]> git.karo-electronics.de Git - linux-beck.git/commit
qlge: Fix TSO for non-accelerated vlan traffic
authorVlad Yasevich <vyasevich@gmail.com>
Mon, 25 Aug 2014 14:34:55 +0000 (10:34 -0400)
committerDavid S. Miller <davem@davemloft.net>
Tue, 26 Aug 2014 00:27:10 +0000 (17:27 -0700)
commit1ee1cfe7d3df00bff11dd28576eeac1875d7d51f
treefe056ca032ee9d8b0307b4502e198f0efc3a2209
parent817dbfa5d1bc276a72c1a577310382008e8aca0a
qlge: Fix TSO for non-accelerated vlan traffic

This device claims TSO support for vlans.  It also allows a user to
control vlan acceleration offloading.  As such, it is possible to turn
off vlan acceleration and configure a vlan which will continue to send
TSO traffic.

In such situation the packet passed down the the device will contain
a vlan header and skb->protocol will be set to ETH_P_8021Q.
The device assumes that skb->protocol contains network protocol
value and uses that value to set up TSO information.
This results in corrupted frames sent on the wire.

This patch extracts the protocol value correctly by using a
vlan_get_protocol() helper and corrects corrupt TSO frames.

CC: Shahed Shaikh <shahed.shaikh@qlogic.com>
CC: Jitendra Kalsaria <jitendra.kalsaria@qlogic.com>
CC: Ron Mercer <ron.mercer@qlogic.com>
CC: linux-driver@qlogic.com
Signed-off-by: Vladislav Yasevich <vyasevic@redhat.com>
Acked-by: Shahed Shaikh <shahed.shaikh@qlogic.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/ethernet/qlogic/qlge/qlge_main.c