[PATCH 23/25][SRU][OEM-5.14] UBUNTU: SAUCE: cfg80211: add definition for 6 GHz power spectral density(psd)
You-Sheng Yang
vicamo.yang at canonical.com
Tue Oct 19 16:24:06 UTC 2021
From: Wen Gong <wgong at codeaurora.org>
BugLink: https://bugs.launchpad.net/bugs/1939528
6 GHz regulatory domains introduces power spectral density(psd). This
patch is define the flags for psd.
Signed-off-by: Wen Gong <wgong at codeaurora.org>
(backported from
https://lore.kernel.org/linux-wireless/20210924100052.32029-4-wgong@codeaurora.org/raw)
Signed-off-by: You-Sheng Yang <vicamo.yang at canonical.com>
---
include/net/cfg80211.h | 5 +++++
include/net/regulatory.h | 1 +
include/uapi/linux/nl80211.h | 2 ++
3 files changed, 8 insertions(+)
diff --git a/include/net/cfg80211.h b/include/net/cfg80211.h
index 161cdf7df1a07..81951121a61eb 100644
--- a/include/net/cfg80211.h
+++ b/include/net/cfg80211.h
@@ -109,6 +109,8 @@ struct wiphy;
* on this channel.
* @IEEE80211_CHAN_16MHZ: 16 MHz bandwidth is permitted
* on this channel.
+ * @IEEE80211_CHAN_PSD: power spectral density (in dBm)
+ * on this channel.
*
*/
enum ieee80211_channel_flags {
@@ -131,6 +133,7 @@ enum ieee80211_channel_flags {
IEEE80211_CHAN_4MHZ = 1<<16,
IEEE80211_CHAN_8MHZ = 1<<17,
IEEE80211_CHAN_16MHZ = 1<<18,
+ IEEE80211_CHAN_PSD = 1<<19,
};
#define IEEE80211_CHAN_NO_HT40 \
@@ -164,6 +167,7 @@ enum ieee80211_channel_flags {
* on this channel.
* @dfs_state_entered: timestamp (jiffies) when the dfs state was entered.
* @dfs_cac_ms: DFS CAC time in milliseconds, this is valid for DFS channels.
+ * @psd: power spectral density (in dBm)
*/
struct ieee80211_channel {
enum nl80211_band band;
@@ -180,6 +184,7 @@ struct ieee80211_channel {
enum nl80211_dfs_state dfs_state;
unsigned long dfs_state_entered;
unsigned int dfs_cac_ms;
+ s8 psd;
};
/**
diff --git a/include/net/regulatory.h b/include/net/regulatory.h
index 47f06f6f5a67c..ed20004fb6a94 100644
--- a/include/net/regulatory.h
+++ b/include/net/regulatory.h
@@ -221,6 +221,7 @@ struct ieee80211_reg_rule {
u32 flags;
u32 dfs_cac_ms;
bool has_wmm;
+ s8 psd;
};
struct ieee80211_regdomain {
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h
index db474994fa732..32a8dc9404d33 100644
--- a/include/uapi/linux/nl80211.h
+++ b/include/uapi/linux/nl80211.h
@@ -4046,6 +4046,7 @@ enum nl80211_sched_scan_match_attr {
* @NL80211_RRF_NO_80MHZ: 80MHz operation not allowed
* @NL80211_RRF_NO_160MHZ: 160MHz operation not allowed
* @NL80211_RRF_NO_HE: HE operation not allowed
+ * @NL80211_RRF_PSD: channels has power spectral density value
*/
enum nl80211_reg_rule_flags {
NL80211_RRF_NO_OFDM = 1<<0,
@@ -4064,6 +4065,7 @@ enum nl80211_reg_rule_flags {
NL80211_RRF_NO_80MHZ = 1<<15,
NL80211_RRF_NO_160MHZ = 1<<16,
NL80211_RRF_NO_HE = 1<<17,
+ NL80211_RRF_PSD = 1<<18,
};
#define NL80211_RRF_PASSIVE_SCAN NL80211_RRF_NO_IR
--
2.32.0
More information about the kernel-team
mailing list