From: Greg Rose Date: Sat, 27 Aug 2011 06:24:59 +0000 (+0000) Subject: igbvf: Fix trunk vlan X-Git-Tag: v2.6.39-400.9.0~423^2~19^2~11^2~236 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=8fe4b0949feef20db9e88a7e8fc3e6b72fd7081d;p=users%2Fjedix%2Flinux-maple.git igbvf: Fix trunk vlan Changes to clean up the VLAN Rx path by Jiri Pirko broke trunk VLAN. Trunk VLANs in a VF driver are those set using "ip link set vf " (cherry picked from commit 4d2d55ac94f52ea8787270ec29579ced83f5f96b) Signed-off-by: Greg Rose CC: Jiri Pirko Signed-off-by: Jeff Kirsher Signed-off-by: Joe Jin --- diff --git a/drivers/net/igbvf/netdev.c b/drivers/net/igbvf/netdev.c index cf26ffd580ff..e404209204cd 100644 --- a/drivers/net/igbvf/netdev.c +++ b/drivers/net/igbvf/netdev.c @@ -102,8 +102,8 @@ static void igbvf_receive_skb(struct igbvf_adapter *adapter, { if (status & E1000_RXD_STAT_VP) { u16 vid = le16_to_cpu(vlan) & E1000_RXD_SPC_VLAN_MASK; - - __vlan_hwaccel_put_tag(skb, vid); + if (test_bit(vid, adapter->active_vlans)) + __vlan_hwaccel_put_tag(skb, vid); } netif_receive_skb(skb); }