Files
android_kernel_xiaomi_sm8450/include/linux
Eric Dumazet d4b812dea4 vlan: mask vlan prio bits
In commit 48cc32d38a
("vlan: don't deliver frames for unknown vlans to protocols")
Florian made sure we set pkt_type to PACKET_OTHERHOST
if the vlan id is set and we could find a vlan device for this
particular id.

But we also have a problem if prio bits are set.

Steinar reported an issue on a router receiving IPv6 frames with a
vlan tag of 4000 (id 0, prio 2), and tunneled into a sit device,
because skb->vlan_tci is set.

Forwarded frame is completely corrupted : We can see (8100:4000)
being inserted in the middle of IPv6 source address :

16:48:00.780413 IP6 2001:16d8:8100:4000:ee1c:0:9d9:bc87 >
9f94:4d95:2001:67c:29f4::: ICMP6, unknown icmp6 type (0), length 64
       0x0000:  0000 0029 8000 c7c3 7103 0001 a0ae e651
       0x0010:  0000 0000 ccce 0b00 0000 0000 1011 1213
       0x0020:  1415 1617 1819 1a1b 1c1d 1e1f 2021 2223
       0x0030:  2425 2627 2829 2a2b 2c2d 2e2f 3031 3233

It seems we are not really ready to properly cope with this right now.

We can probably do better in future kernels :
vlan_get_ingress_priority() should be a netdev property instead of
a per vlan_dev one.

For stable kernels, lets clear vlan_tci to fix the bugs.

Reported-by: Steinar H. Gunderson <sesse@google.com>
Signed-off-by: Eric Dumazet <edumazet@google.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
2013-07-18 13:05:23 -07:00
..
2013-06-27 13:42:16 -04:00
2013-03-01 13:39:00 -08:00
2013-01-02 17:36:10 -08:00
2013-06-17 14:38:54 -04:00
2013-05-07 19:46:02 -07:00
2013-05-29 15:50:34 -04:00
2012-10-08 13:50:20 +10:30
2012-12-02 00:05:12 +00:00
2013-04-29 15:40:23 -04:00
2013-07-03 16:07:39 -07:00
2013-03-23 16:11:31 -07:00
2013-03-22 15:18:18 -07:00
2013-03-12 11:30:04 -07:00
2012-03-23 16:58:38 -07:00
2013-07-05 18:59:33 +04:00
2013-07-10 23:41:18 +01:00
2013-05-01 16:36:22 +05:30
2013-03-28 10:10:25 -06:00
2012-09-30 18:02:20 -07:00
2012-10-16 18:49:15 -07:00
2013-02-26 02:46:08 -05:00
2013-05-07 18:38:27 -07:00
2013-03-15 15:09:43 +10:30
2013-04-29 18:28:40 -07:00
2012-11-22 13:43:27 +09:00
2013-06-17 16:38:57 -07:00
2013-06-19 23:32:07 -04:00
2012-11-08 16:58:30 +01:00
2013-06-10 13:45:49 -07:00
2013-05-06 13:07:33 +02:00
2013-07-03 16:07:32 -07:00
2013-01-25 21:03:54 -08:00
2012-03-26 21:47:19 +02:00
2012-03-26 21:47:19 +02:00
2012-03-26 21:47:19 +02:00
2013-06-13 17:51:04 -07:00
2013-07-18 13:05:23 -07:00
2013-06-17 16:38:57 -07:00
2012-07-17 09:13:37 -07:00
2012-05-31 17:49:32 -07:00
2013-04-30 17:04:06 -07:00
2013-04-01 11:04:50 -07:00
2012-10-10 01:15:44 -04:00
2013-07-09 10:33:30 -07:00
2013-05-31 00:48:22 -07:00
2013-07-10 18:11:34 -07:00
2013-03-15 15:09:43 +10:30
2013-07-02 15:38:19 +09:30
2012-12-25 18:45:06 -05:00
2013-07-03 16:08:05 -07:00
2013-06-08 16:20:14 -04:00
2012-12-11 17:22:27 -08:00
2013-05-04 14:47:26 -04:00
2013-06-12 12:37:40 +01:00
2012-10-17 15:53:02 -05:00
2012-10-10 22:41:05 -04:00
2012-07-10 10:32:06 -05:00
2013-06-12 12:37:30 +01:00
2012-07-31 18:42:43 -07:00
2013-04-29 15:54:28 -07:00
2013-06-26 15:55:52 -06:00
2013-06-26 21:10:05 +02:00
2013-05-31 17:19:05 -07:00
2013-06-21 11:32:51 +02:00
2013-04-29 15:54:28 -07:00
2013-04-12 10:26:23 +02:00
2013-07-03 16:08:05 -07:00
2012-10-06 03:05:01 +09:00
2013-07-10 18:11:34 -07:00
2013-06-17 16:38:57 -07:00
2013-02-19 08:43:34 +01:00
2013-06-17 18:09:53 +09:00
2013-03-29 15:31:30 -04:00
2013-07-05 11:41:00 +05:30
2013-06-20 13:08:01 -07:00
2013-04-30 15:50:12 +05:30
2012-08-21 16:28:31 +02:00
2012-10-09 16:22:32 +09:00
2013-05-21 12:25:02 -05:00
2012-07-22 23:57:55 +04:00
2013-01-15 22:43:15 -08:00
2013-03-20 12:10:38 -04:00
2012-09-05 17:21:36 -07:00
2013-04-29 15:54:37 -07:00
2013-05-27 10:57:53 +09:00
2013-07-10 18:11:34 -07:00