diff options
author | Ron Rindjunsky <ron.rindjunsky@intel.com> | 2008-06-30 05:23:13 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-06-30 17:37:41 -0400 |
commit | 36e1f16ed293d47f052f3532f2fc74c1bfe9c09e (patch) | |
tree | 55bc3ccea197ae5a6b1b73e24e2868a87edaaf75 /drivers/net/wireless/iwlwifi | |
parent | 0c70515f2397b0e61a9961eba386a1277621a244 (diff) |
iwlwifi: remove obsolete lq_ready use
This patch removes the use of lq_ready, once used to sync between link
quality commands to avoid race conditions, but no longer needed as
bss_info_changed is in use.
Signed-off-by: Ron Rindjunsky <ron.rindjunsky@intel.com>
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-4965-rs.c | 19 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-4965-rs.h | 8 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-dev.h | 1 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-sta.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl4965-base.c | 3 |
5 files changed, 2 insertions, 32 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-rs.c b/drivers/net/wireless/iwlwifi/iwl-4965-rs.c index 202303117285..c2f21d79dfc2 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965-rs.c +++ b/drivers/net/wireless/iwlwifi/iwl-4965-rs.c | |||
@@ -822,9 +822,6 @@ static void rs_tx_status(void *priv_rate, struct net_device *dev, | |||
822 | 822 | ||
823 | lq_sta = (struct iwl4965_lq_sta *)sta->rate_ctrl_priv; | 823 | lq_sta = (struct iwl4965_lq_sta *)sta->rate_ctrl_priv; |
824 | 824 | ||
825 | if (!priv->lq_mngr.lq_ready) | ||
826 | goto out; | ||
827 | |||
828 | if ((priv->iw_mode == IEEE80211_IF_TYPE_IBSS) && | 825 | if ((priv->iw_mode == IEEE80211_IF_TYPE_IBSS) && |
829 | !lq_sta->ibss_sta_added) | 826 | !lq_sta->ibss_sta_added) |
830 | goto out; | 827 | goto out; |
@@ -1678,10 +1675,6 @@ static void rs_rate_scale_perform(struct iwl_priv *priv, | |||
1678 | if (!sta || !sta->rate_ctrl_priv) | 1675 | if (!sta || !sta->rate_ctrl_priv) |
1679 | return; | 1676 | return; |
1680 | 1677 | ||
1681 | if (!priv->lq_mngr.lq_ready) { | ||
1682 | IWL_DEBUG_RATE("still rate scaling not ready\n"); | ||
1683 | return; | ||
1684 | } | ||
1685 | lq_sta = (struct iwl4965_lq_sta *)sta->rate_ctrl_priv; | 1678 | lq_sta = (struct iwl4965_lq_sta *)sta->rate_ctrl_priv; |
1686 | 1679 | ||
1687 | tid = rs_tl_add_packet(lq_sta, hdr); | 1680 | tid = rs_tl_add_packet(lq_sta, hdr); |
@@ -2279,9 +2272,6 @@ static void rs_rate_init(void *priv_rate, void *priv_sta, | |||
2279 | lq_sta->drv = priv; | 2272 | lq_sta->drv = priv; |
2280 | #endif | 2273 | #endif |
2281 | 2274 | ||
2282 | if (priv->assoc_station_added) | ||
2283 | priv->lq_mngr.lq_ready = 1; | ||
2284 | |||
2285 | rs_initialize_lq(priv, conf, sta); | 2275 | rs_initialize_lq(priv, conf, sta); |
2286 | } | 2276 | } |
2287 | 2277 | ||
@@ -2421,7 +2411,7 @@ static void rs_clear(void *priv_rate) | |||
2421 | 2411 | ||
2422 | IWL_DEBUG_RATE("enter\n"); | 2412 | IWL_DEBUG_RATE("enter\n"); |
2423 | 2413 | ||
2424 | priv->lq_mngr.lq_ready = 0; | 2414 | /* TODO - add rate scale state reset */ |
2425 | 2415 | ||
2426 | IWL_DEBUG_RATE("leave\n"); | 2416 | IWL_DEBUG_RATE("leave\n"); |
2427 | } | 2417 | } |
@@ -2716,13 +2706,6 @@ int iwl4965_fill_rs_info(struct ieee80211_hw *hw, char *buf, u8 sta_id) | |||
2716 | return cnt; | 2706 | return cnt; |
2717 | } | 2707 | } |
2718 | 2708 | ||
2719 | void iwl4965_rate_scale_init(struct ieee80211_hw *hw, s32 sta_id) | ||
2720 | { | ||
2721 | struct iwl_priv *priv = hw->priv; | ||
2722 | |||
2723 | priv->lq_mngr.lq_ready = 1; | ||
2724 | } | ||
2725 | |||
2726 | int iwl4965_rate_control_register(void) | 2709 | int iwl4965_rate_control_register(void) |
2727 | { | 2710 | { |
2728 | return ieee80211_rate_control_register(&rs_ops); | 2711 | return ieee80211_rate_control_register(&rs_ops); |
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965-rs.h b/drivers/net/wireless/iwlwifi/iwl-4965-rs.h index cbd126418490..9b9972885aa5 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965-rs.h +++ b/drivers/net/wireless/iwlwifi/iwl-4965-rs.h | |||
@@ -296,14 +296,6 @@ static inline u8 iwl4965_get_prev_ieee_rate(u8 rate_index) | |||
296 | extern int iwl4965_fill_rs_info(struct ieee80211_hw *, char *buf, u8 sta_id); | 296 | extern int iwl4965_fill_rs_info(struct ieee80211_hw *, char *buf, u8 sta_id); |
297 | 297 | ||
298 | /** | 298 | /** |
299 | * iwl4965_rate_scale_init - Initialize the rate scale table based on assoc info | ||
300 | * | ||
301 | * The specific throughput table used is based on the type of network | ||
302 | * the associated with, including A, B, G, and G w/ TGG protection | ||
303 | */ | ||
304 | extern void iwl4965_rate_scale_init(struct ieee80211_hw *hw, s32 sta_id); | ||
305 | |||
306 | /** | ||
307 | * iwl4965_rate_control_register - Register the rate control algorithm callbacks | 299 | * iwl4965_rate_control_register - Register the rate control algorithm callbacks |
308 | * | 300 | * |
309 | * Since the rate control algorithm is hardware specific, there is no need | 301 | * Since the rate control algorithm is hardware specific, there is no need |
diff --git a/drivers/net/wireless/iwlwifi/iwl-dev.h b/drivers/net/wireless/iwlwifi/iwl-dev.h index 79a6941be5ab..d1289cfc213c 100644 --- a/drivers/net/wireless/iwlwifi/iwl-dev.h +++ b/drivers/net/wireless/iwlwifi/iwl-dev.h | |||
@@ -693,7 +693,6 @@ struct iwl4965_lq_mngr { | |||
693 | unsigned long stamp_last; | 693 | unsigned long stamp_last; |
694 | u32 flush_time; | 694 | u32 flush_time; |
695 | u32 tx_packets; | 695 | u32 tx_packets; |
696 | u8 lq_ready; | ||
697 | }; | 696 | }; |
698 | 697 | ||
699 | /* Sensitivity and chain noise calibration */ | 698 | /* Sensitivity and chain noise calibration */ |
diff --git a/drivers/net/wireless/iwlwifi/iwl-sta.c b/drivers/net/wireless/iwlwifi/iwl-sta.c index c81ab5f9830f..6d1467d0bd9d 100644 --- a/drivers/net/wireless/iwlwifi/iwl-sta.c +++ b/drivers/net/wireless/iwlwifi/iwl-sta.c | |||
@@ -825,8 +825,7 @@ int iwl_send_lq_cmd(struct iwl_priv *priv, | |||
825 | 825 | ||
826 | iwl_dump_lq_cmd(priv,lq); | 826 | iwl_dump_lq_cmd(priv,lq); |
827 | 827 | ||
828 | if (iwl_is_associated(priv) && priv->assoc_station_added && | 828 | if (iwl_is_associated(priv) && priv->assoc_station_added) |
829 | priv->lq_mngr.lq_ready) | ||
830 | return iwl_send_cmd(priv, &cmd); | 829 | return iwl_send_cmd(priv, &cmd); |
831 | 830 | ||
832 | return 0; | 831 | return 0; |
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c index a87e870f96d0..bb3e61c09cb4 100644 --- a/drivers/net/wireless/iwlwifi/iwl4965-base.c +++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c | |||
@@ -2483,7 +2483,6 @@ static void iwl4965_post_associate(struct iwl_priv *priv) | |||
2483 | 2483 | ||
2484 | switch (priv->iw_mode) { | 2484 | switch (priv->iw_mode) { |
2485 | case IEEE80211_IF_TYPE_STA: | 2485 | case IEEE80211_IF_TYPE_STA: |
2486 | iwl4965_rate_scale_init(priv->hw, IWL_AP_ID); | ||
2487 | break; | 2486 | break; |
2488 | 2487 | ||
2489 | case IEEE80211_IF_TYPE_IBSS: | 2488 | case IEEE80211_IF_TYPE_IBSS: |
@@ -2492,7 +2491,6 @@ static void iwl4965_post_associate(struct iwl_priv *priv) | |||
2492 | priv->assoc_id = 1; | 2491 | priv->assoc_id = 1; |
2493 | 2492 | ||
2494 | iwl_rxon_add_station(priv, priv->bssid, 0); | 2493 | iwl_rxon_add_station(priv, priv->bssid, 0); |
2495 | iwl4965_rate_scale_init(priv->hw, IWL_STA_ID); | ||
2496 | iwl4965_send_beacon_cmd(priv); | 2494 | iwl4965_send_beacon_cmd(priv); |
2497 | 2495 | ||
2498 | break; | 2496 | break; |
@@ -3425,7 +3423,6 @@ static void iwl4965_mac_reset_tsf(struct ieee80211_hw *hw) | |||
3425 | mutex_lock(&priv->mutex); | 3423 | mutex_lock(&priv->mutex); |
3426 | IWL_DEBUG_MAC80211("enter\n"); | 3424 | IWL_DEBUG_MAC80211("enter\n"); |
3427 | 3425 | ||
3428 | priv->lq_mngr.lq_ready = 0; | ||
3429 | spin_lock_irqsave(&priv->lock, flags); | 3426 | spin_lock_irqsave(&priv->lock, flags); |
3430 | memset(&priv->current_ht_config, 0, sizeof(struct iwl_ht_info)); | 3427 | memset(&priv->current_ht_config, 0, sizeof(struct iwl_ht_info)); |
3431 | spin_unlock_irqrestore(&priv->lock, flags); | 3428 | spin_unlock_irqrestore(&priv->lock, flags); |