Skip to content

Commit

Permalink
Merge branch 'cxgb4-update-kconfig-and-fixes'
Browse files Browse the repository at this point in the history
Hariprasad Shenai says:

====================
Update Kconfig and some fixes for cxgb4

This series update Kconfig to add description for Chelsio's next
generation T6 family of adapters, also fixes ethtool stats alignment
and prevents simultaneous execution of service_ofldq thread, deals with
queue wrap around and adds some fl counters for debugging purpose and
device ID for new T5 adapters.

This patch series has been created against net-next tree and includes
patches on cxgb4 driver.

We have included all the maintainers of respective drivers. Kindly review
the change and let us know in case of any review comments.

Thanks

V2: Declare 'service_ofldq_running' as bool in Patch 4/7 ("cxgb4: prevent
    simultaneous execution of service_ofldq()") based on review comment
    by David Miller
====================

Signed-off-by: David S. Miller <davem@davemloft.net>
  • Loading branch information
David S. Miller committed Dec 9, 2015
2 parents 9cbe9fd + 76928c9 commit bc22ff5
Show file tree
Hide file tree
Showing 6 changed files with 202 additions and 93 deletions.
17 changes: 9 additions & 8 deletions drivers/net/ethernet/chelsio/Kconfig
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,14 @@ config CHELSIO_T3
will be called cxgb3.

config CHELSIO_T4
tristate "Chelsio Communications T4/T5 Ethernet support"
tristate "Chelsio Communications T4/T5/T6 Ethernet support"
depends on PCI && (IPV6 || IPV6=n)
select FW_LOADER
select MDIO
---help---
This driver supports Chelsio T4 and T5 based gigabit, 10Gb Ethernet
adapter and T5 based 40Gb Ethernet adapter.
This driver supports Chelsio T4, T5 & T6 based gigabit, 10Gb Ethernet
adapter and T5/T6 based 40Gb and T6 based 25Gb, 50Gb and 100Gb
Ethernet adapters.

For general information about Chelsio and our products, visit
our website at <http://www.chelsio.com>.
Expand All @@ -85,7 +86,7 @@ config CHELSIO_T4
will be called cxgb4.

config CHELSIO_T4_DCB
bool "Data Center Bridging (DCB) Support for Chelsio T4/T5 cards"
bool "Data Center Bridging (DCB) Support for Chelsio T4/T5/T6 cards"
default n
depends on CHELSIO_T4 && DCB
---help---
Expand All @@ -107,12 +108,12 @@ config CHELSIO_T4_FCOE
If unsure, say N.

config CHELSIO_T4VF
tristate "Chelsio Communications T4/T5 Virtual Function Ethernet support"
tristate "Chelsio Communications T4/T5/T6 Virtual Function Ethernet support"
depends on PCI
---help---
This driver supports Chelsio T4 and T5 based gigabit, 10Gb Ethernet
adapters and T5 based 40Gb Ethernet adapters with PCI-E SR-IOV Virtual
Functions.
This driver supports Chelsio T4, T5 & T6 based gigabit, 10Gb Ethernet
adapters and T5/T6 based 40Gb and T6 based 25Gb, 50Gb and 100Gb
Ethernet adapters with PCI-E SR-IOV Virtual Functions.

For general information about Chelsio and our products, visit
our website at <http://www.chelsio.com>.
Expand Down
3 changes: 3 additions & 0 deletions drivers/net/ethernet/chelsio/cxgb4/cxgb4.h
Original file line number Diff line number Diff line change
Expand Up @@ -483,6 +483,8 @@ struct sge_fl { /* SGE free-buffer queue state */
unsigned int pidx; /* producer index */
unsigned long alloc_failed; /* # of times buffer allocation failed */
unsigned long large_alloc_failed;
unsigned long mapping_err; /* # of RX Buffer DMA Mapping failures */
unsigned long low; /* # of times momentarily starving */
unsigned long starving;
/* RO fields */
unsigned int cntxt_id; /* SGE context id for the free list */
Expand Down Expand Up @@ -618,6 +620,7 @@ struct sge_ofld_txq { /* state for an SGE offload Tx queue */
struct adapter *adap;
struct sk_buff_head sendq; /* list of backpressured packets */
struct tasklet_struct qresume_tsk; /* restarts the queue */
bool service_ofldq_running; /* service_ofldq() is processing sendq */
u8 full; /* the Tx ring is full */
unsigned long mapping_err; /* # of I/O MMU packet mapping errors */
} ____cacheline_aligned_in_smp;
Expand Down
6 changes: 6 additions & 0 deletions drivers/net/ethernet/chelsio/cxgb4/cxgb4_debugfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -2325,6 +2325,8 @@ do { \
TL("TxMapErr:", mapping_err);
RL("FLAllocErr:", fl.alloc_failed);
RL("FLLrgAlcErr:", fl.large_alloc_failed);
RL("FLMapErr:", fl.mapping_err);
RL("FLLow:", fl.low);
RL("FLStarving:", fl.starving);

} else if (iscsi_idx < iscsi_entries) {
Expand Down Expand Up @@ -2359,6 +2361,8 @@ do { \
RL("RxNoMem:", stats.nomem);
RL("FLAllocErr:", fl.alloc_failed);
RL("FLLrgAlcErr:", fl.large_alloc_failed);
RL("FLMapErr:", fl.mapping_err);
RL("FLLow:", fl.low);
RL("FLStarving:", fl.starving);

} else if (rdma_idx < rdma_entries) {
Expand Down Expand Up @@ -2388,6 +2392,8 @@ do { \
RL("RxNoMem:", stats.nomem);
RL("FLAllocErr:", fl.alloc_failed);
RL("FLLrgAlcErr:", fl.large_alloc_failed);
RL("FLMapErr:", fl.mapping_err);
RL("FLLow:", fl.low);
RL("FLStarving:", fl.starving);

} else if (ciq_idx < ciq_entries) {
Expand Down
146 changes: 73 additions & 73 deletions drivers/net/ethernet/chelsio/cxgb4/cxgb4_ethtool.c
Original file line number Diff line number Diff line change
Expand Up @@ -35,79 +35,79 @@ static void set_msglevel(struct net_device *dev, u32 val)
}

static const char stats_strings[][ETH_GSTRING_LEN] = {
"tx_octets_ok ",
"tx_frames_ok ",
"tx_broadcast_frames ",
"tx_multicast_frames ",
"tx_unicast_frames ",
"tx_error_frames ",

"tx_frames_64 ",
"tx_frames_65_to_127 ",
"tx_frames_128_to_255 ",
"tx_frames_256_to_511 ",
"tx_frames_512_to_1023 ",
"tx_frames_1024_to_1518 ",
"tx_frames_1519_to_max ",

"tx_frames_dropped ",
"tx_pause_frames ",
"tx_ppp0_frames ",
"tx_ppp1_frames ",
"tx_ppp2_frames ",
"tx_ppp3_frames ",
"tx_ppp4_frames ",
"tx_ppp5_frames ",
"tx_ppp6_frames ",
"tx_ppp7_frames ",

"rx_octets_ok ",
"rx_frames_ok ",
"rx_broadcast_frames ",
"rx_multicast_frames ",
"rx_unicast_frames ",

"rx_frames_too_long ",
"rx_jabber_errors ",
"rx_fcs_errors ",
"rx_length_errors ",
"rx_symbol_errors ",
"rx_runt_frames ",

"rx_frames_64 ",
"rx_frames_65_to_127 ",
"rx_frames_128_to_255 ",
"rx_frames_256_to_511 ",
"rx_frames_512_to_1023 ",
"rx_frames_1024_to_1518 ",
"rx_frames_1519_to_max ",

"rx_pause_frames ",
"rx_ppp0_frames ",
"rx_ppp1_frames ",
"rx_ppp2_frames ",
"rx_ppp3_frames ",
"rx_ppp4_frames ",
"rx_ppp5_frames ",
"rx_ppp6_frames ",
"rx_ppp7_frames ",

"rx_bg0_frames_dropped ",
"rx_bg1_frames_dropped ",
"rx_bg2_frames_dropped ",
"rx_bg3_frames_dropped ",
"rx_bg0_frames_trunc ",
"rx_bg1_frames_trunc ",
"rx_bg2_frames_trunc ",
"rx_bg3_frames_trunc ",

"tso ",
"tx_csum_offload ",
"rx_csum_good ",
"vlan_extractions ",
"vlan_insertions ",
"gro_packets ",
"gro_merged ",
"tx_octets_ok ",
"tx_frames_ok ",
"tx_broadcast_frames ",
"tx_multicast_frames ",
"tx_unicast_frames ",
"tx_error_frames ",

"tx_frames_64 ",
"tx_frames_65_to_127 ",
"tx_frames_128_to_255 ",
"tx_frames_256_to_511 ",
"tx_frames_512_to_1023 ",
"tx_frames_1024_to_1518 ",
"tx_frames_1519_to_max ",

"tx_frames_dropped ",
"tx_pause_frames ",
"tx_ppp0_frames ",
"tx_ppp1_frames ",
"tx_ppp2_frames ",
"tx_ppp3_frames ",
"tx_ppp4_frames ",
"tx_ppp5_frames ",
"tx_ppp6_frames ",
"tx_ppp7_frames ",

"rx_octets_ok ",
"rx_frames_ok ",
"rx_broadcast_frames ",
"rx_multicast_frames ",
"rx_unicast_frames ",

"rx_frames_too_long ",
"rx_jabber_errors ",
"rx_fcs_errors ",
"rx_length_errors ",
"rx_symbol_errors ",
"rx_runt_frames ",

"rx_frames_64 ",
"rx_frames_65_to_127 ",
"rx_frames_128_to_255 ",
"rx_frames_256_to_511 ",
"rx_frames_512_to_1023 ",
"rx_frames_1024_to_1518 ",
"rx_frames_1519_to_max ",

"rx_pause_frames ",
"rx_ppp0_frames ",
"rx_ppp1_frames ",
"rx_ppp2_frames ",
"rx_ppp3_frames ",
"rx_ppp4_frames ",
"rx_ppp5_frames ",
"rx_ppp6_frames ",
"rx_ppp7_frames ",

"rx_bg0_frames_dropped ",
"rx_bg1_frames_dropped ",
"rx_bg2_frames_dropped ",
"rx_bg3_frames_dropped ",
"rx_bg0_frames_trunc ",
"rx_bg1_frames_trunc ",
"rx_bg2_frames_trunc ",
"rx_bg3_frames_trunc ",

"tso ",
"tx_csum_offload ",
"rx_csum_good ",
"vlan_extractions ",
"vlan_insertions ",
"gro_packets ",
"gro_merged ",
};

static char adapter_stats_strings[][ETH_GSTRING_LEN] = {
Expand Down
Loading

0 comments on commit bc22ff5

Please sign in to comment.