Search Linux Wireless

[RFC] mac80211: Add radiotap channel flag option for 6GHz band

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Radiotap header needs a new channel flag for 6GHz packets.
This change uses value 0x200 for new enum balue for 6GHz which was
previously used for passsive scan flag but has since been removed.

Signed-off-by: Aloka Dixit <alokad@xxxxxxxxxxxxxx>
---
 include/net/ieee80211_radiotap.h | 1 +
 net/mac80211/rx.c                | 4 +++-
 2 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/include/net/ieee80211_radiotap.h b/include/net/ieee80211_radiotap.h
index 19c00d100096..df631d177cf9 100644
--- a/include/net/ieee80211_radiotap.h
+++ b/include/net/ieee80211_radiotap.h
@@ -101,6 +101,7 @@ enum ieee80211_radiotap_channel_flags {
 	IEEE80211_CHAN_OFDM = 0x0040,
 	IEEE80211_CHAN_2GHZ = 0x0080,
 	IEEE80211_CHAN_5GHZ = 0x0100,
+	IEEE80211_CHAN_6GHZ = 0x0200,
 	IEEE80211_CHAN_DYN = 0x0400,
 	IEEE80211_CHAN_HALF = 0x4000,
 	IEEE80211_CHAN_QUARTER = 0x8000,
diff --git a/net/mac80211/rx.c b/net/mac80211/rx.c
index 836cde516a18..21aa19c12afc 100644
--- a/net/mac80211/rx.c
+++ b/net/mac80211/rx.c
@@ -451,7 +451,9 @@ ieee80211_add_rx_radiotap_header(struct ieee80211_local *local,
 	else if (status->bw == RATE_INFO_BW_5)
 		channel_flags |= IEEE80211_CHAN_QUARTER;
 
-	if (status->band == NL80211_BAND_5GHZ)
+	if (status->band == NL80211_BAND_6GHZ)
+		channel_flags |= IEEE80211_CHAN_OFDM | IEEE80211_CHAN_6GHZ;
+	else if (status->band == NL80211_BAND_5GHZ)
 		channel_flags |= IEEE80211_CHAN_OFDM | IEEE80211_CHAN_5GHZ;
 	else if (status->encoding != RX_ENC_LEGACY)
 		channel_flags |= IEEE80211_CHAN_DYN | IEEE80211_CHAN_2GHZ;
-- 
2.25.0




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Wireless Regulations]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux