1
0
mirror of git://projects.qi-hardware.com/openwrt-xburst.git synced 2024-11-24 03:11:32 +02:00

fix mode setup for ibss/ahdemo - preserve existing modes and use HOSTAP mode for AHDEMO instead of IBSS to prevent unwanted IBSS merges

git-svn-id: svn://svn.openwrt.org/openwrt/trunk@12884 3c298f89-4303-0410-b956-a3cf2f4a3e73
This commit is contained in:
nbd 2008-10-07 01:40:09 +00:00
parent e9fd938246
commit 14b88b01e8

View File

@ -0,0 +1,23 @@
--- a/ath/if_ath.c
+++ b/ath/if_ath.c
@@ -1260,7 +1260,10 @@
case IEEE80211_M_IBSS:
if ((sc->sc_nvaps != 0) && (ic->ic_opmode == IEEE80211_M_STA))
return NULL;
- ic_opmode = opmode;
+ if (ic->ic_opmode == IEEE80211_M_HOSTAP)
+ ic_opmode = ic->ic_opmode;
+ else
+ ic_opmode = opmode;
break;
case IEEE80211_M_AHDEMO:
case IEEE80211_M_MONITOR:
@@ -1455,7 +1458,7 @@
* frames. Other modes carry over directly to the HAL.
*/
if (ic->ic_opmode == IEEE80211_M_AHDEMO)
- sc->sc_opmode = HAL_M_IBSS;
+ sc->sc_opmode = HAL_M_HOSTAP;
else
sc->sc_opmode = (HAL_OPMODE) ic->ic_opmode; /* NB: compatible */