PERFORCE change 141151 for review

Sam Leffler sam at FreeBSD.org
Sun May 4 19:02:10 UTC 2008


http://perforce.freebsd.org/chv.cgi?CH=141151

Change 141151 by sam at sam_ebb on 2008/05/04 19:01:26

	add DFS capability bit

Affected files ...

.. //depot/projects/vap/sys/net80211/ieee80211.c#45 edit
.. //depot/projects/vap/sys/net80211/ieee80211_ddb.c#15 edit
.. //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#57 edit
.. //depot/projects/vap/sys/net80211/ieee80211_var.h#42 edit

Differences ...

==== //depot/projects/vap/sys/net80211/ieee80211.c#45 (text+ko) ====

@@ -386,9 +386,10 @@
 	if (vap->iv_opmode == IEEE80211_M_STA &&
 	    (vap->iv_caps & IEEE80211_C_BGSCAN))
 		vap->iv_flags |= IEEE80211_F_BGSCAN;
-	vap->iv_flags |= IEEE80211_F_DOTH;	/* XXX out of caps, just ena */
-	/* XXX out of caps, just ena */
-	if (vap->iv_opmode == IEEE80211_M_HOSTAP)
+	vap->iv_flags |= IEEE80211_F_DOTH;	/* XXX no cap, just ena */
+	/* NB: DFS support only makes sense for ap mode right now */
+	if (vap->iv_opmode == IEEE80211_M_HOSTAP &&
+	    (vap->iv_caps & IEEE80211_C_DFS))
 		vap->iv_flags_ext |= IEEE80211_FEXT_DFS;
 
 	vap->iv_des_chan = IEEE80211_CHAN_ANYC;		/* any channel is ok */

==== //depot/projects/vap/sys/net80211/ieee80211_ddb.c#15 (text+ko) ====

@@ -73,7 +73,7 @@
 #define	IEEE80211_C_BITS \
 	"\20\1STA\7FF\10TURBOP\11IBSS\12PMGT" \
 	"\13HOSTAP\14AHDEMO\15SWRETRY\16TXPMGT\17SHSLOT\20SHPREAMBLE" \
-	"\21MONITOR\30WPA1\31WPA2\32BURST\33WME\34WDS\36BGSCAN" \
+	"\21MONITOR\22DFS\30WPA1\31WPA2\32BURST\33WME\34WDS\36BGSCAN" \
 	"\37TXFRAG"
 
 #define	IEEE80211_C_CRYPTO_BITS \

==== //depot/projects/vap/sys/net80211/ieee80211_ioctl.c#57 (text+ko) ====

@@ -3027,11 +3027,8 @@
 		break;
 	case IEEE80211_IOC_DFS:
 		if (ireq->i_val) {
-#if 0
-			/* XXX no capability */
 			if ((vap->iv_caps & IEEE80211_C_DFS) == 0)
 				return EOPNOTSUPP;
-#endif
 			/* NB: DFS requires 11h support */
 			if ((vap->iv_flags & IEEE80211_F_DOTH) == 0)
 				return EINVAL;

==== //depot/projects/vap/sys/net80211/ieee80211_var.h#42 (text+ko) ====

@@ -505,7 +505,8 @@
 #define	IEEE80211_C_SHSLOT	0x00004000	/* CAPABILITY: short slottime */
 #define	IEEE80211_C_SHPREAMBLE	0x00008000	/* CAPABILITY: short preamble */
 #define	IEEE80211_C_MONITOR	0x00010000	/* CAPABILITY: monitor mode */
-/* 0x20000 available */
+#define	IEEE80211_C_DFS		0x00020000	/* CAPABILITY: DFS/radar avail*/
+/* 0x7c0000 available */
 #define	IEEE80211_C_WPA1	0x00800000	/* CAPABILITY: WPA1 avail */
 #define	IEEE80211_C_WPA2	0x01000000	/* CAPABILITY: WPA2 avail */
 #define	IEEE80211_C_WPA		0x01800000	/* CAPABILITY: WPA1+WPA2 avail*/


More information about the p4-projects mailing list