]> git.proxmox.com Git - mirror_ubuntu-bionic-kernel.git/commitdiff
cfg80211: get rid of name indirection trick for ieee80211_get_channel()
authorArend Van Spriel <arend.vanspriel@broadcom.com>
Thu, 17 Nov 2016 12:48:53 +0000 (12:48 +0000)
committerJohannes Berg <johannes.berg@intel.com>
Tue, 13 Dec 2016 15:04:56 +0000 (16:04 +0100)
The comment on the name indirection suggested an issue but turned out
to be untrue. Digging in older kernel version showed issue with ipw2x00
but that is no longer true so get rid on the name indirection.

Signed-off-by: Arend van Spriel <arend.vanspriel@broadcom.com>
Signed-off-by: Johannes Berg <johannes.berg@intel.com>
drivers/net/wireless/ath/ath10k/htt_rx.c
drivers/net/wireless/marvell/mwifiex/cfg80211.c
include/net/cfg80211.h
net/wireless/util.c

index 86d082cf4eef06f607dc8e32f790721f63bf3b77..0bc7fe8c4b528008c591b7f8dcf098bdac2d8bec 100644 (file)
@@ -2451,8 +2451,7 @@ bool ath10k_htt_t2h_msg_handler(struct ath10k *ar, struct sk_buff *skb)
                u32 phymode = __le32_to_cpu(resp->chan_change.phymode);
                u32 freq = __le32_to_cpu(resp->chan_change.freq);
 
-               ar->tgt_oper_chan =
-                       __ieee80211_get_channel(ar->hw->wiphy, freq);
+               ar->tgt_oper_chan = ieee80211_get_channel(ar->hw->wiphy, freq);
                ath10k_dbg(ar, ATH10K_DBG_HTT,
                           "htt chan change freq %u phymode %s\n",
                           freq, ath10k_wmi_phymode_str(phymode));
index 145cc4b5103b80bc2a0b0f5c94987a2d1349b39d..1e3bd435a694534f4a450b32e8b0bd69702e5269 100644 (file)
@@ -2078,7 +2078,7 @@ static int mwifiex_cfg80211_inform_ibss_bss(struct mwifiex_private *priv)
        ie_len = ie_buf[1] + sizeof(struct ieee_types_header);
 
        band = mwifiex_band_to_radio_type(priv->curr_bss_params.band);
-       chan = __ieee80211_get_channel(priv->wdev.wiphy,
+       chan = ieee80211_get_channel(priv->wdev.wiphy,
                        ieee80211_channel_to_frequency(bss_info.bss_chan,
                                                       band));
 
index 814be4b4200c253da028555613a67eead223933b..ca2ac1ce5862a65f80a82e092dd549a306a09b9b 100644 (file)
@@ -3955,26 +3955,15 @@ int ieee80211_channel_to_frequency(int chan, enum nl80211_band band);
  */
 int ieee80211_frequency_to_channel(int freq);
 
-/*
- * Name indirection necessary because the ieee80211 code also has
- * a function named "ieee80211_get_channel", so if you include
- * cfg80211's header file you get cfg80211's version, if you try
- * to include both header files you'll (rightfully!) get a symbol
- * clash.
- */
-struct ieee80211_channel *__ieee80211_get_channel(struct wiphy *wiphy,
-                                                 int freq);
 /**
  * ieee80211_get_channel - get channel struct from wiphy for specified frequency
+ *
  * @wiphy: the struct wiphy to get the channel for
  * @freq: the center frequency of the channel
+ *
  * Return: The channel struct from @wiphy at @freq.
  */
-static inline struct ieee80211_channel *
-ieee80211_get_channel(struct wiphy *wiphy, int freq)
-{
-       return __ieee80211_get_channel(wiphy, freq);
-}
+struct ieee80211_channel *ieee80211_get_channel(struct wiphy *wiphy, int freq);
 
 /**
  * ieee80211_get_response_rate - get basic rate for a given rate
index e9d040d29846f87517c0b6b40f0ff9dbeca63a05..2cf7df8173b6280f6a2dc8488b71f63e23d16992 100644 (file)
@@ -114,8 +114,7 @@ int ieee80211_frequency_to_channel(int freq)
 }
 EXPORT_SYMBOL(ieee80211_frequency_to_channel);
 
-struct ieee80211_channel *__ieee80211_get_channel(struct wiphy *wiphy,
-                                                 int freq)
+struct ieee80211_channel *ieee80211_get_channel(struct wiphy *wiphy, int freq)
 {
        enum nl80211_band band;
        struct ieee80211_supported_band *sband;
@@ -135,7 +134,7 @@ struct ieee80211_channel *__ieee80211_get_channel(struct wiphy *wiphy,
 
        return NULL;
 }
-EXPORT_SYMBOL(__ieee80211_get_channel);
+EXPORT_SYMBOL(ieee80211_get_channel);
 
 static void set_mandatory_flags_band(struct ieee80211_supported_band *sband,
                                     enum nl80211_band band)