cfg80211: constify ieee80211_get_response_rate return
authorJoe Perches <joe@perches.com>
Sun, 18 Apr 2021 08:39:53 +0000 (01:39 -0700)
committerJohannes Berg <johannes.berg@intel.com>
Mon, 19 Apr 2021 09:59:33 +0000 (11:59 +0200)
It's not modified so make it const with the eventual goal of moving
data to text for various static struct ieee80211_rate arrays.

Signed-off-by: Joe Perches <joe@perches.com>
Link: https://lore.kernel.org/r/8b210b5f5972e39eded269b35a1297cf824c4181.camel@perches.com
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/broadcom/b43/main.c
drivers/net/wireless/broadcom/b43legacy/main.c
include/net/cfg80211.h
net/wireless/util.c

index 150a366..17bcec5 100644 (file)
@@ -4053,7 +4053,7 @@ static void b43_update_basic_rates(struct b43_wldev *dev, u32 brates)
 {
        struct ieee80211_supported_band *sband =
                dev->wl->hw->wiphy->bands[b43_current_band(dev->wl)];
-       struct ieee80211_rate *rate;
+       const struct ieee80211_rate *rate;
        int i;
        u16 basic, direct, offset, basic_offset, rateptr;
 
index 7692a26..f64ebff 100644 (file)
@@ -2762,7 +2762,7 @@ static void b43legacy_update_basic_rates(struct b43legacy_wldev *dev, u32 brates
 {
        struct ieee80211_supported_band *sband =
                dev->wl->hw->wiphy->bands[NL80211_BAND_2GHZ];
-       struct ieee80211_rate *rate;
+       const struct ieee80211_rate *rate;
        int i;
        u16 basic, direct, offset, basic_offset, rateptr;
 
index 528bea5..73b17ea 100644 (file)
@@ -5607,7 +5607,7 @@ static inline bool cfg80211_channel_is_psc(struct ieee80211_channel *chan)
  * which is, for this function, given as a bitmap of indices of
  * rates in the band's bitrate table.
  */
-struct ieee80211_rate *
+const struct ieee80211_rate *
 ieee80211_get_response_rate(struct ieee80211_supported_band *sband,
                            u32 basic_rates, int bitrate);
 
index 1bf0200..382c526 100644 (file)
@@ -24,7 +24,7 @@
 #include "rdev-ops.h"
 
 
-struct ieee80211_rate *
+const struct ieee80211_rate *
 ieee80211_get_response_rate(struct ieee80211_supported_band *sband,
                            u32 basic_rates, int bitrate)
 {