Search Linux Wireless

Re: [PATCH 03/13] ath5k: preserve antenna settings

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

 



2010/3/9 Bruno Randolf <br1@xxxxxxxxxxx>:
> save antenna settings and preserve across resets.
>
> Signed-off-by: Bruno Randolf <br1@xxxxxxxxxxx>
> ---
>  drivers/net/wireless/ath/ath5k/attach.c |    1 +
>  drivers/net/wireless/ath/ath5k/base.c   |    2 +-
>  drivers/net/wireless/ath/ath5k/phy.c    |    1 +
>  3 files changed, 3 insertions(+), 1 deletions(-)
>
> diff --git a/drivers/net/wireless/ath/ath5k/attach.c b/drivers/net/wireless/ath/ath5k/attach.c
> index 4228444..c8bb102 100644
> --- a/drivers/net/wireless/ath/ath5k/attach.c
> +++ b/drivers/net/wireless/ath/ath5k/attach.c
> @@ -123,6 +123,7 @@ int ath5k_hw_attach(struct ath5k_softc *sc)
>        ah->ah_cw_min = AR5K_TUNE_CWMIN;
>        ah->ah_limit_tx_retries = AR5K_INIT_TX_RETRY;
>        ah->ah_software_retry = false;
> +       ah->ah_ant_mode = AR5K_ANTMODE_DEFAULT;
>
>        /*
>         * Find the mac version
> diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c
> index 85eb670..fd4dd3c 100644
> --- a/drivers/net/wireless/ath/ath5k/base.c
> +++ b/drivers/net/wireless/ath/ath5k/base.c
> @@ -2916,7 +2916,7 @@ ath5k_config(struct ieee80211_hw *hw, u32 changed)
>         * then we must allow the user to set how many tx antennas we
>         * have available
>         */
> -       ath5k_hw_set_antenna_mode(ah, AR5K_ANTMODE_DEFAULT);
> +       ath5k_hw_set_antenna_mode(ah, ah->ah_ant_mode);
>
>  unlock:
>        mutex_unlock(&sc->lock);
> diff --git a/drivers/net/wireless/ath/ath5k/phy.c b/drivers/net/wireless/ath/ath5k/phy.c
> index ffe253a..3fa4f4d 100644
> --- a/drivers/net/wireless/ath/ath5k/phy.c
> +++ b/drivers/net/wireless/ath/ath5k/phy.c
> @@ -1929,6 +1929,7 @@ ath5k_hw_set_antenna_mode(struct ath5k_hw *ah, u8 ant_mode)
>
>        ah->ah_tx_ant = tx_ant;
>        ah->ah_ant_mode = ant_mode;
> +       ah->ah_def_ant = def_ant;
>
>        sta_id1 |= use_def_for_tx ? AR5K_STA_ID1_DEFAULT_ANTENNA : 0;
>        sta_id1 |= update_def_on_tx ? AR5K_STA_ID1_DESC_ANTENNA : 0;
>
> --
> 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
>

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