mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-09-03 17:40:04 +00:00
vxlan: Fix error that was resulting in VXLAN MTU size being 10 bytes too large
This change fixes an issue I found where VXLAN frames were fragmented when they were up to the VXLAN MTU size. I root caused the issue to the fact that the headroom was 4 + 20 + 8 + 8. This math doesn't appear to be correct because we are not inserting a VLAN header, but instead a 2nd Ethernet header. As such the math for the overhead should be 20 + 8 + 8 + 14 to account for the extra headers that are inserted for VXLAN. Signed-off-by: Alexander Duyck <alexander.h.duyck@intel.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:
parent
bd090dfc63
commit
52b702ffa5
1 changed files with 2 additions and 2 deletions
|
@ -50,8 +50,8 @@
|
||||||
|
|
||||||
#define VXLAN_N_VID (1u << 24)
|
#define VXLAN_N_VID (1u << 24)
|
||||||
#define VXLAN_VID_MASK (VXLAN_N_VID - 1)
|
#define VXLAN_VID_MASK (VXLAN_N_VID - 1)
|
||||||
/* VLAN + IP header + UDP + VXLAN */
|
/* IP header + UDP + VXLAN + Ethernet header */
|
||||||
#define VXLAN_HEADROOM (4 + 20 + 8 + 8)
|
#define VXLAN_HEADROOM (20 + 8 + 8 + 14)
|
||||||
|
|
||||||
#define VXLAN_FLAGS 0x08000000 /* struct vxlanhdr.vx_flags required value. */
|
#define VXLAN_FLAGS 0x08000000 /* struct vxlanhdr.vx_flags required value. */
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue