From owner-p4-projects@FreeBSD.ORG Sun May 4 19:02:09 2008 Return-Path: Delivered-To: p4-projects@freebsd.org Received: by hub.freebsd.org (Postfix, from userid 32767) id A4A521065676; Sun, 4 May 2008 19:02:09 +0000 (UTC) Delivered-To: perforce@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 65EC81065671 for ; Sun, 4 May 2008 19:02:09 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (repoman.freebsd.org [IPv6:2001:4f8:fff6::29]) by mx1.freebsd.org (Postfix) with ESMTP id 675AF8FC19 for ; Sun, 4 May 2008 19:02:09 +0000 (UTC) (envelope-from sam@freebsd.org) Received: from repoman.freebsd.org (localhost [127.0.0.1]) by repoman.freebsd.org (8.14.1/8.14.1) with ESMTP id m44J292J066345 for ; Sun, 4 May 2008 19:02:09 GMT (envelope-from sam@freebsd.org) Received: (from perforce@localhost) by repoman.freebsd.org (8.14.1/8.14.1/Submit) id m44J29T3066343 for perforce@freebsd.org; Sun, 4 May 2008 19:02:09 GMT (envelope-from sam@freebsd.org) Date: Sun, 4 May 2008 19:02:09 GMT Message-Id: <200805041902.m44J29T3066343@repoman.freebsd.org> X-Authentication-Warning: repoman.freebsd.org: perforce set sender to sam@freebsd.org using -f From: Sam Leffler To: Perforce Change Reviews Cc: Subject: PERFORCE change 141151 for review X-BeenThere: p4-projects@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: p4 projects tree changes List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 04 May 2008 19:02:10 -0000 http://perforce.freebsd.org/chv.cgi?CH=141151 Change 141151 by sam@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*/