Netdev List
 help / color / mirror / Atom feed
* [PATCH net 0/2] Fix vlan untag and insertion for bridge and vlan with reorder_hdr off
@ 2018-03-13  5:51 Toshiaki Makita
  2018-03-13  5:51 ` [PATCH net 1/2] net: Fix vlan untag for bridge and vlan_dev " Toshiaki Makita
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Toshiaki Makita @ 2018-03-13  5:51 UTC (permalink / raw)
  To: David S. Miller; +Cc: Toshiaki Makita, netdev, Brandon Carpenter, Vlad Yasevich

As Brandon Carpenter reported[1], sending non-vlan-offloaded packets from
bridge devices ends up with corrupted packets. He narrowed down this problem
and found that the root cause is in skb_reorder_vlan_header().

While I was working on fixing this problem, I found that the function does
not work properly for double tagged packets with reorder_hdr off as well.

Patch 1 fixes these 2 problems in skb_reorder_vlan_header().

And it turned out that fixing skb_reorder_vlan_header() is not sufficient
to receive double tagged packets with reorder_hdr off while I was testing the
fix. Vlan tags got out of order when vlan devices with reorder_hdr disabled
were stacked. Patch 2 fixes this problem.

[1] https://www.spinics.net/lists/linux-ethernet-bridging/msg07039.html

Toshiaki Makita (2):
  net: Fix vlan untag for bridge and vlan_dev with reorder_hdr off
  vlan: Fix out of order vlan headers with reorder header off

 include/linux/if_vlan.h       | 66 +++++++++++++++++++++++++++++++++++--------
 include/uapi/linux/if_ether.h |  1 +
 net/8021q/vlan_core.c         |  4 +--
 net/core/skbuff.c             |  7 +++--
 4 files changed, 63 insertions(+), 15 deletions(-)

-- 
1.8.3.1

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2018-03-28  8:04 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-03-13  5:51 [PATCH net 0/2] Fix vlan untag and insertion for bridge and vlan with reorder_hdr off Toshiaki Makita
2018-03-13  5:51 ` [PATCH net 1/2] net: Fix vlan untag for bridge and vlan_dev " Toshiaki Makita
2018-03-13  5:51 ` [PATCH net 2/2] vlan: Fix out of order vlan headers with reorder header off Toshiaki Makita
2018-03-16 14:05 ` [PATCH net 0/2] Fix vlan untag and insertion for bridge and vlan with reorder_hdr off David Miller
2018-03-28  6:11   ` Eric Dumazet
2018-03-28  8:03     ` Toshiaki Makita

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox