bnxt_en: Add support for PCIe statistics
Gather periodic PCIe statistics for ethtool -S. Signed-off-by: Vasundhara Volam <vasundhara-v.volam@broadcom.com> Signed-off-by: Michael Chan <michael.chan@broadcom.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
a220eabc88
commit
55e4398d4e
@@ -1354,6 +1354,7 @@ struct bnxt {
|
||||
#define BNXT_FLAG_DIM 0x2000000
|
||||
#define BNXT_FLAG_ROCE_MIRROR_CAP 0x4000000
|
||||
#define BNXT_FLAG_PORT_STATS_EXT 0x10000000
|
||||
#define BNXT_FLAG_PCIE_STATS 0x40000000
|
||||
|
||||
#define BNXT_FLAG_ALL_CONFIG_FEATS (BNXT_FLAG_TPA | \
|
||||
BNXT_FLAG_RFS | \
|
||||
@@ -1480,6 +1481,7 @@ struct bnxt {
|
||||
#define BNXT_FW_CAP_KONG_MB_CHNL 0x00000080
|
||||
#define BNXT_FW_CAP_OVS_64BIT_HANDLE 0x00000400
|
||||
#define BNXT_FW_CAP_TRUSTED_VF 0x00000800
|
||||
#define BNXT_FW_CAP_PCIE_STATS_SUPPORTED 0x00020000
|
||||
|
||||
#define BNXT_NEW_RM(bp) ((bp)->fw_cap & BNXT_FW_CAP_NEW_RM)
|
||||
u32 hwrm_spec_code;
|
||||
@@ -1498,10 +1500,12 @@ struct bnxt {
|
||||
struct tx_port_stats *hw_tx_port_stats;
|
||||
struct rx_port_stats_ext *hw_rx_port_stats_ext;
|
||||
struct tx_port_stats_ext *hw_tx_port_stats_ext;
|
||||
struct pcie_ctx_hw_stats *hw_pcie_stats;
|
||||
dma_addr_t hw_rx_port_stats_map;
|
||||
dma_addr_t hw_tx_port_stats_map;
|
||||
dma_addr_t hw_rx_port_stats_ext_map;
|
||||
dma_addr_t hw_tx_port_stats_ext_map;
|
||||
dma_addr_t hw_pcie_stats_map;
|
||||
int hw_port_stats_size;
|
||||
u16 fw_rx_stats_ext_size;
|
||||
u16 fw_tx_stats_ext_size;
|
||||
@@ -1634,6 +1638,9 @@ struct bnxt {
|
||||
#define BNXT_TX_STATS_EXT_OFFSET(counter) \
|
||||
(offsetof(struct tx_port_stats_ext, counter) / 8)
|
||||
|
||||
#define BNXT_PCIE_STATS_OFFSET(counter) \
|
||||
(offsetof(struct pcie_ctx_hw_stats, counter) / 8)
|
||||
|
||||
#define I2C_DEV_ADDR_A0 0xa0
|
||||
#define I2C_DEV_ADDR_A2 0xa2
|
||||
#define SFF_DIAG_SUPPORT_OFFSET 0x5c
|
||||
|
Reference in New Issue
Block a user