summaryrefslogtreecommitdiff
path: root/drivers/net/ethernet
diff options
context:
space:
mode:
authorSuresh Reddy <suresh.reddy@broadcom.com>2018-02-06 16:52:41 +0300
committerDavid S. Miller <davem@davemloft.net>2018-02-06 19:48:17 +0300
commit3df40aad1a864af124bd50a1371ef16089ac9af2 (patch)
tree9fc84f3d7249645ad12df5aa888146b644aeff30 /drivers/net/ethernet
parent2c0aa08631b86a4678dbc93b9caa5248014b4458 (diff)
downloadlinux-3df40aad1a864af124bd50a1371ef16089ac9af2.tar.xz
be2net: Fix HW stall issue in Lancer
Lancer HW cannot handle a TSO packet with a single segment. Disable TSO/GSO for such packets. Signed-off-by: Suresh Reddy <suresh.reddy@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r--drivers/net/ethernet/emulex/benet/be_main.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/ethernet/emulex/benet/be_main.c b/drivers/net/ethernet/emulex/benet/be_main.c
index d81e2d37bc3d..286d591c574e 100644
--- a/drivers/net/ethernet/emulex/benet/be_main.c
+++ b/drivers/net/ethernet/emulex/benet/be_main.c
@@ -5104,9 +5104,12 @@ static netdev_features_t be_features_check(struct sk_buff *skb,
features &= ~NETIF_F_TSO6;
/* Lancer cannot handle the packet with MSS less than 256.
+ * Also it can't handle a TSO packet with a single segment
* Disable the GSO support in such cases
*/
- if (lancer_chip(adapter) && skb_shinfo(skb)->gso_size < 256)
+ if (lancer_chip(adapter) &&
+ (skb_shinfo(skb)->gso_size < 256 ||
+ skb_shinfo(skb)->gso_segs == 1))
features &= ~NETIF_F_GSO_MASK;
}