From: Greg Rose Date: Sat, 27 Aug 2011 02:06:25 +0000 (+0000) Subject: ixgbevf: Fix broken trunk vlan X-Git-Tag: v2.6.39-400.9.0~423^2~19^2~11^2~75 X-Git-Url: https://www.infradead.org/git/?a=commitdiff_plain;h=e86ee2aaea66515185d409b2298749c8333bc66f;p=users%2Fjedix%2Flinux-maple.git ixgbevf: Fix broken trunk vlan Changes to clean up the vlan rx path broke trunk vlan. Trunk vlans in a VF driver are those set using: "ip link set vf " (cherry picked from commit dd1ed3b7bfed15f6162f63840941e9cf4f3611a1) Signed-off-by: Greg Rose CC: Jiri Pirko Signed-off-by: Jeff Kirsher Signed-off-by: Joe Jin --- diff --git a/drivers/net/ixgbevf/ixgbevf_main.c b/drivers/net/ixgbevf/ixgbevf_main.c index c70f068d3203a..e58f424ca31bd 100644 --- a/drivers/net/ixgbevf/ixgbevf_main.c +++ b/drivers/net/ixgbevf/ixgbevf_main.c @@ -297,12 +297,10 @@ static void ixgbevf_receive_skb(struct ixgbevf_q_vector *q_vector, { struct ixgbevf_adapter *adapter = q_vector->adapter; bool is_vlan = (status & IXGBE_RXD_STAT_VP); + u16 tag = le16_to_cpu(rx_desc->wb.upper.vlan); - if (is_vlan) { - u16 tag = le16_to_cpu(rx_desc->wb.upper.vlan); - + if (is_vlan && test_bit(tag, adapter->active_vlans)) __vlan_hwaccel_put_tag(skb, tag); - } if (!(adapter->flags & IXGBE_FLAG_IN_NETPOLL)) napi_gro_receive(&q_vector->napi, skb);