aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/ath/ath9k/recv.c
diff options
context:
space:
mode:
authorJan Friedrich <jft@dev2day.de>2010-08-02 17:55:50 -0400
committerJohn W. Linville <linville@tuxdriver.com>2010-08-04 15:28:37 -0400
commitc8f3b7213342d905cbb75d6c8820d9141205f3a0 (patch)
tree9ce37980157138280c19ea2de739c876af68d880 /drivers/net/wireless/ath/ath9k/recv.c
parent5f7aebd845a9d2ed42f36b7333579ec3534b4713 (diff)
ath9k: fix erased ieee80211_rx_status.mactime
ath9k_rx_skb_preprocess nulls rxs and the mactime is never set again - mactime is always 0. This causes problems in IBSS mode. ieee80211_rx_bss_info uses mactime to decide if an IBSS merge is needed. Without this patch the merge is triggered by each beacon received. This can be recognized by the "beacon TSF higher than local TSF - IBSS merge with BSSID" log message accompanying each beacon. This problem was not completely fixed in commit a6d2055b02dde1067075795274672720baadd3ca and is not a stable kernel fix. It is solely intended for wireless-testing. Signed-off-by: Jan Friedrich <jft@dev2day.de> Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/recv.c')
-rw-r--r--drivers/net/wireless/ath/ath9k/recv.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/drivers/net/wireless/ath/ath9k/recv.c b/drivers/net/wireless/ath/ath9k/recv.c
index da0cfe90c38a..a3fc987ebab0 100644
--- a/drivers/net/wireless/ath/ath9k/recv.c
+++ b/drivers/net/wireless/ath/ath9k/recv.c
@@ -1140,6 +1140,11 @@ int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp)
1140 if (flush) 1140 if (flush)
1141 goto requeue; 1141 goto requeue;
1142 1142
1143 retval = ath9k_rx_skb_preprocess(common, hw, hdr, &rs,
1144 rxs, &decrypt_error);
1145 if (retval)
1146 goto requeue;
1147
1143 rxs->mactime = (tsf & ~0xffffffffULL) | rs.rs_tstamp; 1148 rxs->mactime = (tsf & ~0xffffffffULL) | rs.rs_tstamp;
1144 if (rs.rs_tstamp > tsf_lower && 1149 if (rs.rs_tstamp > tsf_lower &&
1145 unlikely(rs.rs_tstamp - tsf_lower > 0x10000000)) 1150 unlikely(rs.rs_tstamp - tsf_lower > 0x10000000))
@@ -1149,11 +1154,6 @@ int ath_rx_tasklet(struct ath_softc *sc, int flush, bool hp)
1149 unlikely(tsf_lower - rs.rs_tstamp > 0x10000000)) 1154 unlikely(tsf_lower - rs.rs_tstamp > 0x10000000))
1150 rxs->mactime += 0x100000000ULL; 1155 rxs->mactime += 0x100000000ULL;
1151 1156
1152 retval = ath9k_rx_skb_preprocess(common, hw, hdr, &rs,
1153 rxs, &decrypt_error);
1154 if (retval)
1155 goto requeue;
1156
1157 /* Ensure we always have an skb to requeue once we are done 1157 /* Ensure we always have an skb to requeue once we are done
1158 * processing the current buffer's skb */ 1158 * processing the current buffer's skb */
1159 requeue_skb = ath_rxbuf_alloc(common, common->rx_bufsize, GFP_ATOMIC); 1159 requeue_skb = ath_rxbuf_alloc(common, common->rx_bufsize, GFP_ATOMIC);