* [PATCH] staging: rtl8723bs: remove 5 GHz code
@ 2020-08-13 6:50 Michael Straube
0 siblings, 0 replies; only message in thread
From: Michael Straube @ 2020-08-13 6:50 UTC (permalink / raw)
To: gregkh; +Cc: hdegoede, Larry.Finger, devel, linux-kernel, Michael Straube
According to the TODO 5 GHz code should be removed.
- find and remove remaining code valid only for 5 GHz. Most of the obvious
ones have been removed, but things like channel > 14 still exist.
Remove code for channels > 14 from rtw_get_center_ch().
Signed-off-by: Michael Straube <straube.linux@gmail.com>
---
drivers/staging/rtl8723bs/core/rtw_wlan_util.c | 15 +--------------
1 file changed, 1 insertion(+), 14 deletions(-)
diff --git a/drivers/staging/rtl8723bs/core/rtw_wlan_util.c b/drivers/staging/rtl8723bs/core/rtw_wlan_util.c
index a3ea7ce3e12e..a5790a648a5b 100644
--- a/drivers/staging/rtl8723bs/core/rtw_wlan_util.c
+++ b/drivers/staging/rtl8723bs/core/rtw_wlan_util.c
@@ -374,20 +374,7 @@ u8 rtw_get_center_ch(u8 channel, u8 chnl_bw, u8 chnl_offset)
u8 center_ch = channel;
if (chnl_bw == CHANNEL_WIDTH_80) {
- if ((channel == 36) || (channel == 40) || (channel == 44) || (channel == 48))
- center_ch = 42;
- if ((channel == 52) || (channel == 56) || (channel == 60) || (channel == 64))
- center_ch = 58;
- if ((channel == 100) || (channel == 104) || (channel == 108) || (channel == 112))
- center_ch = 106;
- if ((channel == 116) || (channel == 120) || (channel == 124) || (channel == 128))
- center_ch = 122;
- if ((channel == 132) || (channel == 136) || (channel == 140) || (channel == 144))
- center_ch = 138;
- if ((channel == 149) || (channel == 153) || (channel == 157) || (channel == 161))
- center_ch = 155;
- else if (channel <= 14)
- center_ch = 7;
+ center_ch = 7;
} else if (chnl_bw == CHANNEL_WIDTH_40) {
if (chnl_offset == HAL_PRIME_CHNL_OFFSET_LOWER)
center_ch = channel + 2;
--
2.28.0
^ permalink raw reply related [flat|nested] only message in thread
only message in thread, other threads:[~2020-08-13 6:54 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-08-13 6:50 [PATCH] staging: rtl8723bs: remove 5 GHz code Michael Straube
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).