aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/hw.c
diff options
context:
space:
mode:
authorSujith Manoharan <Sujith.Manoharan@atheros.com>2010-12-19 21:32:42 -0500
committerJohn W. Linville <linville@tuxdriver.com>2010-12-22 15:43:25 -0500
commit97dcec5715a381362c88d1542e52c63147764d3c (patch)
treeeddbe362c36a42441d9ebd8794be5cb6975fbfed /drivers/net/wireless/ath/ath9k/hw.c
parent3cfeb0c33f5cbcc6dde371392877ef3101b8f805 (diff)
ath9k_htc: Fix warning on device removal
The commit "ath9k_hw: warn if we cannot change the power to the chip" introduced a new warning to indicate chip powerup failures, but this is not required for devices that have been removed. Handle USB device removal properly by checking for unplugged status. For PCI devices, this warning will still be seen when the card is pulled out, not sure how to check for card removal. Signed-off-by: Sujith Manoharan <Sujith.Manoharan@atheros.com> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/hw.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/hw.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/drivers/net/wireless/ath/ath9k/hw.c b/drivers/net/wireless/ath/ath9k/hw.c
index 4b51ed47fe6..fde978665e0 100644
--- a/drivers/net/wireless/ath/ath9k/hw.c
+++ b/drivers/net/wireless/ath/ath9k/hw.c
@@ -1615,7 +1615,9 @@ bool ath9k_hw_setpower(struct ath_hw *ah, enum ath9k_power_mode mode)
1615 * simply keep the ATH_DBG_WARN_ON_ONCE() but make 1615 * simply keep the ATH_DBG_WARN_ON_ONCE() but make
1616 * ath9k_hw_setpower() return type void. 1616 * ath9k_hw_setpower() return type void.
1617 */ 1617 */
1618 ATH_DBG_WARN_ON_ONCE(!status); 1618
1619 if (!(ah->ah_flags & AH_UNPLUGGED))
1620 ATH_DBG_WARN_ON_ONCE(!status);
1619 1621
1620 return status; 1622 return status;
1621} 1623}