2
0
mirror of https://github.com/openvswitch/ovs synced 2025-10-23 14:57:06 +00:00

netdev-linux: Read packet auxdata to obtain vlan_tid

If VLAN acceleration is used when the kernel receives a packet
then the outer-most VLAN tag will not be present in the packet
when it is received by netdev-linux. Rather, it will be present
in auxdata.

This patch uses recvmsg() instead of recv() to read auxdata for
each packet and if the vlan_tid is set then it is added to the packet.

Adding the vlan_tid makes use of headroom available
in the buffer parameter of rx_recv.

Signed-off-by: Simon Horman <horms@verge.net.au>
Co-authored-by: Ben Pfaff <blp@nicira.com>
Signed-off-by: Ben Pfaff <blp@nicira.com>
This commit is contained in:
Simon Horman
2014-01-15 17:17:02 +09:00
committed by Ben Pfaff
parent 1bf02876a4
commit b73c85181d
4 changed files with 185 additions and 18 deletions

View File

@@ -87,6 +87,7 @@ enum {
};
enum {
SOL_PACKET,
SOL_SOCKET
};