wifi: rtw89: declare support bands with const
authorZong-Zhe Yang <kevin_yang@realtek.com>
Thu, 20 Oct 2022 05:27:01 +0000 (13:27 +0800)
committerKalle Valo <kvalo@kernel.org>
Tue, 1 Nov 2022 09:25:03 +0000 (11:25 +0200)
They are just default declarations and we won't modify them directly.
Instead, we actually do moification on their memdup now. So, they
should be declared with const.

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/20221020052702.33988-1-pkshih@realtek.com
drivers/net/wireless/realtek/rtw89/core.c

index a0fa963..6d8243e 100644 (file)
@@ -171,7 +171,7 @@ bool rtw89_ra_report_to_bitrate(struct rtw89_dev *rtwdev, u8 rpt_rate, u16 *bitr
        return true;
 }
 
-static struct ieee80211_supported_band rtw89_sband_2ghz = {
+static const struct ieee80211_supported_band rtw89_sband_2ghz = {
        .band           = NL80211_BAND_2GHZ,
        .channels       = rtw89_channels_2ghz,
        .n_channels     = ARRAY_SIZE(rtw89_channels_2ghz),
@@ -181,7 +181,7 @@ static struct ieee80211_supported_band rtw89_sband_2ghz = {
        .vht_cap        = {0},
 };
 
-static struct ieee80211_supported_band rtw89_sband_5ghz = {
+static const struct ieee80211_supported_band rtw89_sband_5ghz = {
        .band           = NL80211_BAND_5GHZ,
        .channels       = rtw89_channels_5ghz,
        .n_channels     = ARRAY_SIZE(rtw89_channels_5ghz),
@@ -193,7 +193,7 @@ static struct ieee80211_supported_band rtw89_sband_5ghz = {
        .vht_cap        = {0},
 };
 
-static struct ieee80211_supported_band rtw89_sband_6ghz = {
+static const struct ieee80211_supported_band rtw89_sband_6ghz = {
        .band           = NL80211_BAND_6GHZ,
        .channels       = rtw89_channels_6ghz,
        .n_channels     = ARRAY_SIZE(rtw89_channels_6ghz),