udp, passt: Introduce socket packet buffer, avoid getsockname() for UDP
This is in preparation for scatter-gather IO on the UDP receive path: save a getsockname() syscall by setting a flag if we get the numbering of all bound sockets in a strict sequence (expected, in practice) and repurpose the tap buffer to be also a socket receive buffer, passing it down to protocol handlers. Signed-off-by: Stefano Brivio <sbrivio@redhat.com>
This commit is contained in:
2
icmp.h
2
icmp.h
@@ -3,7 +3,7 @@
|
||||
|
||||
struct ctx;
|
||||
|
||||
void icmp_sock_handler(struct ctx *c, int s, uint32_t events,
|
||||
void icmp_sock_handler(struct ctx *c, int s, uint32_t events, char *pkt_buf,
|
||||
struct timespec *now);
|
||||
int icmp_tap_handler(struct ctx *c, int af, void *addr,
|
||||
struct tap_msg *msg, int count, struct timespec *now);
|
||||
|
||||
Reference in New Issue
Block a user