summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorJohannes Berg <johannes.berg@intel.com>2026-04-28 11:25:38 +0200
committerJohannes Berg <johannes.berg@intel.com>2026-05-05 14:49:03 +0200
commit5af8f06349d85824a32aa15949cb66b174e0f713 (patch)
tree6d4d08688b34adeb789fac20e312dc514009438c /include
parenta731e2fc26b68c0af61de7138e4b468091668a55 (diff)
downloadlinux-next-5af8f06349d85824a32aa15949cb66b174e0f713.tar.gz
linux-next-5af8f06349d85824a32aa15949cb66b174e0f713.zip
wifi: mac80211: mlme: use NPCA chandef if capable
If the device is capable, parse the AP chandef with NPCA. Also advertise the other NPCA operational parameters to the underlying driver and track if they change (though not with BSS critical update etc. yet) Since NPCA can only be enabled when the chanctx isn't shared, the channel context code needs to clear/set npca.enabled in the per-link configuration, except during association since we can't enable NPCA before having completed association. In this case, set npca.enabled during the association process. Link: https://patch.msgid.link/20260428112708.eb1e42c0b6d7.I0acd8445d4600363afb8430922531450399d0fab@changeid Signed-off-by: Johannes Berg <johannes.berg@intel.com>
Diffstat (limited to 'include')
-rw-r--r--include/net/mac80211.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/include/net/mac80211.h b/include/net/mac80211.h
index ae7fd44e17b5..4fb579805e0f 100644
--- a/include/net/mac80211.h
+++ b/include/net/mac80211.h
@@ -373,6 +373,7 @@ struct ieee80211_vif_chanctx_switch {
* @BSS_CHANGED_MLD_TTLM: negotiated TID to link mapping was changed
* @BSS_CHANGED_TPE: transmit power envelope changed
* @BSS_CHANGED_NAN_LOCAL_SCHED: NAN local schedule changed (NAN mode only)
+ * @BSS_CHANGED_NPCA: NPCA parameters changed
*/
enum ieee80211_bss_change {
BSS_CHANGED_ASSOC = 1<<0,
@@ -411,6 +412,7 @@ enum ieee80211_bss_change {
BSS_CHANGED_MLD_TTLM = BIT_ULL(34),
BSS_CHANGED_TPE = BIT_ULL(35),
BSS_CHANGED_NAN_LOCAL_SCHED = BIT_ULL(36),
+ BSS_CHANGED_NPCA = BIT_ULL(37),
/* when adding here, make sure to change ieee80211_reconfig */
};
@@ -597,6 +599,26 @@ struct ieee80211_parsed_tpe {
};
/**
+ * struct ieee80211_bss_npca_params - NPCA parameters
+ * @min_dur_thresh: NPCA minimum duration threshold (512 + 128*n usec)
+ * @switch_delay: NPCA switch delay (units of 4 usec)
+ * @switch_back_delay: NPCA switch back delay (units of 4 usec)
+ * @init_qsrc: initial QSRC value
+ * @moplen: indicates MOPLEN NPCA is permitted in the BSS
+ * @enabled: NPCA is enabled for this link
+ *
+ * Note: the individual values (except @enabled) are in spec representation.
+ */
+struct ieee80211_bss_npca_params {
+ u32 min_dur_thresh:4,
+ switch_delay:6,
+ switch_back_delay:6,
+ init_qsrc:2,
+ moplen:1,
+ enabled:1;
+};
+
+/**
* struct ieee80211_bss_conf - holds the BSS's changing parameters
*
* This structure keeps information about a BSS (and an association
@@ -770,6 +792,7 @@ struct ieee80211_parsed_tpe {
* (as opposed to hearing its value from another link's beacon).
* @s1g_long_beacon_period: number of beacon intervals between each long
* beacon transmission.
+ * @npca: NPCA parameters
*/
struct ieee80211_bss_conf {
struct ieee80211_vif *vif;
@@ -873,6 +896,8 @@ struct ieee80211_bss_conf {
u8 bss_param_ch_cnt_link_id;
u8 s1g_long_beacon_period;
+
+ struct ieee80211_bss_npca_params npca;
};
#define IEEE80211_NAN_MAX_CHANNELS 3