svn commit: r288622 - head/sys/dev/usb/wlan
Adrian Chadd
adrian at FreeBSD.org
Sat Oct 3 17:34:12 UTC 2015
Author: adrian
Date: Sat Oct 3 17:34:11 2015
New Revision: 288622
URL: https://svnweb.freebsd.org/changeset/base/288622
Log:
rum(4): add support for AHDEMO mode.
Submitted by: <s3erios at gmail.com>
Differential Revision: https://reviews.freebsd.org/D3627
Modified:
head/sys/dev/usb/wlan/if_rum.c
Modified: head/sys/dev/usb/wlan/if_rum.c
==============================================================================
--- head/sys/dev/usb/wlan/if_rum.c Sat Oct 3 17:30:57 2015 (r288621)
+++ head/sys/dev/usb/wlan/if_rum.c Sat Oct 3 17:34:11 2015 (r288622)
@@ -489,6 +489,7 @@ rum_attach(device_t self)
| IEEE80211_C_IBSS /* IBSS mode supported */
| IEEE80211_C_MONITOR /* monitor mode supported */
| IEEE80211_C_HOSTAP /* HostAp mode supported */
+ | IEEE80211_C_AHDEMO /* adhoc demo mode */
| IEEE80211_C_TXPMGT /* tx power management */
| IEEE80211_C_SHPREAMBLE /* short preamble supported */
| IEEE80211_C_SHSLOT /* short slot time supported */
@@ -795,7 +796,8 @@ rum_newstate(struct ieee80211vap *vap, e
goto run_fail;
}
- if (vap->iv_opmode != IEEE80211_M_MONITOR) {
+ if (vap->iv_opmode != IEEE80211_M_MONITOR &&
+ vap->iv_opmode != IEEE80211_M_AHDEMO) {
if ((ret = rum_enable_tsf_sync(sc)) != 0)
goto run_fail;
} else
@@ -2360,7 +2362,10 @@ rum_scan_end(struct ieee80211com *ic)
struct rum_softc *sc = ic->ic_softc;
RUM_LOCK(sc);
- rum_enable_tsf_sync(sc);
+ if (ic->ic_opmode != IEEE80211_M_AHDEMO)
+ rum_enable_tsf_sync(sc);
+ else
+ rum_enable_tsf(sc);
rum_set_bssid(sc, sc->sc_bssid);
RUM_UNLOCK(sc);
More information about the svn-src-all
mailing list