diff options
author | stephen hemminger <shemminger@vyatta.com> | 2012-04-30 06:47:37 +0000 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2012-05-21 09:39:59 -0700 |
commit | 53a67da1360b5634779e1cfece9625ae5b32aba7 (patch) | |
tree | 58b188f17afc3c4ff3412f0a313e71cbf82fa0df /drivers/net/sky2.h | |
parent | ec2b1ddb8f9c4efd78f4bd0d832ab4a35eed4659 (diff) |
sky2: fix receive length error in mixed non-VLAN/VLAN traffic
[ Upstream commit e072b3fad5f3915102c94628b4971f52ff99dd05 ]
Bug: The VLAN bit of the MAC RX Status Word is unreliable in several older
supported chips. Sometimes the VLAN bit is not set for valid VLAN packets
and also sometimes the VLAN bit is set for non-VLAN packets that came after
a VLAN packet. This results in a receive length error when VLAN hardware
tagging is enabled.
Fix: Variation on original fix proposed by Mirko.
The VLAN information is decoded in the status loop, and can be
applied to the received SKB there. This eliminates the need for the
separate tag field in the interface data structure. The tag has to
be copied and cleared if packet is copied. This version checked out
with vlan and normal traffic.
Note: vlan_tx_tag_present should be renamed vlan_tag_present, but that
is outside scope of this.
Reported-by: Mirko Lindner <mlindner@marvell.com>
Signed-off-by: Stephen Hemminger <shemminger@vyatta.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/net/sky2.h')
-rw-r--r-- | drivers/net/sky2.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/net/sky2.h b/drivers/net/sky2.h index 318c9ae7bf9..a79a1662ea9 100644 --- a/drivers/net/sky2.h +++ b/drivers/net/sky2.h @@ -2236,7 +2236,6 @@ struct sky2_port { u16 rx_pending; u16 rx_data_size; u16 rx_nfrags; - u16 rx_tag; struct { unsigned long last; |