diff mbox series

[PULL,02/13] net: Add a 'do_not_pad" to NetClientState

Message ID 1616407692-693-3-git-send-email-jasowang@redhat.com
State New
Headers show
Series [PULL,01/13] net: eth: Add a helper to pad a short Ethernet frame | expand

Commit Message

Jason Wang March 22, 2021, 10:08 a.m. UTC
From: Bin Meng <bmeng.cn@gmail.com>

This adds a flag in NetClientState, so that a net client can tell
its peer that the packets do not need to be padded to the minimum
size of an Ethernet frame (60 bytes) before sending to it.

Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
Reviewed-by: Philippe Mathieu-Daudé <philmd@redhat.com>
Signed-off-by: Jason Wang <jasowang@redhat.com>
---
 include/net/net.h | 1 +
 1 file changed, 1 insertion(+)
diff mbox series

Patch

diff --git a/include/net/net.h b/include/net/net.h
index a02949f..3559f3c 100644
--- a/include/net/net.h
+++ b/include/net/net.h
@@ -103,6 +103,7 @@  struct NetClientState {
     int vring_enable;
     int vnet_hdr_len;
     bool is_netdev;
+    bool do_not_pad; /* do not pad to the minimum ethernet frame length */
     QTAILQ_HEAD(, NetFilterState) filters;
 };