The vhost-device devices all call VhostUserDaemon::serve in a loop, to
handle reconnections. This is not ideal, because a new listener is
created each loop iteration, which means that each time, the old
socket is unlinked and a new one is created. This means that there's
a potential race where a frontend attempts to connect to the backend
before the new socket is created.
A more robust way to achieve this would be to have the devices create
their own listeners, and pass the same one to VhostUserDaemon::start
on each loop iteration, instead of letting VhostUserDaemon::serve
create it repeatedly. This was not previously possible though,
because VhostUserDaemon::start consumed the listener, even though it
didn't need to.
Because it's now possible to call VhostUserDaemon::start multiple
times with the same socket, I've removed the TODO about handling
reconnection.
Signed-off-by: Alyssa Ross <hi@alyssa.is>