diff options
author | Mintz Yuval <yuvalmin@broadcom.com> | 2012-02-15 02:10:22 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-02-15 15:30:48 -0500 |
commit | 1355b704b9ba44182a97c90b4480d79f0de8f040 (patch) | |
tree | 06250df554f95fa48f7480ef34128d60771a6c03 /drivers/net/ethernet/broadcom/bnx2x/bnx2x.h | |
parent | eb40d89276705a35c9a2e05793ae63411ae357eb (diff) | |
download | lwn-1355b704b9ba44182a97c90b4480d79f0de8f040.tar.gz lwn-1355b704b9ba44182a97c90b4480d79f0de8f040.zip |
bnx2x: consistent statistics after internal driver reload
Currently bnx2x statistics are reset by inner driver reload, e.g. by MTU
change. This patch fixes this issue - from now on statistics should only
be reset upon device closure.
Thanks to Michal Schmidt <mschmidt@redhat.com> for his initial patch
regarding this issue.
Signed-off-by: Yuval Mintz <yuvalmin@broadcom.com>
Signed-off-by: Eilon Greenstein <eilong@broadcom.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet/broadcom/bnx2x/bnx2x.h')
-rw-r--r-- | drivers/net/ethernet/broadcom/bnx2x/bnx2x.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/drivers/net/ethernet/broadcom/bnx2x/bnx2x.h b/drivers/net/ethernet/broadcom/bnx2x/bnx2x.h index 7d184fbffaf6..d60b5f073b6f 100644 --- a/drivers/net/ethernet/broadcom/bnx2x/bnx2x.h +++ b/drivers/net/ethernet/broadcom/bnx2x/bnx2x.h @@ -540,6 +540,7 @@ struct bnx2x_fastpath { struct ustorm_per_queue_stats old_uclient; struct xstorm_per_queue_stats old_xclient; struct bnx2x_eth_q_stats eth_q_stats; + struct bnx2x_eth_q_stats_old eth_q_stats_old; /* The size is calculated using the following: sizeof name field from netdev structure + @@ -1046,7 +1047,6 @@ struct bnx2x_slowpath { struct nig_stats nig_stats; struct host_port_stats port_stats; struct host_func_stats func_stats; - struct host_func_stats func_stats_base; u32 wb_comp; u32 wb_data[4]; @@ -1462,6 +1462,10 @@ struct bnx2x { u16 stats_counter; struct bnx2x_eth_stats eth_stats; + struct bnx2x_eth_stats_old eth_stats_old; + struct bnx2x_net_stats_old net_stats_old; + struct bnx2x_fw_port_stats_old fw_stats_old; + bool stats_init; struct z_stream_s *strm; void *gunzip_buf; |