diff options
author | Bob Copeland <me@bobcopeland.com> | 2009-07-29 10:29:03 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-04 16:43:25 -0400 |
commit | ae6f53f25f9803212d1985b5eb5a03111f439c24 (patch) | |
tree | 6906896b6ca8cd95134fcf4ee893160d556c351d | |
parent | 57c9fff3d0c5d77bc7910717faeca4e8a018b1ee (diff) | |
download | blackbird-obmc-linux-ae6f53f25f9803212d1985b5eb5a03111f439c24.tar.gz blackbird-obmc-linux-ae6f53f25f9803212d1985b5eb5a03111f439c24.zip |
ath5k: update PCU opmode whenever a new interface is added
Previously, we would store the operating mode at interface up time,
but only update the PCU registers when the next reset happened.
The result is that if beacon configuration (ops->bss_info_changed)
happens before ops->config, we will program the wrong things into
the timer registers. Consequently, beacons won't work in AP mode
until after a reset (channel change, scan etc.).
This is fragile anyway so just program the opmode as soon as
mac80211 gives it to us.
Signed-off-by: Bob Copeland <me@bobcopeland.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
-rw-r--r-- | drivers/net/wireless/ath/ath5k/base.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath5k/base.c b/drivers/net/wireless/ath/ath5k/base.c index 7db32ce3dbd8..55ee976ab6d7 100644 --- a/drivers/net/wireless/ath/ath5k/base.c +++ b/drivers/net/wireless/ath/ath5k/base.c @@ -1117,6 +1117,8 @@ ath5k_mode_setup(struct ath5k_softc *sc) struct ath5k_hw *ah = sc->ah; u32 rfilt; + ah->ah_op_mode = sc->opmode; + /* configure rx filter */ rfilt = sc->filter_flags; ath5k_hw_set_rx_filter(ah, rfilt); @@ -2768,6 +2770,7 @@ static int ath5k_add_interface(struct ieee80211_hw *hw, } ath5k_hw_set_lladdr(sc->ah, conf->mac_addr); + ath5k_mode_setup(sc); ret = 0; end: |