Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=247ae4492065ed73bf5f287e38cd4c54ce192b27 Commit: 247ae4492065ed73bf5f287e38cd4c54ce192b27 Parent: c65638a72c619e941bcb4006feded09fd358ad5f Author: John W. Linville <[EMAIL PROTECTED]> AuthorDate: Mon Jan 21 15:36:05 2008 -0500 Committer: David S. Miller <[EMAIL PROTECTED]> CommitDate: Mon Jan 28 15:10:48 2008 -0800
ath5k: reset key cache after resume Otherwise it may be impossible to connected to an open network after a resume. This is a modified version of an original patch by Alex Eskin <[EMAIL PROTECTED]>: https://bugzilla.redhat.com/show_bug.cgi?id=425950#c8 Signed-off-by: John W. Linville <[EMAIL PROTECTED]> --- 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 75e5970..5ff115d 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) { struct ieee80211_hw *hw = pci_get_drvdata(pdev); struct ath5k_softc *sc = hw->priv; - int err; + struct ath5k_hw *ah = sc->ah; + int i, err; err = pci_set_power_state(pdev, PCI_D0); if (err) @@ -624,10 +625,20 @@ ath5k_pci_resume(struct pci_dev *pdev) ath5k_init(sc); if (test_bit(ATH_STAT_LEDSOFT, sc->status)) { - ath5k_hw_set_gpio_output(sc->ah, sc->led_pin); - ath5k_hw_set_gpio(sc->ah, sc->led_pin, 0); + ath5k_hw_set_gpio_output(ah, sc->led_pin); + ath5k_hw_set_gpio(ah, sc->led_pin, 0); } + /* + * Reset the key cache since some parts do not + * reset the contents on initial power up or resume. + * + * FIXME: This may need to be revisited when mac80211 becomes + * aware of suspend/resume. + */ + for (i = 0; i < AR5K_KEYTABLE_SIZE; i++) + ath5k_hw_reset_key(ah, i); + return 0; } #endif /* CONFIG_PM */ - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html