From 1e375f3aa7a92e173c3e867f8324570ab4668669 Mon Sep 17 00:00:00 2001 From: "Bjoern A. Zeeb" Date: Wed, 7 Oct 2020 21:56:58 +0000 Subject: [PATCH] 80211: non-functional changes Sort a few VHT160 and 80+80 lines, update some comments, and remove a superfluous ','. No functional changes intended. MFC after: 1 week Sponsored by: The FreeBSD Foundation --- lib/lib80211/lib80211_regdomain.c | 2 +- sbin/ifconfig/ifieee80211.c | 3 +-- sys/net80211/ieee80211.c | 12 ++++++------ sys/net80211/ieee80211_node.h | 2 +- 4 files changed, 9 insertions(+), 10 deletions(-) diff --git a/lib/lib80211/lib80211_regdomain.c b/lib/lib80211/lib80211_regdomain.c index 8dfd435e07a0..f5ed236467f5 100644 --- a/lib/lib80211/lib80211_regdomain.c +++ b/lib/lib80211/lib80211_regdomain.c @@ -191,11 +191,11 @@ decode_flag(struct mystate *mt, const char *p, int len) FLAG(IEEE80211_CHAN_VHT20), FLAG(IEEE80211_CHAN_VHT40), FLAG(IEEE80211_CHAN_VHT80), + FLAG(IEEE80211_CHAN_VHT160), /* * XXX VHT80P80? This likely should be done by * 80MHz chan logic in net80211 / ifconfig. */ - FLAG(IEEE80211_CHAN_VHT160), FLAG(IEEE80211_CHAN_ST), FLAG(IEEE80211_CHAN_TURBO), FLAG(IEEE80211_CHAN_PASSIVE), diff --git a/sbin/ifconfig/ifieee80211.c b/sbin/ifconfig/ifieee80211.c index d7794be320e5..e27623ecef5e 100644 --- a/sbin/ifconfig/ifieee80211.c +++ b/sbin/ifconfig/ifieee80211.c @@ -2385,8 +2385,7 @@ regdomain_makechannels( &dc->dc_chaninfo); } - /* VHT80 */ - /* XXX dc_vhtcap? */ + /* VHT80 is mandatory (and so should be VHT40 above). */ if (1) { regdomain_addchans(ci, &rd->bands_11ac, reg, IEEE80211_CHAN_A | IEEE80211_CHAN_HT40U | diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c index 68a13ec8b2f1..766b2b1bdfeb 100644 --- a/sys/net80211/ieee80211.c +++ b/sys/net80211/ieee80211.c @@ -158,7 +158,7 @@ ieee80211_chan_init(struct ieee80211com *ic) /* * Setup the HT40/VHT40 upper/lower bits. - * The VHT80 math is done elsewhere. + * The VHT80/... math is done elsewhere. */ if (IEEE80211_IS_CHAN_HT40(c) && c->ic_extieee == 0) c->ic_extieee = ieee80211_mhz2ieee(c->ic_freq + @@ -167,8 +167,8 @@ ieee80211_chan_init(struct ieee80211com *ic) /* Update VHT math */ /* - * XXX VHT again, note that this assumes VHT80 channels - * are legit already + * XXX VHT again, note that this assumes VHT80/... channels + * are legit already. */ set_vht_extchan(c); @@ -712,8 +712,8 @@ ieee80211_vap_attach(struct ieee80211vap *vap, ifm_change_cb_t media_change, ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_VHT); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT40); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80); - ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80P80); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT160); + ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80P80); IEEE80211_UNLOCK(ic); return 1; @@ -767,8 +767,8 @@ ieee80211_vap_detach(struct ieee80211vap *vap) ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_VHT); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT40); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80); - ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80P80); ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT160); + ieee80211_syncflag_vht_locked(ic, IEEE80211_FVHT_USEVHT80P80); /* NB: this handles the bpfdetach done below */ ieee80211_syncflag_ext_locked(ic, IEEE80211_FEXT_BPF); @@ -1160,7 +1160,7 @@ struct vht_chan_range vht80_chan_ranges[] = { { 5570, 5650 }, { 5650, 5730 }, { 5735, 5815 }, - { 0, 0, } + { 0, 0 } }; static int diff --git a/sys/net80211/ieee80211_node.h b/sys/net80211/ieee80211_node.h index ff826d30ca72..07144fa0adb3 100644 --- a/sys/net80211/ieee80211_node.h +++ b/sys/net80211/ieee80211_node.h @@ -70,7 +70,7 @@ struct ieee80211vap; struct ieee80211_scanparams; /* - * Information element ``blob''. We use this structure + * Information element (IE) ``blob''. We use this structure * to capture management frame payloads that need to be * retained. Information elements within the payload that * we need to consult have references recorded.