Skip to content

Commit

Permalink
ath9k: fix ibss beacon next tbtt
Browse files Browse the repository at this point in the history
Sync-up ibss beacon timer with the beacon frame's timestamp. When the
node acts as joiner, it has to sync with the received beacon timestamp
instead of reading tsf from hw. As the hw tsf wont wont be update till
bssid is configured. This patch programs hw tsf with the received beacon
timestamp if beacon timers are yet to be configured.

Signed-off-by: Rajkumar Manoharan <[email protected]>
Signed-off-by: John W. Linville <[email protected]>
  • Loading branch information
Rajkumar Manoharan authored and linvjw committed Apr 16, 2012
1 parent 3e5217e commit de5f8fc
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions drivers/net/wireless/ath/ath9k/beacon.c
Original file line number Diff line number Diff line change
Expand Up @@ -653,6 +653,8 @@ static void ath_beacon_config_adhoc(struct ath_softc *sc,
u32 tsf, intval, nexttbtt;

ath9k_reset_beacon_status(sc);
if (!(sc->sc_flags & SC_OP_BEACONS))
ath9k_hw_settsf64(ah, sc->beacon.bc_tstamp);

intval = TU_TO_USEC(conf->beacon_interval);
tsf = roundup(ath9k_hw_gettsf32(ah) + TU_TO_USEC(FUDGE), intval);
Expand Down

0 comments on commit de5f8fc

Please sign in to comment.