iwlwifi: fix clear statistics counter command
authorWey-Yi Guy <wey-yi.w.guy@intel.com>
Fri, 15 Jan 2010 21:43:33 +0000 (13:43 -0800)
committerJohn W. Linville <linville@tuxdriver.com>
Tue, 19 Jan 2010 21:25:08 +0000 (16:25 -0500)
When receive reply statistics command with "clear" mask, just reset the
accumulated statistics counters, but not the current statistics counters,
so the accumulated statistics counter can provide the correct
information.

Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwlwifi/iwl-rx.c

index 6f36b6e79f5e3db56d72fdcbcab1da493ae41e8a..10db973274526e2deef7796452998e3d4594631c 100644 (file)
@@ -638,8 +638,6 @@ void iwl_reply_statistics(struct iwl_priv *priv,
        struct iwl_rx_packet *pkt = rxb_addr(rxb);
 
        if (le32_to_cpu(pkt->u.stats.flag) & UCODE_STATISTICS_CLEAR_MSK) {
-               memset(&priv->statistics, 0,
-                       sizeof(struct iwl_notif_statistics));
 #ifdef CONFIG_IWLWIFI_DEBUG
                memset(&priv->accum_statistics, 0,
                        sizeof(struct iwl_notif_statistics));