]> git.kernelconcepts.de Git - karo-tx-linux.git/commitdiff
iwlwifi: remove ack_check module parameter
authorJohannes Berg <johannes.berg@intel.com>
Tue, 10 Apr 2012 00:46:56 +0000 (17:46 -0700)
committerJohn W. Linville <linville@tuxdriver.com>
Thu, 12 Apr 2012 19:06:09 +0000 (15:06 -0400)
This defaults to false, and we don't recommend
to use it anywhere, so just remove it.

Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/iwlwifi/iwl-agn-rx.c
drivers/net/wireless/iwlwifi/iwl-agn.c
drivers/net/wireless/iwlwifi/iwl-shared.h

index e12f11d50b88f72bcf2d87d1cf8dc0f53bd5eb7e..25abbb9b5e071b498b6582c56aafe2bc47bb8ffc 100644 (file)
@@ -246,69 +246,6 @@ static int iwlagn_rx_beacon_notif(struct iwl_priv *priv,
        return 0;
 }
 
-/* the threshold ratio of actual_ack_cnt to expected_ack_cnt in percent */
-#define ACK_CNT_RATIO (50)
-#define BA_TIMEOUT_CNT (5)
-#define BA_TIMEOUT_MAX (16)
-
-/**
- * iwl_good_ack_health - checks for ACK count ratios, BA timeout retries.
- *
- * When the ACK count ratio is low and aggregated BA timeout retries exceeding
- * the BA_TIMEOUT_MAX, reload firmware and bring system back to normal
- * operation state.
- */
-static bool iwlagn_good_ack_health(struct iwl_priv *priv,
-                               struct statistics_tx *cur)
-{
-       int actual_delta, expected_delta, ba_timeout_delta;
-       struct statistics_tx *old;
-
-       if (priv->agg_tids_count)
-               return true;
-
-       lockdep_assert_held(&priv->statistics.lock);
-
-       old = &priv->statistics.tx;
-
-       actual_delta = le32_to_cpu(cur->actual_ack_cnt) -
-                      le32_to_cpu(old->actual_ack_cnt);
-       expected_delta = le32_to_cpu(cur->expected_ack_cnt) -
-                        le32_to_cpu(old->expected_ack_cnt);
-
-       /* Values should not be negative, but we do not trust the firmware */
-       if (actual_delta <= 0 || expected_delta <= 0)
-               return true;
-
-       ba_timeout_delta = le32_to_cpu(cur->agg.ba_timeout) -
-                          le32_to_cpu(old->agg.ba_timeout);
-
-       if ((actual_delta * 100 / expected_delta) < ACK_CNT_RATIO &&
-           ba_timeout_delta > BA_TIMEOUT_CNT) {
-               IWL_DEBUG_RADIO(priv,
-                       "deltas: actual %d expected %d ba_timeout %d\n",
-                       actual_delta, expected_delta, ba_timeout_delta);
-
-#ifdef CONFIG_IWLWIFI_DEBUGFS
-               /*
-                * This is ifdef'ed on DEBUGFS because otherwise the
-                * statistics aren't available. If DEBUGFS is set but
-                * DEBUG is not, these will just compile out.
-                */
-               IWL_DEBUG_RADIO(priv, "rx_detected_cnt delta %d\n",
-                               priv->delta_stats.tx.rx_detected_cnt);
-               IWL_DEBUG_RADIO(priv,
-                               "ack_or_ba_timeout_collision delta %d\n",
-                               priv->delta_stats.tx.ack_or_ba_timeout_collision);
-#endif
-
-               if (ba_timeout_delta >= BA_TIMEOUT_MAX)
-                       return false;
-       }
-
-       return true;
-}
-
 /**
  * iwl_good_plcp_health - checks for plcp error.
  *
@@ -368,12 +305,6 @@ static void iwlagn_recover_from_statistics(struct iwl_priv *priv,
        if (msecs < 99)
                return;
 
-       if (iwlagn_mod_params.ack_check && !iwlagn_good_ack_health(priv, tx)) {
-               IWL_ERR(priv, "low ack count detected, restart firmware\n");
-               if (!iwl_force_reset(priv, IWL_FW_RESET, false))
-                       return;
-       }
-
        if (iwlagn_mod_params.plcp_check &&
            !iwlagn_good_plcp_health(priv, cur_ofdm, cur_ofdm_ht, msecs))
                iwl_force_reset(priv, IWL_RF_RESET, false);
index 9e320c1e79f86333fbc35cc837bbba3da5ce8b36..096c227640a7aeaf1273fd25d0321f8f9f404b56 100644 (file)
@@ -2281,9 +2281,6 @@ MODULE_PARM_DESC(bt_ch_inhibition,
 module_param_named(plcp_check, iwlagn_mod_params.plcp_check, bool, S_IRUGO);
 MODULE_PARM_DESC(plcp_check, "Check plcp health (default: 1 [enabled])");
 
-module_param_named(ack_check, iwlagn_mod_params.ack_check, bool, S_IRUGO);
-MODULE_PARM_DESC(ack_check, "Check ack health (default: 0 [disabled])");
-
 module_param_named(wd_disable, iwlagn_mod_params.wd_disable, int, S_IRUGO);
 MODULE_PARM_DESC(wd_disable,
                "Disable stuck queue watchdog timer 0=system default, "
index c6de9309658236707c0c5e3aca910a882262cb05..c6325c5df6c1e6d73bf6651e0adad7aa9a5229c3 100644 (file)
@@ -121,7 +121,6 @@ extern struct iwl_mod_params iwlagn_mod_params;
  * @antenna: both antennas (use diversity), default = 0
  * @restart_fw: restart firmware, default = 1
  * @plcp_check: enable plcp health check, default = true
- * @ack_check: disable ack health check, default = false
  * @wd_disable: enable stuck queue check, default = 0
  * @bt_coex_active: enable bt coex, default = true
  * @led_mode: system default, default = 0
@@ -141,7 +140,6 @@ struct iwl_mod_params {
        int antenna;
        int restart_fw;
        bool plcp_check;
-       bool ack_check;
        int  wd_disable;
        bool bt_coex_active;
        int led_mode;