be2net: patch-set
Subsystems (3)
cover be2net: patch-set
Hi Dave, Please consider applying these two patches to net
Suresh Reddy (2):
be2net: Fix HW stall issue in Lancer
be2net: Handle transmit completion errors in Lancer
drivers/net/ethernet/emulex/benet/be.h | 7 +- drivers/net/ethernet/emulex/benet/be_ethtool.c | 1 + drivers/net/ethernet/emulex/benet/be_hw.h | 1 + drivers/net/ethernet/emulex/benet/be_main.c | 113 +++++++++++++++---------- 4 files changed, 73 insertions(+), 49 deletions(-)
Signature · 1 line
1.8.3.1
PATCH 1/2 be2net: Fix HW stall issue in Lancer
Lancer HW cannot handle a TSO packet with a single segment. Disable TSO/GSO for such packets.
--- drivers/net/ethernet/emulex/benet/be_main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-)
drivers/net/ethernet/emulex/benet/be_main.c +4 -1
@@ -5097,9 +5097,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 ; }
Signature · 1 line
1.8.3.1
PATCH 2/2 be2net: Handle transmit completion errors in Lancer
In reply to Suresh ReddyIf the driver receives a TX CQE with status as 0x1 or 0x9 or 0xb, the completion indexes should not be used. The driver must stop consuming CQEs from this TXQ/CQ. The TXQ from this point on-wards to be in a bad state. Driver should destroy and recreate the TXQ.
0x1: LANCER_TX_COMP_LSO_ERR0x9 LANCER_TX_COMP_SGE_ERR0xb: LANCER_TX_COMP_PARITY_ERR
Reset the adapter if driver sees this error in TX completion. Also adding sge error counter in ethtool stats.
--- drivers/net/ethernet/emulex/benet/be.h | 7 +- drivers/net/ethernet/emulex/benet/be_ethtool.c | 1 + drivers/net/ethernet/emulex/benet/be_hw.h | 1 + drivers/net/ethernet/emulex/benet/be_main.c | 108 ++++++++++++++----------- 4 files changed, 69 insertions(+), 48 deletions(-)
drivers/net/ethernet/emulex/benet/be.h +5 -2
@@ -248,6 +248,7 @@ struct be_tx_stats {u32 tx_spoof_check_err;u32 tx_qinq_err;u32 tx_internal_parity_err; +u32 tx_sge_err;struct u64_stats_sync sync;struct u64_stats_sync sync_compl; };
@@ -944,8 +945,10 @@ static inline bool is_ipv6_ext_hdr(struct sk_buff *skb)#define BE_ERROR_EEH 1#define BE_ERROR_UE BIT(1)#define BE_ERROR_FW BIT(2) -#define BE_ERROR_HW (BE_ERROR_EEH | BE_ERROR_UE) -#define BE_ERROR_ANY (BE_ERROR_EEH | BE_ERROR_UE | BE_ERROR_FW) +#define BE_ERROR_TX BIT(3) +#define BE_ERROR_HW (BE_ERROR_EEH | BE_ERROR_UE | BE_ERROR_TX) +#define BE_ERROR_ANY (BE_ERROR_EEH | BE_ERROR_UE | BE_ERROR_FW | \ + BE_ERROR_TX)#define BE_CLEAR_ALL 0xFFstatic inline u8 be_check_error (struct be_adapter *adapter,u32 err_type)
drivers/net/ethernet/emulex/benet/be_ethtool.c +1 -0
@@ -189,6 +189,7 @@ struct be_ethtool_stat {* packet data. This counter is applicable only for Lancer adapters. */ {DRVSTAT_TX_INFO(tx_internal_parity_err)}, + {DRVSTAT_TX_INFO(tx_sge_err)}, {DRVSTAT_TX_INFO(tx_bytes)}, {DRVSTAT_TX_INFO(tx_pkts)}, {DRVSTAT_TX_INFO(tx_vxlan_offload_pkts)},
drivers/net/ethernet/emulex/benet/be_hw.h +1 -0
@@ -261,6 +261,7 @@ struct be_eth_hdr_wrb {#define LANCER_TX_COMP_HSW_DROP_MAC_ERR 0x3#define LANCER_TX_COMP_HSW_DROP_VLAN_ERR 0x5#define LANCER_TX_COMP_QINQ_ERR 0x7 +#define LANCER_TX_COMP_SGE_ERR 0x9#define LANCER_TX_COMP_PARITY_ERR 0xb#define LANCER_TX_COMP_DMA_ERR 0xd
drivers/net/ethernet/emulex/benet/be_main.c +62 -46
140 lines not on this page · raw message
Signature · 1 line
1.8.3.1
David Miller
maintainerFrom: Suresh Reddy <[email protected]>
Date: Tue, 6 Feb 2018 08:52:40 -0500
Quoted 1 line
Hi Dave, Please consider applying these two patches to net
Series applied, thank you.