crosvm/third_party
Alexandre Courbot d60bf43903 devices: vhost-user: handler: stop spawning a thread for the socket listener
The async methods of the socket VVU handler were calling the non-async
accept() on a dedicated thread so the async method does not get blocked
awaiting for a connection. This socket-specific behavior forces us to
have dedicated code for the socket and VVU handlers.

Fix this by adding a poll_descriptor() method to vmm_vhost's Listener
trait that returns a descriptor that callers can poll on if a call to
accept() can block. This way we can wait for the connection
asynchronously and avoid using a thread for that. It also opens the way
towards factorizing the socket and VVU specific code.

BUG=b:229554679
TEST=vhost-user console device works.

Change-Id: I3fbc96d3904f777c6165b04564f577c553ce55d2
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/platform/crosvm/+/3592632
Reviewed-by: Keiichi Watanabe <keiichiw@chromium.org>
Tested-by: kokoro <noreply+kokoro@google.com>
Commit-Queue: Alexandre Courbot <acourbot@chromium.org>
2022-06-08 02:29:20 +00:00
..
libslirp-rs third_party: libslirp-rs: remove unused files. 2022-06-02 03:00:37 +00:00
minigbm@ef852e007c Uprev all submodules 2021-10-19 19:12:53 +00:00
minijail@77c59db8ff third_party/minijail: update to latest 2022-05-06 23:09:20 +00:00
virglrenderer@4770f706db virglrenderer: Add cross-domain support 2022-05-20 20:49:55 +00:00
vmm_vhost devices: vhost-user: handler: stop spawning a thread for the socket listener 2022-06-08 02:29:20 +00:00