| #
7449e591
|
| 13-Oct-2025 |
Zhenlei Huang <zlei@FreeBSD.org> |
net80211: Use proper prototype for SYSINIT functions
MFC after: 1 week
|
| #
06527b28
|
| 14-Aug-2025 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211 / LinuxKPI: 802.11: revert / redo enum ieee80211_sta_rx_bw
The initial thought of migrating the LinuxKPI 802.11 enum into net80211 for shared use did not work out well. Currently in the ne
net80211 / LinuxKPI: 802.11: revert / redo enum ieee80211_sta_rx_bw
The initial thought of migrating the LinuxKPI 802.11 enum into net80211 for shared use did not work out well. Currently in the need for yet another adjustment, I decided to undo/de-couple net80211 and LinuxKPI 802.11 again.
The enum name now gets used in LinuxKPI based wifi drivers and it turns out it is spelt differntly than what I used initially. This creates a conflict.
net80211 still in the need to be able to express BW_320 in an uint8_t will likely be fine with the current solution as well. Rename the enum and prefixes in net80211 to "net80211" instead of "ieee80211". Apart from the names/prefix we leave the values the same.
In LinuxKPI add the enum with the expected name and use it there throughout to make modern versions of LinuxKPI based wifi drivers compile.
Sponsored by: The FreeBSD Foundation Fixes: ca389486a9599, 2c8b0d6205f6f MFC after: 3 days Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D52064
show more ...
|
| #
4e78b9b5
|
| 11-Jun-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: fix VHT node setup in hostap mode
Way back in 2017 I wrote the initial VHT hostap support, and then added a NULL check here to stop it from panicing. However, there is no VHTINFO IE in an
net80211: fix VHT node setup in hostap mode
Way back in 2017 I wrote the initial VHT hostap support, and then added a NULL check here to stop it from panicing. However, there is no VHTINFO IE in an ASSOC_REQ management frame. Thus, the node would never have VHT state initialised.
This mirrors what HT node setup does (which again doesn't have HTINFO IE's in an ASSOC_REQ frame), the upgrade will happen once the exchange completes.
Fixes: 2023566223a4020d832bd4e25dc7dadfd660b836 Differential Revision: https://reviews.freebsd.org/D50787
show more ...
|
| #
674362e2
|
| 01-Jun-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: migrate direct printf() to net80211_printf()
Mechanically migrate printf() -> net80211_printf(). A few places looked like they should be using net80211_vap_printf(), so migrate those appro
net80211: migrate direct printf() to net80211_printf()
Mechanically migrate printf() -> net80211_printf(). A few places looked like they should be using net80211_vap_printf(), so migrate those appropriately.
Differential Revision: https://reviews.freebsd.org/D50644 Reviewed by: bz
show more ...
|
| #
363846a7
|
| 01-May-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: fix VHT80/VHT160 transmit width checks
I didn't double check to see if ni_chw had been updated to actually implement values other than 20/40. It's just implementing the HT channel width s
net80211: fix VHT80/VHT160 transmit width checks
I didn't double check to see if ni_chw had been updated to actually implement values other than 20/40. It's just implementing the HT channel width stuff during both association and upon receiving a HT TX channel width action frame.
This meant the VHT80/VHT160 transmit width checks were never going to be true, as ni_chw is never set to VHT80 / VHT160.
After checking the HT action frame and looking for VHT changes, I'm pretty sure there's nothing explicit about VHT width, as it's normally done via CCA (clear channel access) and/or RTS/CTS exchanges - each 20MHz subchannel is RTS/CTS'ed / will be checked and if they're busy, a narrower frame will be transmitted.
So, change the VHT80 / VHT160 checks to only check if ni_chw is 20MHz. If it's 20MHz then a HT action frame has come out saying to TX at 20MHz, and we should obey it. Otherwise, do 80/160MHz as available.
Differential Revision: https://reviews.freebsd.org/D50096 Reviewed by: bz
show more ...
|
| #
05884447
|
| 02-Mar-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: add the specific 802.11-2020 references to VHT IEs
Since I keep needing to find them, just add the references to the VHT info/operation IEs.
Differential Revision: https://reviews.freebsd
net80211: add the specific 802.11-2020 references to VHT IEs
Since I keep needing to find them, just add the references to the VHT info/operation IEs.
Differential Revision: https://reviews.freebsd.org/D49199
show more ...
|
| #
7b0e3c5b
|
| 23-Jan-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: add ieee80211_vht_node_check_tx_valid_mcs()
Introduce ieee80211_vht_node_check_tx_valid_mcs(), which takes the node, bandwidth, NSS and MCS and validates whether that is possible to TX to
net80211: add ieee80211_vht_node_check_tx_valid_mcs()
Introduce ieee80211_vht_node_check_tx_valid_mcs(), which takes the node, bandwidth, NSS and MCS and validates whether that is possible to TX to the given node.
Differential Revision: https://reviews.freebsd.org/D48610 Reviewed by: bz, thj
show more ...
|
| #
1c746222
|
| 13-Jan-2025 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: Implement ieee80211_setup_vht_rates()
Implement ieee80211_setup_vht_rates() - calculate the intersection between the peers advertised RX VHT MCS map and the vap's configured TX map.
Whils
net80211: Implement ieee80211_setup_vht_rates()
Implement ieee80211_setup_vht_rates() - calculate the intersection between the peers advertised RX VHT MCS map and the vap's configured TX map.
Whilst here, remove the unused vhtcap/vhtinfo fields; they're already populated in the ieee80211_node before ieee80211_setup_vht_rates() is called.
Differential Revision: https://reviews.freebsd.org/D48607 Reviewed by: bz
show more ...
|
| #
912a0567
|
| 16-Dec-2024 |
Adrian Chadd <adrian@FreeBSD.org> |
net80211: add helper functions for VHT transmit
* Add static helper functions for VHT TX for 20MHz, 40MHz and 80MHz. * Add a public function to check if the given VHT width is available for transm
net80211: add helper functions for VHT transmit
* Add static helper functions for VHT TX for 20MHz, 40MHz and 80MHz. * Add a public function to check if the given VHT width is available for transmit.
Differential Revision: https://reviews.freebsd.org/D48101
show more ...
|
| #
243f6925
|
| 28-Nov-2024 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: 11ac: add options to manage VHT STBC
Add IEEE80211_FVHT_STBC_(TX|RX) flags to allow userspace to manage if STBC will be allowed for VHT RX/TX. For RX this will only allow us to turn it off
net80211: 11ac: add options to manage VHT STBC
Add IEEE80211_FVHT_STBC_(TX|RX) flags to allow userspace to manage if STBC will be allowed for VHT RX/TX. For RX this will only allow us to turn it off but no fine grained control of the number of supported spatial streams.
Introduce IEEE80211_FVHT_CHANWIDTH_MASK as a helper to make the spelling out of the IEEE80211_FVHT_MASK more readable.
Update ifconfig to allow setting of these flags.
Sponsored by: The FreeBSD Foundation MFC atfer: 3 days Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D47838
show more ...
|
| #
e85eb4c8
|
| 02-Dec-2023 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: adjust more VHT structures/fields
Replace ieee80211_ie_vhtcap with ieee80211_vht_cap and ieee80211_ie_vht_operation with ieee80211_vht_operation. The "ie" version has the two bytes type/le
net80211: adjust more VHT structures/fields
Replace ieee80211_ie_vhtcap with ieee80211_vht_cap and ieee80211_ie_vht_operation with ieee80211_vht_operation. The "ie" version has the two bytes type/length at the beginning which we did not actually use as such (the one place doing did just as unused extra work).
Using the non-"ie" versions allows us to re-use them on shared code. Using an enum helps us to not accidentally get unsuppored or unhandled values tough we cannot use it in the struct as we need to ensure the field width.
ieee80211_vht_operation is guarded by _KERNEL/WANT_NET80211. While the header is supposed to be exported to user land historically, software such as wpa bring their own structure definitions. For in-tree usage it is only ifconfig which really cares (at least for now).
Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian (earlier), cc Differential Revision: https://reviews.freebsd.org/D42901
show more ...
|
| #
fdafd315
|
| 24-Nov-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remov
sys: Automated cleanup of cdefs and other formatting
Apply the following automated changes to try to eliminate no-longer-needed sys/cdefs.h includes as well as now-empty blank lines in a row.
Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/ Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/ Remove /\n+#if.*\n#endif.*\n+/ Remove /^#if.*\n#endif.*\n/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/ Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/
Sponsored by: Netflix
show more ...
|
| #
6c3ae01c
|
| 26-Oct-2023 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: add ieee80211_add_vhtcap_ch()
Add an implementation of ieee80211_add_vhtcap() which works based on information derived from the vap (and possibly channel/band but we do not support that ye
net80211: add ieee80211_add_vhtcap_ch()
Add an implementation of ieee80211_add_vhtcap() which works based on information derived from the vap (and possibly channel/band but we do not support that yet in net80211). This is needed for scans request information in LinuxKPI at times before we have a BSS.
Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian, cc Differential Revision: https://reviews.freebsd.org/D42422
show more ...
|
| #
562adbe1
|
| 27-Oct-2023 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: migrate ic_vhtcaps, ic_vht_mcsinfo, ic_flags_vht
Like for the VAP rename ic_flags_vht to ic_vht_flags for consistency to keep "VHT" fields together and merge ic_vhtcaps and ic_vht_mcsinfo
net80211: migrate ic_vhtcaps, ic_vht_mcsinfo, ic_flags_vht
Like for the VAP rename ic_flags_vht to ic_vht_flags for consistency to keep "VHT" fields together and merge ic_vhtcaps and ic_vht_mcsinfo into struct ieee80211_vht_cap ic_vht_cap.
While the structure layout changes no other functional changes intended.
Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian, cc Differential Revision: https://reviews.freebsd.org/D42421
show more ...
|
| #
fbba0d6b
|
| 27-Oct-2023 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: combine iv_vhtcaps and iv_vht_mcsinfo
The iv_vhtcaps and iv_vht_mcsinfo fields together form struct ieee80211_vht_cap so combine them into one field in the VAP and keep the information tog
net80211: combine iv_vhtcaps and iv_vht_mcsinfo
The iv_vhtcaps and iv_vht_mcsinfo fields together form struct ieee80211_vht_cap so combine them into one field in the VAP and keep the information together.
While the structure layout changes no other functional changes intended.
Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian, cc Differential Revision: https://reviews.freebsd.org/D42420
show more ...
|
| #
ef48d4fa
|
| 27-Oct-2023 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: rename iv_flags_vht to iv_vht_flags
While the flag field is internal start naming it as well as "iv_vht*" so we keep all "VHT" fields together. This breaks with what was done done for HT
net80211: rename iv_flags_vht to iv_vht_flags
While the flag field is internal start naming it as well as "iv_vht*" so we keep all "VHT" fields together. This breaks with what was done done for HT but with HE, EHT, .. coming one day seems the more logic choice.
No functional changes intended.
Sponsored by: The FreeBSD Foundation MFC after: 3 days Reviewed by: adrian, cc Differential Revision: https://reviews.freebsd.org/D42419
show more ...
|
| #
685dc743
|
| 16-Aug-2023 |
Warner Losh <imp@FreeBSD.org> |
sys: Remove $FreeBSD$: one-line .c pattern
Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/
|
| #
dc32c713
|
| 29-Jul-2022 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: VHT correct check/option in ieee80211_vht_adjust_channel()
In ieee80211_vht_adjust_channel() we have to check for all possible IEEE80211_FVHT_VHT* options using the mask rather than just c
net80211: VHT correct check/option in ieee80211_vht_adjust_channel()
In ieee80211_vht_adjust_channel() we have to check for all possible IEEE80211_FVHT_VHT* options using the mask rather than just checking for IEEE80211_FVHT_VHT; ieee80211_vhtchanflags() (contrary to its HT counterpart) only returns the "highest" flag nor or-ing them together with the base flag. For the moment this seems to make sense as with more width options we'd add a pyramid.
Later on, in the same function when we get VHT160 actually go and look for VHT160 and not VHT80.
Sponsored by: The FreeBSD Foundation MFC after: 1 week Reviewed by: adrian Differential Revision: https://reviews.freebsd.org/D35977
show more ...
|
| #
04e7bb08
|
| 18-Oct-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: update for (more) VHT160 support
Implement two macros IEEE80211_VHTCAP_SUPP_CHAN_WIDTH_IS_160MHZ() and its 80+80 counter part to check in vhtcaps for appropriate levels of support and use
net80211: update for (more) VHT160 support
Implement two macros IEEE80211_VHTCAP_SUPP_CHAN_WIDTH_IS_160MHZ() and its 80+80 counter part to check in vhtcaps for appropriate levels of support and use the macros throughout the code.
Add vht160_chan_ranges/is_vht160_valid_freq and handle analogue to vht80 in various parts of the code.
Add ieee80211_add_channel_cbw() which also takes the CBW flag fields and make the former ieee80211_add_channel() a wrapper to it. With the CBW flags we can add HT/VHT channels passing them to getflags() for the 2/5ghz functions.
In ifconfig(8) add the regdomain_addchans() support for VHT160 and VHT80P80.
With this (+ regdoain.xml updates) VHT160 channels can be configured, listed, and pass regdomain where appropriate.
Tested with: iwlwifi Reviewed by: adrian MFC after: 10 days Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D26712
show more ...
|
| #
fe5ebb23
|
| 24-Sep-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
Provide MS() and SM() macros for 80211 and wireless drivers.
We have (two versions) of MS() and SM() macros which we use throughout the wireless code. Change all but three places (ath_hal, rtwn, an
Provide MS() and SM() macros for 80211 and wireless drivers.
We have (two versions) of MS() and SM() macros which we use throughout the wireless code. Change all but three places (ath_hal, rtwn, and rsu) to the newly provided _IEEE80211_MASKSHIFT() and _IEEE80211_SHIFTMASK() macros. Also change one internal case using both _S and _M instead of just _S away from _M (one of the reasons rtwn and rsu were not changed).
This was done semi-mechanically. No functional changes intended.
Requested by: gnn (D26091) Reviewed by: adrian (pre line wrap) MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC (d/b/a "Netgate") Differential Revision: https://reviews.freebsd.org/D26539
show more ...
|
| #
662c1305
|
| 01-Sep-2020 |
Mateusz Guzik <mjg@FreeBSD.org> |
net: clean up empty lines in .c and .h files
|
| #
e2515283
|
| 27-Aug-2020 |
Glen Barber <gjb@FreeBSD.org> |
MFH
Sponsored by: Rubicon Communications, LLC (netgate.com)
|
| #
97d9ee18
|
| 17-Aug-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: VHT correct NSS Set loop boundary
For the <VHT-MCS, NSS> tuple, NSS is 1..8 (or in our loop case 0..7 but not 0..6). Correct the boundry to check for < 8 and not < 7.
MFC after: 2 weeks R
net80211: VHT correct NSS Set loop boundary
For the <VHT-MCS, NSS> tuple, NSS is 1..8 (or in our loop case 0..7 but not 0..6). Correct the boundry to check for < 8 and not < 7.
MFC after: 2 weeks Reviewed by: adrian Sponsored by: Rubicon Communications, LLC (d/b/a "Netgate") Differential Revision: https://reviews.freebsd.org/D26087
show more ...
|
| #
a666b24e
|
| 17-Aug-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: return 80P80 before 160
In ieee80211_vht_get_chwidth_ie() we need to return 80P80 (3) before VHT160 (2) as otherwise we'll never use 80P80. Fix the order.
MFC after: 2 weeks X-MFC with:
net80211: return 80P80 before 160
In ieee80211_vht_get_chwidth_ie() we need to return 80P80 (3) before VHT160 (2) as otherwise we'll never use 80P80. Fix the order.
MFC after: 2 weeks X-MFC with: r364303 (which missed this) Sponsored by: Rubicon Communications, LLC (d/b/a "Netgate")
show more ...
|
| #
372c7b95
|
| 17-Aug-2020 |
Bjoern A. Zeeb <bz@FreeBSD.org> |
net80211: remove vertical whitespace
No functional changes.
MFC after: 2 weeks Sponsored by: Rubicon Communications, LLC (d/b/a "Netgate")
|