Commit c07fa08f authored by Michael Chan's avatar Michael Chan Committed by David S. Miller

bnxt_en: Fix wrong flag value passed to HWRM_PORT_QSTATS_EXT fw call.

The wrong flag value caused the firmware call to return actual port
counters instead of the counter masks.  This messed up the counter
overflow logic and caused erratic extended port counters to be
displayed under ethtool -S.

Fixes: 531d1d26 ("bnxt_en: Retrieve hardware masks for port counters.")
Reviewed-by: default avatarEdwin Peer <edwin.peer@broadcom.com>
Signed-off-by: default avatarMichael Chan <michael.chan@broadcom.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent d2b42d01
...@@ -3853,7 +3853,7 @@ static void bnxt_init_stats(struct bnxt *bp) ...@@ -3853,7 +3853,7 @@ static void bnxt_init_stats(struct bnxt *bp)
tx_masks = stats->hw_masks; tx_masks = stats->hw_masks;
tx_count = sizeof(struct tx_port_stats_ext) / 8; tx_count = sizeof(struct tx_port_stats_ext) / 8;
flags = FUNC_QSTATS_EXT_REQ_FLAGS_COUNTER_MASK; flags = PORT_QSTATS_EXT_REQ_FLAGS_COUNTER_MASK;
rc = bnxt_hwrm_port_qstats_ext(bp, flags); rc = bnxt_hwrm_port_qstats_ext(bp, flags);
if (rc) { if (rc) {
mask = (1ULL << 40) - 1; mask = (1ULL << 40) - 1;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment