diff options
-rw-r--r-- | drivers/net/wireless/ath5k/base.c | 17 |
1 files changed, 14 insertions, 3 deletions
diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c index 75e5970c0799..5ff115da91e3 100644 --- a/drivers/net/wireless/ath5k/base.c +++ b/drivers/net/wireless/ath5k/base.c | |||
@@ -604,7 +604,8 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
604 | { | 604 | { |
605 | struct ieee80211_hw *hw = pci_get_drvdata(pdev); | 605 | struct ieee80211_hw *hw = pci_get_drvdata(pdev); |
606 | struct ath5k_softc *sc = hw->priv; | 606 | struct ath5k_softc *sc = hw->priv; |
607 | int err; | 607 | struct ath5k_hw *ah = sc->ah; |
608 | int i, err; | ||
608 | 609 | ||
609 | err = pci_set_power_state(pdev, PCI_D0); | 610 | err = pci_set_power_state(pdev, PCI_D0); |
610 | if (err) | 611 | if (err) |
@@ -624,10 +625,20 @@ ath5k_pci_resume(struct pci_dev *pdev) | |||
624 | 625 | ||
625 | ath5k_init(sc); | 626 | ath5k_init(sc); |
626 | if (test_bit(ATH_STAT_LEDSOFT, sc->status)) { | 627 | if (test_bit(ATH_STAT_LEDSOFT, sc->status)) { |
627 | ath5k_hw_set_gpio_output(sc->ah, sc->led_pin); | 628 | ath5k_hw_set_gpio_output(ah, sc->led_pin); |
628 | ath5k_hw_set_gpio(sc->ah, sc->led_pin, 0); | 629 | ath5k_hw_set_gpio(ah, sc->led_pin, 0); |
629 | } | 630 | } |
630 | 631 | ||
632 | /* | ||
633 | * Reset the key cache since some parts do not | ||
634 | * reset the contents on initial power up or resume. | ||
635 | * | ||
636 | * FIXME: This may need to be revisited when mac80211 becomes | ||
637 | * aware of suspend/resume. | ||
638 | */ | ||
639 | for (i = 0; i < AR5K_KEYTABLE_SIZE; i++) | ||
640 | ath5k_hw_reset_key(ah, i); | ||
641 | |||
631 | return 0; | 642 | return 0; |
632 | } | 643 | } |
633 | #endif /* CONFIG_PM */ | 644 | #endif /* CONFIG_PM */ |