From 64a0ba3b272dd9ee175e0c6256a6d0cb1733599b Mon Sep 17 00:00:00 2001 From: Stefano Brivio Date: Wed, 21 Jul 2021 12:01:04 +0200 Subject: udp: Introduce recvmmsg()/sendmmsg(), zero-copy path from socket Packets are received directly onto pre-cooked, static buffers for IPv4 (with partial checksum pre-calculation) and IPv6 frames, with pre-filled Ethernet addresses and, partially, IP headers, and sent out from the same buffers with sendmmsg(), for both passt and pasta (non-local traffic only) modes. Signed-off-by: Stefano Brivio --- passt.h | 3 +++ 1 file changed, 3 insertions(+) (limited to 'passt.h') diff --git a/passt.h b/passt.h index 1a708fd..f5ecb0c 100644 --- a/passt.h +++ b/passt.h @@ -134,3 +134,6 @@ struct ctx { struct udp_ctx udp; struct icmp_ctx icmp; }; + +void proto_update_l2_buf(unsigned char *eth_d, unsigned char *eth_s, + uint32_t *ip_da); -- cgit v1.2.3