Commit b56b1438 authored by John Whitmore's avatar John Whitmore Committed by Greg Kroah-Hartman

staging:rtl8192u: Rename IsLegalChannel - Style

The function IsLegalChannel causes a checkpatch issue due to its use
of CamelCase naming. The function has been renamed to is_legal_channel.

This is a coding style change which should have no impact on runtime
code execution.
Signed-off-by: default avatarJohn Whitmore <johnfwhitmore@gmail.com>
Signed-off-by: default avatarGreg Kroah-Hartman <gregkh@linuxfoundation.org>
parent e859737a
......@@ -136,19 +136,19 @@ void dot11d_scan_complete(struct ieee80211_device *dev)
}
EXPORT_SYMBOL(dot11d_scan_complete);
int IsLegalChannel(struct ieee80211_device *dev, u8 channel)
int is_legal_channel(struct ieee80211_device *dev, u8 channel)
{
struct rt_dot11d_info *pDot11dInfo = GET_DOT11D_INFO(dev);
if (channel > MAX_CHANNEL_NUMBER) {
netdev_err(dev->dev, "IsLegalChannel(): Invalid Channel\n");
netdev_err(dev->dev, "is_legal_channel(): Invalid Channel\n");
return 0;
}
if (pDot11dInfo->channel_map[channel] > 0)
return 1;
return 0;
}
EXPORT_SYMBOL(IsLegalChannel);
EXPORT_SYMBOL(is_legal_channel);
int ToLegalChannel(struct ieee80211_device *dev, u8 channel)
{
......@@ -164,7 +164,7 @@ int ToLegalChannel(struct ieee80211_device *dev, u8 channel)
}
if (channel > MAX_CHANNEL_NUMBER) {
netdev_err(dev->dev, "IsLegalChannel(): Invalid Channel\n");
netdev_err(dev->dev, "is_legal_channel(): Invalid Channel\n");
return default_chn;
}
......
......@@ -51,7 +51,7 @@ void dot11d_update_country_ie(struct ieee80211_device *dev,
u8 *coutry_ie);
u8 dot11d_get_max_tx_pwr_in_dbm(struct ieee80211_device *dev, u8 channel);
void dot11d_scan_complete(struct ieee80211_device *dev);
int IsLegalChannel(struct ieee80211_device *dev, u8 channel);
int is_legal_channel(struct ieee80211_device *dev, u8 channel);
int ToLegalChannel(struct ieee80211_device *dev, u8 channel);
#endif /* #ifndef __INC_DOT11D_H */
......@@ -2439,7 +2439,7 @@ static inline void ieee80211_process_probe_response(
// then wireless adapter should do active scan from ch1~11 and
// passive scan from ch12~14
if (!IsLegalChannel(ieee, network->channel))
if (!is_legal_channel(ieee, network->channel))
goto out;
if (ieee->bGlobalDomain)
{
......@@ -2448,7 +2448,7 @@ static inline void ieee80211_process_probe_response(
// Case 1: Country code
if(IS_COUNTRY_IE_VALID(ieee) )
{
if (!IsLegalChannel(ieee, network->channel)) {
if (!is_legal_channel(ieee, network->channel)) {
printk("GetScanInfo(): For Country code, filter probe response at channel(%d).\n", network->channel);
goto out;
}
......@@ -2469,7 +2469,7 @@ static inline void ieee80211_process_probe_response(
// Case 1: Country code
if(IS_COUNTRY_IE_VALID(ieee) )
{
if (!IsLegalChannel(ieee, network->channel)) {
if (!is_legal_channel(ieee, network->channel)) {
printk("GetScanInfo(): For Country code, filter beacon at channel(%d).\n",network->channel);
goto out;
}
......
......@@ -1271,7 +1271,7 @@ static u8 rtl8192_phy_SwChnlStepByStep(struct net_device *dev, u8 channel,
RT_TRACE(COMP_CH, "%s() stage: %d, step: %d, channel: %d\n",
__func__, *stage, *step, channel);
if (!IsLegalChannel(priv->ieee80211, channel)) {
if (!is_legal_channel(priv->ieee80211, channel)) {
RT_TRACE(COMP_ERR, "set to illegal channel: %d\n", channel);
/* return true to tell upper caller function this channel
* setting is finished! Or it will in while loop.
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment