* [PATCH] cfg80211: Adjust 6ghz frequencies per channelization
@ 2020-06-19 21:10 Amar Singhal
0 siblings, 0 replies; 2+ messages in thread
From: Amar Singhal @ 2020-06-19 21:10 UTC (permalink / raw)
To: linux-wireless, johannes, jouni; +Cc: asinghal
Per 11ax draft 6.1, 6ghz frequencies need adjustment. Also orphan
channel of frequency 5935 MHz has been added. Modify utilities
accordingly.
Change-Id: I3a10fbef7ece7b86f44ac9bd09556f9d89d1844c
Signed-off-by: Amar Singhal <asinghal@codeaurora.org>
---
net/wireless/util.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/net/wireless/util.c b/net/wireless/util.c
index df75e58..f64af43 100644
--- a/net/wireless/util.c
+++ b/net/wireless/util.c
@@ -92,9 +92,11 @@ u32 ieee80211_channel_to_freq_khz(int chan, enum nl80211_band band)
return MHZ_TO_KHZ(5000 + chan * 5);
break;
case NL80211_BAND_6GHZ:
- /* see 802.11ax D4.1 27.3.22.2 */
- if (chan <= 253)
- return 5940 + chan * 5;
+ /* see 802.11ax D6.1 27.3.23.2 */
+ if (chan == 2)
+ return 5925 + chan * 5;
+ if (chan <= 233)
+ return 5950 + chan * 5;
break;
case NL80211_BAND_60GHZ:
if (chan < 7)
@@ -119,11 +121,13 @@ int ieee80211_freq_khz_to_channel(u32 freq)
return (freq - 2407) / 5;
else if (freq >= 4910 && freq <= 4980)
return (freq - 4000) / 5;
- else if (freq < 5945)
+ else if (freq < 5925)
return (freq - 5000) / 5;
+ else if (freq == 5935)
+ return (freq - 5925) / 5;
else if (freq <= 45000) /* DMG band lower limit */
- /* see 802.11ax D4.1 27.3.22.2 */
- return (freq - 5940) / 5;
+ /* see 802.11ax D6.1 27.3.23.2 */
+ return (freq - 5950) / 5;
else if (freq >= 58320 && freq <= 70200)
return (freq - 56160) / 2160;
else
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [PATCH] cfg80211: Adjust 6ghz frequencies per channelization
@ 2020-06-19 20:52 Amar Singhal
0 siblings, 0 replies; 2+ messages in thread
From: Amar Singhal @ 2020-06-19 20:52 UTC (permalink / raw)
To: linux-wireless, johannes, jouni; +Cc: asinghal
Per 11ax draft 6.1, 6ghz frequencies need adjustment. Also orphan
channel of frequency 5935 MHz has been added. Modify utilities
accordingly.
Signed-off-by: Amar Singhal <asinghal@codeaurora.org>
---
net/wireless/util.c | 16 ++++++++++------
1 file changed, 10 insertions(+), 6 deletions(-)
diff --git a/net/wireless/util.c b/net/wireless/util.c
index df75e58..3fb4f4b 100644
--- a/net/wireless/util.c
+++ b/net/wireless/util.c
@@ -92,9 +92,11 @@ u32 ieee80211_channel_to_freq_khz(int chan, enum nl80211_band band)
return MHZ_TO_KHZ(5000 + chan * 5);
break;
case NL80211_BAND_6GHZ:
- /* see 802.11ax D4.1 27.3.22.2 */
- if (chan <= 253)
- return 5940 + chan * 5;
+ /* see 802.11ax D6.1 27.3.22.2 */
+ if (chan == 2)
+ return 5925 + chan * 5;
+ if (chan <= 233)
+ return 5950 + chan * 5;
break;
case NL80211_BAND_60GHZ:
if (chan < 7)
@@ -119,11 +121,13 @@ int ieee80211_freq_khz_to_channel(u32 freq)
return (freq - 2407) / 5;
else if (freq >= 4910 && freq <= 4980)
return (freq - 4000) / 5;
- else if (freq < 5945)
+ else if (freq < 5925)
return (freq - 5000) / 5;
+ else if (freq == 5935)
+ return (freq - 5925) / 5;
else if (freq <= 45000) /* DMG band lower limit */
- /* see 802.11ax D4.1 27.3.22.2 */
- return (freq - 5940) / 5;
+ /* see 802.11ax D6.1 27.3.22.2 */
+ return (freq - 5950) / 5;
else if (freq >= 58320 && freq <= 70200)
return (freq - 56160) / 2160;
else
--
1.9.1
^ permalink raw reply related [flat|nested] 2+ messages in thread
end of thread, other threads:[~2020-06-19 21:10 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-06-19 21:10 [PATCH] cfg80211: Adjust 6ghz frequencies per channelization Amar Singhal
-- strict thread matches above, loose matches on Subject: below --
2020-06-19 20:52 Amar Singhal
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.