From d372c42460a56ecb9dfdc80f861f2e6a925ba25b Mon Sep 17 00:00:00 2001 From: Stefano Brivio Date: Tue, 27 Jul 2021 00:48:06 +0200 Subject: tap: Increase amount of tap receive buffers to 128 ...boom. To make it slightly more reasonable, shrink struct tap_msg down a bit, and move the main message array away from the stack of tap_handler_passt(). Signed-off-by: Stefano Brivio --- passt.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'passt.h') diff --git a/passt.h b/passt.h index f5ecb0c..e3f570b 100644 --- a/passt.h +++ b/passt.h @@ -11,8 +11,8 @@ struct tap_msg { char *start; char *l4h; - size_t len; - size_t l4_len; + uint16_t len; + uint16_t l4_len; }; union epoll_ref; @@ -45,7 +45,7 @@ union epoll_ref { uint64_t u64; }; -#define TAP_BUF_BYTES (ETH_MAX_MTU * 3) +#define TAP_BUF_BYTES (ETH_MAX_MTU * 128) #define TAP_BUF_FILL (TAP_BUF_BYTES - ETH_MAX_MTU - sizeof(uint32_t)) #define TAP_MSGS (TAP_BUF_BYTES / sizeof(struct ethhdr) + 1) -- cgit v1.2.3