wifi: rtw89: refine rtw89_correct_cck_chan() by rtw89_hw_to_nl80211_band()
authorZong-Zhe Yang <kevin_yang@realtek.com>
Wed, 16 Aug 2023 08:21:29 +0000 (16:21 +0800)
committerKalle Valo <kvalo@kernel.org>
Fri, 25 Aug 2023 09:58:28 +0000 (12:58 +0300)
commitb05fdc46c5a64358f515c4db31991f609a572b53
tree171f1944333ef7d96274b03b886fe92fa52fb914
parent64a24cb63a4b6036e4af280767b305a5044ff303
wifi: rtw89: refine rtw89_correct_cck_chan() by rtw89_hw_to_nl80211_band()

In rtw89_correct_cck_chan(), we turn to use rtw89_hw_to_nl80211_band().
The difference between rtw89_hw_to_nl80211_band() and the original raw
judgement is the case on 6 GHz. Since rtw89_correct_cck_chan() is common
code independent on chip, if runtime chip doesn't support 6 GHz, it is
probably safe. Otherwise, it might not.

Signed-off-by: Zong-Zhe Yang <kevin_yang@realtek.com>
Signed-off-by: Ping-Ke Shih <pkshih@realtek.com>
Signed-off-by: Kalle Valo <kvalo@kernel.org>
Link: https://lore.kernel.org/r/20230816082133.57474-3-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/core.c