Skip to content

Commit

Permalink
be2net: Fix HW stall issue in Lancer
Browse files Browse the repository at this point in the history
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>
  • Loading branch information
Suresh Reddy authored and David S. Miller committed Feb 6, 2018
1 parent 2c0aa08 commit 3df40aa
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion drivers/net/ethernet/emulex/benet/be_main.c
Original file line number Diff line number Diff line change
Expand Up @@ -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;
}

Expand Down

0 comments on commit 3df40aa

Please sign in to comment.