aboutsummaryrefslogtreecommitdiff
path: root/sys/net80211
diff options
context:
space:
mode:
authorBjoern A. Zeeb <bz@FreeBSD.org>2020-08-23 21:37:20 +0000
committerBjoern A. Zeeb <bz@FreeBSD.org>2020-08-23 21:37:20 +0000
commit30fdd33ca35dceb87c8ba051b9957d9766333582 (patch)
tree100f0e25dbbd9e68d0b82d7a4cc77c7a18a54c2c /sys/net80211
parentf0d9c77e5218267d32debfe03b807daa91fba61d (diff)
Notes
Diffstat (limited to 'sys/net80211')
-rw-r--r--sys/net80211/ieee80211.c35
1 files changed, 22 insertions, 13 deletions
diff --git a/sys/net80211/ieee80211.c b/sys/net80211/ieee80211.c
index 63a14d6a6dd6..38d749876452 100644
--- a/sys/net80211/ieee80211.c
+++ b/sys/net80211/ieee80211.c
@@ -1168,23 +1168,17 @@ set_vht_extchan(struct ieee80211_channel *c)
{
int i;
- if (! IEEE80211_IS_CHAN_VHT(c)) {
+ if (! IEEE80211_IS_CHAN_VHT(c))
return (0);
- }
- if (IEEE80211_IS_CHAN_VHT20(c)) {
- c->ic_vht_ch_freq1 = c->ic_ieee;
- return (1);
+ if (IEEE80211_IS_CHAN_VHT80P80(c)) {
+ printf("%s: TODO VHT80+80 channel (ieee=%d, flags=0x%08x)\n",
+ __func__, c->ic_ieee, c->ic_flags);
}
- if (IEEE80211_IS_CHAN_VHT40(c)) {
- if (IEEE80211_IS_CHAN_HT40U(c))
- c->ic_vht_ch_freq1 = c->ic_ieee + 2;
- else if (IEEE80211_IS_CHAN_HT40D(c))
- c->ic_vht_ch_freq1 = c->ic_ieee - 2;
- else
- return (0);
- return (1);
+ if (IEEE80211_IS_CHAN_VHT160(c)) {
+ printf("%s: TODO VHT160 channel (ieee=%d, flags=0x%08x)\n",
+ __func__, c->ic_ieee, c->ic_flags);
}
if (IEEE80211_IS_CHAN_VHT80(c)) {
@@ -1208,6 +1202,21 @@ set_vht_extchan(struct ieee80211_channel *c)
return (0);
}
+ if (IEEE80211_IS_CHAN_VHT40(c)) {
+ if (IEEE80211_IS_CHAN_HT40U(c))
+ c->ic_vht_ch_freq1 = c->ic_ieee + 2;
+ else if (IEEE80211_IS_CHAN_HT40D(c))
+ c->ic_vht_ch_freq1 = c->ic_ieee - 2;
+ else
+ return (0);
+ return (1);
+ }
+
+ if (IEEE80211_IS_CHAN_VHT20(c)) {
+ c->ic_vht_ch_freq1 = c->ic_ieee;
+ return (1);
+ }
+
printf("%s: unknown VHT channel type (ieee=%d, flags=0x%08x)\n",
__func__, c->ic_ieee, c->ic_flags);