diff options
author | Felix Fietkau <nbd@openwrt.org> | 2010-05-13 14:37:24 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-05-25 11:12:54 -0400 |
commit | 774610e4f26cb3d9da14a8b5974324c9e51017bd (patch) | |
tree | 418441d85667352270052c98da4a26ae8d878eca /drivers/net/wireless/ath/ath9k/beacon.c | |
parent | ededf1f82ac8f06a0311097a68ccb582d32e70d5 (diff) |
ath9k: change beacon allocation to prefer the first beacon slot
This fixes IBSS beacon transmissions without VEOL enabled
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/beacon.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/beacon.c | 12 |
1 files changed, 3 insertions, 9 deletions
diff --git a/drivers/net/wireless/ath/ath9k/beacon.c b/drivers/net/wireless/ath/ath9k/beacon.c index c8a4558f79b..77face76e05 100644 --- a/drivers/net/wireless/ath/ath9k/beacon.c +++ b/drivers/net/wireless/ath/ath9k/beacon.c | |||
@@ -274,17 +274,11 @@ int ath_beacon_alloc(struct ath_wiphy *aphy, struct ieee80211_vif *vif) | |||
274 | avp->av_bslot = 0; | 274 | avp->av_bslot = 0; |
275 | for (slot = 0; slot < ATH_BCBUF; slot++) | 275 | for (slot = 0; slot < ATH_BCBUF; slot++) |
276 | if (sc->beacon.bslot[slot] == NULL) { | 276 | if (sc->beacon.bslot[slot] == NULL) { |
277 | /* | ||
278 | * XXX hack, space out slots to better | ||
279 | * deal with misses | ||
280 | */ | ||
281 | if (slot+1 < ATH_BCBUF && | ||
282 | sc->beacon.bslot[slot+1] == NULL) { | ||
283 | avp->av_bslot = slot+1; | ||
284 | break; | ||
285 | } | ||
286 | avp->av_bslot = slot; | 277 | avp->av_bslot = slot; |
278 | |||
287 | /* NB: keep looking for a double slot */ | 279 | /* NB: keep looking for a double slot */ |
280 | if (slot == 0 || !sc->beacon.bslot[slot-1]) | ||
281 | break; | ||
288 | } | 282 | } |
289 | BUG_ON(sc->beacon.bslot[avp->av_bslot] != NULL); | 283 | BUG_ON(sc->beacon.bslot[avp->av_bslot] != NULL); |
290 | sc->beacon.bslot[avp->av_bslot] = vif; | 284 | sc->beacon.bslot[avp->av_bslot] = vif; |