diff options
author | Luis R. Rodriguez <lrodriguez@atheros.com> | 2009-10-19 02:33:39 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-10-30 16:50:37 -0400 |
commit | dc51dd503953a8bed545d10eb89fb3340a98879b (patch) | |
tree | 891ce48b346f3457199026edc25a8141f38f6ab3 | |
parent | 431ba3c6dce0256eafde43af221504f99a2fcc0a (diff) |
ath9k_hw: rename ath9k_hw_rf_free() to ath9k_hw_rf_free_ext_banks()
This clarifies this is only required for external radios.
Signed-off-by: Luis R. Rodriguez <lrodriguez@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.c | 3 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/hw.h | 1 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/phy.c | 9 | ||||
-rw-r--r-- | drivers/net/wireless/ath/ath9k/phy.h | 2 |
4 files changed, 10 insertions, 5 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c index 2e2516e1cd4a..4c3ff2e429e7 100644 --- a/drivers/net/wireless/ath/ath9k/hw.c +++ b/drivers/net/wireless/ath/ath9k/hw.c | |||
@@ -1282,7 +1282,8 @@ void ath9k_hw_detach(struct ath_hw *ah) | |||
1282 | ath9k_hw_setpower(ah, ATH9K_PM_FULL_SLEEP); | 1282 | ath9k_hw_setpower(ah, ATH9K_PM_FULL_SLEEP); |
1283 | 1283 | ||
1284 | free_hw: | 1284 | free_hw: |
1285 | ath9k_hw_rf_free(ah); | 1285 | if (!AR_SREV_9280_10_OR_LATER(ah)) |
1286 | ath9k_hw_rf_free_ext_banks(ah); | ||
1286 | kfree(ah); | 1287 | kfree(ah); |
1287 | ah = NULL; | 1288 | ah = NULL; |
1288 | } | 1289 | } |
diff --git a/drivers/net/wireless/ath/ath9k/hw.h b/drivers/net/wireless/ath/ath9k/hw.h index 007b41426b27..7f2b5d21f2f1 100644 --- a/drivers/net/wireless/ath/ath9k/hw.h +++ b/drivers/net/wireless/ath/ath9k/hw.h | |||
@@ -628,7 +628,6 @@ static inline struct ath_regulatory *ath9k_hw_regulatory(struct ath_hw *ah) | |||
628 | const char *ath9k_hw_probe(u16 vendorid, u16 devid); | 628 | const char *ath9k_hw_probe(u16 vendorid, u16 devid); |
629 | void ath9k_hw_detach(struct ath_hw *ah); | 629 | void ath9k_hw_detach(struct ath_hw *ah); |
630 | int ath9k_hw_init(struct ath_hw *ah); | 630 | int ath9k_hw_init(struct ath_hw *ah); |
631 | void ath9k_hw_rf_free(struct ath_hw *ah); | ||
632 | int ath9k_hw_reset(struct ath_hw *ah, struct ath9k_channel *chan, | 631 | int ath9k_hw_reset(struct ath_hw *ah, struct ath9k_channel *chan, |
633 | bool bChannelChange); | 632 | bool bChannelChange); |
634 | void ath9k_hw_fill_cap_info(struct ath_hw *ah); | 633 | void ath9k_hw_fill_cap_info(struct ath_hw *ah); |
diff --git a/drivers/net/wireless/ath/ath9k/phy.c b/drivers/net/wireless/ath/ath9k/phy.c index 923ea0b45174..d50b5ff28b38 100644 --- a/drivers/net/wireless/ath/ath9k/phy.c +++ b/drivers/net/wireless/ath/ath9k/phy.c | |||
@@ -384,18 +384,20 @@ ath9k_hw_set_rf_regs(struct ath_hw *ah, struct ath9k_channel *chan, | |||
384 | } | 384 | } |
385 | 385 | ||
386 | /** | 386 | /** |
387 | * ath9k_hw_rf_free - Free memory for analog bank scratch buffers | 387 | * ath9k_hw_rf_free_ext_banks - Free memory for analog bank scratch buffers |
388 | * @ah: atheros hardware struture | 388 | * @ah: atheros hardware struture |
389 | * For the external AR2133/AR5133 radios. | 389 | * For the external AR2133/AR5133 radios banks. |
390 | */ | 390 | */ |
391 | void | 391 | void |
392 | ath9k_hw_rf_free(struct ath_hw *ah) | 392 | ath9k_hw_rf_free_ext_banks(struct ath_hw *ah) |
393 | { | 393 | { |
394 | #define ATH_FREE_BANK(bank) do { \ | 394 | #define ATH_FREE_BANK(bank) do { \ |
395 | kfree(bank); \ | 395 | kfree(bank); \ |
396 | bank = NULL; \ | 396 | bank = NULL; \ |
397 | } while (0); | 397 | } while (0); |
398 | 398 | ||
399 | BUG_ON(AR_SREV_9280_10_OR_LATER(ah)); | ||
400 | |||
399 | ATH_FREE_BANK(ah->analogBank0Data); | 401 | ATH_FREE_BANK(ah->analogBank0Data); |
400 | ATH_FREE_BANK(ah->analogBank1Data); | 402 | ATH_FREE_BANK(ah->analogBank1Data); |
401 | ATH_FREE_BANK(ah->analogBank2Data); | 403 | ATH_FREE_BANK(ah->analogBank2Data); |
@@ -405,6 +407,7 @@ ath9k_hw_rf_free(struct ath_hw *ah) | |||
405 | ATH_FREE_BANK(ah->analogBank7Data); | 407 | ATH_FREE_BANK(ah->analogBank7Data); |
406 | ATH_FREE_BANK(ah->addac5416_21); | 408 | ATH_FREE_BANK(ah->addac5416_21); |
407 | ATH_FREE_BANK(ah->bank6Temp); | 409 | ATH_FREE_BANK(ah->bank6Temp); |
410 | |||
408 | #undef ATH_FREE_BANK | 411 | #undef ATH_FREE_BANK |
409 | } | 412 | } |
410 | 413 | ||
diff --git a/drivers/net/wireless/ath/ath9k/phy.h b/drivers/net/wireless/ath/ath9k/phy.h index 0bbbfbcfe3f4..477b606d09fd 100644 --- a/drivers/net/wireless/ath/ath9k/phy.h +++ b/drivers/net/wireless/ath/ath9k/phy.h | |||
@@ -29,6 +29,8 @@ bool ath9k_hw_set_rf_regs(struct ath_hw *ah, | |||
29 | u16 modesIndex); | 29 | u16 modesIndex); |
30 | void ath9k_hw_decrease_chain_power(struct ath_hw *ah, | 30 | void ath9k_hw_decrease_chain_power(struct ath_hw *ah, |
31 | struct ath9k_channel *chan); | 31 | struct ath9k_channel *chan); |
32 | |||
33 | void ath9k_hw_rf_free_ext_banks(struct ath_hw *ah); | ||
32 | int ath9k_hw_rf_alloc_ext_banks(struct ath_hw *ah); | 34 | int ath9k_hw_rf_alloc_ext_banks(struct ath_hw *ah); |
33 | 35 | ||
34 | #define AR_PHY_BASE 0x9800 | 36 | #define AR_PHY_BASE 0x9800 |