PERFORCE change 64715 for review
Sam Leffler
sam at FreeBSD.org
Tue Nov 9 12:29:23 PST 2004
http://perforce.freebsd.org/chv.cgi?CH=64715
Change 64715 by sam at sam_ebb on 2004/11/09 20:28:57
add ibss merge; still need to fix beacons
Affected files ...
.. //depot/projects/wifi/sys/dev/ath/if_ath.c#14 edit
Differences ...
==== //depot/projects/wifi/sys/dev/ath/if_ath.c#14 (text+ko) ====
@@ -2200,6 +2200,23 @@
ATH_RSSI_LPF(ATH_NODE(ni)->an_halstats.ns_avgbrssi, rssi);
/* fall thru... */
case IEEE80211_FC0_SUBTYPE_PROBE_RESP:
+ if (ic->ic_opmode == IEEE80211_M_IBSS &&
+ ic->ic_state == IEEE80211_S_RUN) {
+ struct ath_hal *ah = sc->sc_ah;
+ /* XXX extend rstamp */
+ u_int64_t tsf = ath_hal_gettsf64(ah);
+
+ /*
+ * Handle ibss merge as needed; check the tsf on the
+ * frame before attempting the merge. The 802.11 spec
+ * says the station should change it's bssid to match
+ * the oldest station with the same ssid, where oldest
+ * is determined by the tsf.
+ */
+ if (le64toh(ni->ni_tstamp.tsf) >= tsf &&
+ ieee80211_ibss_merge(ic, ni))
+ ath_hal_setassocid(ah, ic->ic_bss->ni_bssid, 0);
+ }
break;
}
}
More information about the p4-projects
mailing list