aboutgitcodebugslistschat
path: root/tap.h
diff options
context:
space:
mode:
authorStefano Brivio <sbrivio@redhat.com>2022-01-26 16:39:33 +0100
committerStefano Brivio <sbrivio@redhat.com>2022-01-28 18:51:50 +0100
commit34e642923538a05ac21d7e7495da23fb0da56c5f (patch)
tree7bf87c1259114dd95d05302d9fdc9aa985edbab7 /tap.h
parentb1f5688495665269fb17732a3c7fb91c709e61b6 (diff)
downloadpasst-34e642923538a05ac21d7e7495da23fb0da56c5f.tar
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.tar.gz
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.tar.bz2
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.tar.lz
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.tar.xz
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.tar.zst
passt-34e642923538a05ac21d7e7495da23fb0da56c5f.zip
passt, tap: Daemonise once socket is ready without waiting for connection
The existing behaviour is not really practical: an automated agent in charge of starting both qemu and passt would need to fork itself to start passt, because passt won't fork to background until qemu connects, and the agent needs to unblock to start qemu. Instead of waiting for a connection to daemonise, do it right away as soon as a socket is available: that can be considered an initialised state already. Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
Diffstat (limited to 'tap.h')
-rw-r--r--tap.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/tap.h b/tap.h
index c437f5f..8942fcf 100644
--- a/tap.h
+++ b/tap.h
@@ -6,5 +6,5 @@
void tap_ip_send(struct ctx *c, struct in6_addr *src, uint8_t proto,
char *in, size_t len, uint32_t flow);
int tap_send(struct ctx *c, void *data, size_t len, int vnet_pre);
-void tap_handler(struct ctx *c, uint32_t events, struct timespec *now);
+void tap_handler(struct ctx *c, int fd, uint32_t events, struct timespec *now);
void tap_sock_init(struct ctx *c);