Search Linux Wireless

Re: [PATCH] ath5k: reset key cache after resume

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



2008/1/21, John W. Linville <linville@xxxxxxxxxxxxx>:
> 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 <alexeskin@xxxxxxxxx>:
>
>         https://bugzilla.redhat.com/show_bug.cgi?id=425950#c8
>
> Signed-off-by: John W. Linville <linville@xxxxxxxxxxxxx>
> ---
>  drivers/net/wireless/ath5k/base.c |   12 +++++++++++-
>  1 files changed, 11 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/wireless/ath5k/base.c b/drivers/net/wireless/ath5k/base.c
> index 75e5970..6ab4746 100644
> --- a/drivers/net/wireless/ath5k/base.c
> +++ b/drivers/net/wireless/ath5k/base.c
> @@ -604,7 +604,7 @@ ath5k_pci_resume(struct pci_dev *pdev)
>  {
>         struct ieee80211_hw *hw = pci_get_drvdata(pdev);
>         struct ath5k_softc *sc = hw->priv;
> -       int err;
> +       int i, err;
>
>         err = pci_set_power_state(pdev, PCI_D0);
>         if (err)
> @@ -628,6 +628,16 @@ ath5k_pci_resume(struct pci_dev *pdev)
>                 ath5k_hw_set_gpio(sc->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(sc->ah, i);
> +
>         return 0;
>  }
>  #endif /* CONFIG_PM */
> --
> 1.5.3.3
>

Thanx John ;-)

Acked-by: Nick Kossifidis <mickflemm@xxxxxxxxx>


-- 
GPG ID: 0xD21DB2DB
As you read this post global entropy rises. Have Fun ;-)
Nick
-
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Security]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux ATA RAID]     [Samba]     [Device Mapper]
  Powered by Linux