aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-mac80211.c
diff options
context:
space:
mode:
authorEmmanuel Grumbach <emmanuel.grumbach@intel.com>2012-04-18 10:28:17 -0400
committerWey-Yi Guy <wey-yi.w.guy@intel.com>2012-04-18 10:29:43 -0400
commit68e8dfdadb424fd76ca81eeb399c3228adc5cea2 (patch)
treee8b641240ec3cdf61aa218d2c9d7e9c340683f69 /drivers/net/wireless/iwlwifi/iwl-mac80211.c
parent9130bab137844d9ad3db6ab524de299cd2b9e39d (diff)
iwlwifi: op_mode holds its pointer to the transport
Instead of using the shared area that we be killed. Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com> Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-mac80211.c')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-mac80211.c34
1 files changed, 17 insertions, 17 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-mac80211.c b/drivers/net/wireless/iwlwifi/iwl-mac80211.c
index 3f82ff4f3afe..20388ec8f9db 100644
--- a/drivers/net/wireless/iwlwifi/iwl-mac80211.c
+++ b/drivers/net/wireless/iwlwifi/iwl-mac80211.c
@@ -198,8 +198,8 @@ int iwlagn_mac_setup_register(struct iwl_priv *priv,
198 WIPHY_FLAG_IBSS_RSN; 198 WIPHY_FLAG_IBSS_RSN;
199 199
200 if (priv->fw->img[IWL_UCODE_WOWLAN].sec[0].len && 200 if (priv->fw->img[IWL_UCODE_WOWLAN].sec[0].len &&
201 trans(priv)->ops->wowlan_suspend && 201 priv->trans->ops->wowlan_suspend &&
202 device_can_wakeup(trans(priv)->dev)) { 202 device_can_wakeup(priv->trans->dev)) {
203 hw->wiphy->wowlan.flags = WIPHY_WOWLAN_MAGIC_PKT | 203 hw->wiphy->wowlan.flags = WIPHY_WOWLAN_MAGIC_PKT |
204 WIPHY_WOWLAN_DISCONNECT | 204 WIPHY_WOWLAN_DISCONNECT |
205 WIPHY_WOWLAN_EAP_IDENTITY_REQ | 205 WIPHY_WOWLAN_EAP_IDENTITY_REQ |
@@ -237,7 +237,7 @@ int iwlagn_mac_setup_register(struct iwl_priv *priv,
237 priv->hw->wiphy->bands[IEEE80211_BAND_5GHZ] = 237 priv->hw->wiphy->bands[IEEE80211_BAND_5GHZ] =
238 &priv->bands[IEEE80211_BAND_5GHZ]; 238 &priv->bands[IEEE80211_BAND_5GHZ];
239 239
240 hw->wiphy->hw_version = trans(priv)->hw_id; 240 hw->wiphy->hw_version = priv->trans->hw_id;
241 241
242 iwl_leds_init(priv); 242 iwl_leds_init(priv);
243 243
@@ -356,7 +356,7 @@ void iwlagn_mac_stop(struct ieee80211_hw *hw)
356 * even if interface is down, trans->down will leave the RF 356 * even if interface is down, trans->down will leave the RF
357 * kill interrupt enabled 357 * kill interrupt enabled
358 */ 358 */
359 iwl_trans_stop_hw(trans(priv)); 359 iwl_trans_stop_hw(priv->trans);
360 360
361 IWL_DEBUG_MAC80211(priv, "leave\n"); 361 IWL_DEBUG_MAC80211(priv, "leave\n");
362} 362}
@@ -412,9 +412,9 @@ int iwlagn_mac_suspend(struct ieee80211_hw *hw, struct cfg80211_wowlan *wowlan)
412 if (ret) 412 if (ret)
413 goto error; 413 goto error;
414 414
415 device_set_wakeup_enable(trans(priv)->dev, true); 415 device_set_wakeup_enable(priv->trans->dev, true);
416 416
417 iwl_trans_wowlan_suspend(trans(priv)); 417 iwl_trans_wowlan_suspend(priv->trans);
418 418
419 goto out; 419 goto out;
420 420
@@ -441,19 +441,19 @@ static int iwlagn_mac_resume(struct ieee80211_hw *hw)
441 IWL_DEBUG_MAC80211(priv, "enter\n"); 441 IWL_DEBUG_MAC80211(priv, "enter\n");
442 mutex_lock(&priv->mutex); 442 mutex_lock(&priv->mutex);
443 443
444 iwl_write32(trans(priv), CSR_UCODE_DRV_GP1_CLR, 444 iwl_write32(priv->trans, CSR_UCODE_DRV_GP1_CLR,
445 CSR_UCODE_DRV_GP1_BIT_D3_CFG_COMPLETE); 445 CSR_UCODE_DRV_GP1_BIT_D3_CFG_COMPLETE);
446 446
447 base = priv->device_pointers.error_event_table; 447 base = priv->device_pointers.error_event_table;
448 if (iwlagn_hw_valid_rtc_data_addr(base)) { 448 if (iwlagn_hw_valid_rtc_data_addr(base)) {
449 spin_lock_irqsave(&trans(priv)->reg_lock, flags); 449 spin_lock_irqsave(&priv->trans->reg_lock, flags);
450 ret = iwl_grab_nic_access_silent(trans(priv)); 450 ret = iwl_grab_nic_access_silent(priv->trans);
451 if (likely(ret == 0)) { 451 if (likely(ret == 0)) {
452 iwl_write32(trans(priv), HBUS_TARG_MEM_RADDR, base); 452 iwl_write32(priv->trans, HBUS_TARG_MEM_RADDR, base);
453 status = iwl_read32(trans(priv), HBUS_TARG_MEM_RDAT); 453 status = iwl_read32(priv->trans, HBUS_TARG_MEM_RDAT);
454 iwl_release_nic_access(trans(priv)); 454 iwl_release_nic_access(priv->trans);
455 } 455 }
456 spin_unlock_irqrestore(&trans(priv)->reg_lock, flags); 456 spin_unlock_irqrestore(&priv->trans->reg_lock, flags);
457 457
458#ifdef CONFIG_IWLWIFI_DEBUGFS 458#ifdef CONFIG_IWLWIFI_DEBUGFS
459 if (ret == 0) { 459 if (ret == 0) {
@@ -468,7 +468,7 @@ static int iwlagn_mac_resume(struct ieee80211_hw *hw)
468 468
469 if (priv->wowlan_sram) 469 if (priv->wowlan_sram)
470 _iwl_read_targ_mem_words( 470 _iwl_read_targ_mem_words(
471 trans(priv), 0x800000, 471 priv->trans, 0x800000,
472 priv->wowlan_sram, 472 priv->wowlan_sram,
473 img->sec[IWL_UCODE_SECTION_DATA].len / 4); 473 img->sec[IWL_UCODE_SECTION_DATA].len / 4);
474 } 474 }
@@ -480,7 +480,7 @@ static int iwlagn_mac_resume(struct ieee80211_hw *hw)
480 480
481 priv->wowlan = false; 481 priv->wowlan = false;
482 482
483 device_set_wakeup_enable(trans(priv)->dev, false); 483 device_set_wakeup_enable(priv->trans->dev, false);
484 484
485 iwlagn_prepare_restart(priv); 485 iwlagn_prepare_restart(priv);
486 486
@@ -654,7 +654,7 @@ int iwlagn_mac_ampdu_action(struct ieee80211_hw *hw,
654 ret = iwl_sta_rx_agg_stop(priv, sta, tid); 654 ret = iwl_sta_rx_agg_stop(priv, sta, tid);
655 break; 655 break;
656 case IEEE80211_AMPDU_TX_START: 656 case IEEE80211_AMPDU_TX_START:
657 if (!trans(priv)->ops->tx_agg_setup) 657 if (!priv->trans->ops->tx_agg_setup)
658 break; 658 break;
659 if (iwlagn_mod_params.disable_11n & IWL_DISABLE_HT_TXAGG) 659 if (iwlagn_mod_params.disable_11n & IWL_DISABLE_HT_TXAGG)
660 break; 660 break;
@@ -1006,7 +1006,7 @@ void iwlagn_mac_flush(struct ieee80211_hw *hw, bool drop)
1006 } 1006 }
1007 } 1007 }
1008 IWL_DEBUG_MAC80211(priv, "wait transmit/flush all frames\n"); 1008 IWL_DEBUG_MAC80211(priv, "wait transmit/flush all frames\n");
1009 iwl_trans_wait_tx_queue_empty(trans(priv)); 1009 iwl_trans_wait_tx_queue_empty(priv->trans);
1010done: 1010done:
1011 mutex_unlock(&priv->mutex); 1011 mutex_unlock(&priv->mutex);
1012 IWL_DEBUG_MAC80211(priv, "leave\n"); 1012 IWL_DEBUG_MAC80211(priv, "leave\n");