From: Chris Friesen <chris.frie...@genband.com> In igbvf_receive_skb() the VLAN tag is big-endian while the mask is cpu-endian. We need to convert both to common endianness before applying the mask.
Signed-off-by: Chris Friesen <chris.frie...@genband.com> Reported-by: Mark Huang <mark.hu...@genband.com> --- diff --git a/src/netdev.c b/src/netdev.c index a18f000..260a598 100644 --- a/src/netdev.c +++ b/src/netdev.c @@ -127,9 +127,9 @@ static void igbvf_receive_skb(struct igbvf_adapter *adapter, if (status & E1000_RXD_STAT_VP) { if ((adapter->flags & IGBVF_FLAG_RX_LB_VLAN_BSWAP) && (status & E1000_RXDEXT_STATERR_LB)) - vid = be16_to_cpu(vlan & E1000_RXD_SPC_VLAN_MASK); + vid = be16_to_cpu(vlan) & E1000_RXD_SPC_VLAN_MASK; else - vid = le16_to_cpu(vlan & E1000_RXD_SPC_VLAN_MASK); + vid = le16_to_cpu(vlan) & E1000_RXD_SPC_VLAN_MASK; } /* * On some adapters, trunk VLANs are incorrectly indicated in the ------------------------------------------------------------------------------ Monitor your physical, virtual and cloud infrastructure from a single web console. Get in-depth insight into apps, servers, databases, vmware, SAP, cloud infrastructure, etc. Download 30-day Free Trial. Pricing starts from $795 for 25 servers or applications! http://p.sf.net/sfu/zoho_dev2dev_nov _______________________________________________ E1000-devel mailing list E1000-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/e1000-devel To learn more about Intel® Ethernet, visit http://communities.intel.com/community/wired