staging: rtl8192e: Rename bFilterSour.., CCKPresentAt.. and ResetProg..

Rename variable bFilterSourceStationFrame to fltr_src_sta_frame,
CCKPresentAttentuation to cck_present_attn and ResetProgress to
rst_progress to avoid CamelCase which is not accepted by checkpatch.

Signed-off-by: Philipp Hortmann <philipp.g.hortmann@gmail.com>
Link: https://lore.kernel.org/r/25ab52350a4a3249a1f76b28eea10c44e2f9552d.1668313325.git.philipp.g.hortmann@gmail.com
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Philipp Hortmann 2022-11-13 05:36:02 +01:00 committed by Greg Kroah-Hartman
parent 8e5d08ceb8
commit 62310f889a
8 changed files with 43 additions and 43 deletions

View file

@ -617,7 +617,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
start:
rtl92e_reset_desc_ring(dev);
priv->Rf_Mode = RF_OP_By_SW_3wire;
if (priv->ResetProgress == RESET_TYPE_NORESET) {
if (priv->rst_progress == RESET_TYPE_NORESET) {
rtl92e_writeb(dev, ANAPAR, 0x37);
mdelay(500);
}
@ -650,7 +650,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
}
priv->LoopbackMode = RTL819X_NO_LOOPBACK;
if (priv->ResetProgress == RESET_TYPE_NORESET) {
if (priv->rst_progress == RESET_TYPE_NORESET) {
ulRegRead = rtl92e_readl(dev, CPU_GEN);
if (priv->LoopbackMode == RTL819X_NO_LOOPBACK)
ulRegRead = (ulRegRead & CPU_GEN_NO_LOOPBACK_MSK) |
@ -699,7 +699,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
rtl92e_writeb(dev, ACK_TIMEOUT, 0x30);
if (priv->ResetProgress == RESET_TYPE_NORESET)
if (priv->rst_progress == RESET_TYPE_NORESET)
rtl92e_set_wireless_mode(dev, priv->rtllib->mode);
rtl92e_cam_reset(dev);
{
@ -739,7 +739,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
}
}
if (priv->ResetProgress == RESET_TYPE_NORESET) {
if (priv->rst_progress == RESET_TYPE_NORESET) {
rtStatus = rtl92e_config_phy(dev);
if (!rtStatus) {
netdev_info(dev, "RF Config failed\n");
@ -766,7 +766,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
else
priv->Rf_Mode = RF_OP_By_SW_3wire;
if (priv->ResetProgress == RESET_TYPE_NORESET) {
if (priv->rst_progress == RESET_TYPE_NORESET) {
rtl92e_dm_init_txpower_tracking(dev);
if (priv->IC_Cut >= IC_VersionCut_D) {
@ -795,7 +795,7 @@ bool rtl92e_start_adapter(struct net_device *dev)
}
priv->CCKPresentAttentuation_40Mdefault = 0;
priv->CCKPresentAttentuation_difference = 0;
priv->CCKPresentAttentuation =
priv->cck_present_attn =
priv->CCKPresentAttentuation_20Mdefault;
priv->btxpower_tracking = false;
}

View file

@ -1008,16 +1008,16 @@ static void _rtl92e_cck_tx_power_track_bw_switch_tssi(struct net_device *dev)
switch (priv->CurrentChannelBW) {
case HT_CHANNEL_WIDTH_20:
priv->CCKPresentAttentuation =
priv->cck_present_attn =
priv->CCKPresentAttentuation_20Mdefault +
priv->CCKPresentAttentuation_difference;
if (priv->CCKPresentAttentuation >
if (priv->cck_present_attn >
(CCKTxBBGainTableLength-1))
priv->CCKPresentAttentuation =
priv->cck_present_attn =
CCKTxBBGainTableLength-1;
if (priv->CCKPresentAttentuation < 0)
priv->CCKPresentAttentuation = 0;
if (priv->cck_present_attn < 0)
priv->cck_present_attn = 0;
if (priv->rtllib->current_network.channel == 14 &&
!priv->bcck_in_ch14) {
@ -1033,16 +1033,16 @@ static void _rtl92e_cck_tx_power_track_bw_switch_tssi(struct net_device *dev)
break;
case HT_CHANNEL_WIDTH_20_40:
priv->CCKPresentAttentuation =
priv->cck_present_attn =
priv->CCKPresentAttentuation_40Mdefault +
priv->CCKPresentAttentuation_difference;
if (priv->CCKPresentAttentuation >
if (priv->cck_present_attn >
(CCKTxBBGainTableLength - 1))
priv->CCKPresentAttentuation =
priv->cck_present_attn =
CCKTxBBGainTableLength-1;
if (priv->CCKPresentAttentuation < 0)
priv->CCKPresentAttentuation = 0;
if (priv->cck_present_attn < 0)
priv->cck_present_attn = 0;
if (priv->rtllib->current_network.channel == 14 &&
!priv->bcck_in_ch14) {

View file

@ -850,7 +850,7 @@ static void _rtl92e_init_priv_variable(struct net_device *dev)
priv->rtllib->iw_mode = IW_MODE_INFRA;
priv->rtllib->net_promiscuous_md = false;
priv->rtllib->intel_promiscuous_md_info.promiscuous_on = false;
priv->rtllib->intel_promiscuous_md_info.bFilterSourceStationFrame =
priv->rtllib->intel_promiscuous_md_info.fltr_src_sta_frame =
false;
priv->rtllib->ieee_up = 0;
priv->retry_rts = DEFAULT_RETRY_RTS;
@ -861,11 +861,11 @@ static void _rtl92e_init_priv_variable(struct net_device *dev)
priv->promisc = (dev->flags & IFF_PROMISC) ? 1 : 0;
priv->bcck_in_ch14 = false;
priv->bfsync_processing = false;
priv->CCKPresentAttentuation = 0;
priv->cck_present_attn = 0;
priv->rfa_txpowertrackingindex = 0;
priv->rfc_txpowertrackingindex = 0;
priv->CckPwEnl = 6;
priv->ResetProgress = RESET_TYPE_NORESET;
priv->rst_progress = RESET_TYPE_NORESET;
priv->force_reset = false;
memset(priv->rtllib->swcamtable, 0, sizeof(struct sw_cam_table) * 32);
@ -1135,8 +1135,8 @@ static void _rtl92e_if_silent_reset(struct net_device *dev)
struct rtllib_device *ieee = priv->rtllib;
unsigned long flag;
if (priv->ResetProgress == RESET_TYPE_NORESET) {
priv->ResetProgress = RESET_TYPE_SILENT;
if (priv->rst_progress == RESET_TYPE_NORESET) {
priv->rst_progress = RESET_TYPE_SILENT;
spin_lock_irqsave(&priv->rf_ps_lock, flag);
if (priv->rf_change_in_progress) {
@ -1233,7 +1233,7 @@ static void _rtl92e_if_silent_reset(struct net_device *dev)
rtl92e_cam_restore(dev);
rtl92e_dm_restore_state(dev);
END:
priv->ResetProgress = RESET_TYPE_NORESET;
priv->rst_progress = RESET_TYPE_NORESET;
priv->reset_count++;
priv->bResetInProgress = false;
@ -1396,7 +1396,7 @@ static void _rtl92e_watchdog_wq_cb(void *data)
spin_unlock_irqrestore(&priv->tx_lock, flags);
if (ResetType == RESET_TYPE_NORMAL) {
priv->ResetProgress = RESET_TYPE_NORMAL;
priv->rst_progress = RESET_TYPE_NORMAL;
return;
}

View file

@ -483,7 +483,7 @@ struct r8192_priv {
u8 CCKPresentAttentuation_20Mdefault;
u8 CCKPresentAttentuation_40Mdefault;
s8 CCKPresentAttentuation_difference;
s8 CCKPresentAttentuation;
s8 cck_present_attn;
long undecorated_smoothed_pwdb;
u32 MCSTxPowerLevelOriginalOffset[6];
@ -536,7 +536,7 @@ struct r8192_priv {
u32 reset_count;
enum reset_type ResetProgress;
enum reset_type rst_progress;
u16 TxCounter;
u16 RxCounter;
bool bResetInProgress;

View file

@ -267,7 +267,7 @@ static void _rtl92e_dm_check_ac_dc_power(struct net_device *dev)
"PATH=/usr/bin:/bin",
NULL};
if (priv->ResetProgress == RESET_TYPE_SILENT)
if (priv->rst_progress == RESET_TYPE_SILENT)
return;
if (priv->rtllib->state != RTLLIB_LINKED)
return;
@ -716,21 +716,21 @@ static void _rtl92e_dm_tx_power_tracking_callback_tssi(struct net_device *dev)
}
if (priv->CurrentChannelBW == HT_CHANNEL_WIDTH_20)
priv->CCKPresentAttentuation =
priv->cck_present_attn =
priv->CCKPresentAttentuation_20Mdefault +
priv->CCKPresentAttentuation_difference;
else
priv->CCKPresentAttentuation =
priv->cck_present_attn =
priv->CCKPresentAttentuation_40Mdefault +
priv->CCKPresentAttentuation_difference;
if (priv->CCKPresentAttentuation > (CCKTxBBGainTableLength-1))
priv->CCKPresentAttentuation = CCKTxBBGainTableLength-1;
if (priv->CCKPresentAttentuation < 0)
priv->CCKPresentAttentuation = 0;
if (priv->cck_present_attn > (CCKTxBBGainTableLength-1))
priv->cck_present_attn = CCKTxBBGainTableLength-1;
if (priv->cck_present_attn < 0)
priv->cck_present_attn = 0;
if (priv->CCKPresentAttentuation > -1 &&
priv->CCKPresentAttentuation < CCKTxBBGainTableLength) {
if (priv->cck_present_attn > -1 &&
priv->cck_present_attn < CCKTxBBGainTableLength) {
if (priv->rtllib->current_network.channel == 14 &&
!priv->bcck_in_ch14) {
priv->bcck_in_ch14 = true;
@ -963,7 +963,7 @@ static void _rtl92e_dm_cck_tx_power_adjust_tssi(struct net_device *dev,
{
u32 TempVal;
struct r8192_priv *priv = rtllib_priv(dev);
u8 attenuation = priv->CCKPresentAttentuation;
u8 attenuation = priv->cck_present_attn;
TempVal = 0;
if (!bInCH14) {

View file

@ -1015,20 +1015,20 @@ static int _rtl92e_wx_set_promisc_mode(struct net_device *dev,
u32 oid;
u32 promiscuous_on;
u32 bFilterSourceStationFrame;
u32 fltr_src_sta_frame;
if (copy_from_user(info_buf, wrqu->data.pointer, sizeof(info_buf)))
return -EFAULT;
oid = info_buf[0];
promiscuous_on = info_buf[1];
bFilterSourceStationFrame = info_buf[2];
fltr_src_sta_frame = info_buf[2];
if (oid == OID_RT_INTEL_PROMISCUOUS_MODE) {
ieee->intel_promiscuous_md_info.promiscuous_on =
(promiscuous_on) ? (true) : (false);
ieee->intel_promiscuous_md_info.bFilterSourceStationFrame =
(bFilterSourceStationFrame) ? (true) : (false);
ieee->intel_promiscuous_md_info.fltr_src_sta_frame =
(fltr_src_sta_frame) ? (true) : (false);
(promiscuous_on) ?
(rtllib_EnableIntelPromiscuousMode(dev, false)) :
(rtllib_DisableIntelPromiscuousMode(dev, false));
@ -1036,7 +1036,7 @@ static int _rtl92e_wx_set_promisc_mode(struct net_device *dev,
netdev_info(dev,
"=======>%s(), on = %d, filter src sta = %d\n",
__func__, promiscuous_on,
bFilterSourceStationFrame);
fltr_src_sta_frame);
} else {
return -1;
}
@ -1055,7 +1055,7 @@ static int _rtl92e_wx_get_promisc_mode(struct net_device *dev,
snprintf(extra, 45, "PromiscuousMode:%d, FilterSrcSTAFrame:%d",
ieee->intel_promiscuous_md_info.promiscuous_on,
ieee->intel_promiscuous_md_info.bFilterSourceStationFrame);
ieee->intel_promiscuous_md_info.fltr_src_sta_frame);
wrqu->data.length = strlen(extra) + 1;
mutex_unlock(&priv->wx_mutex);

View file

@ -1385,7 +1385,7 @@ struct rt_pmkid_list {
struct rt_intel_promisc_mode {
bool promiscuous_on;
bool bFilterSourceStationFrame;
bool fltr_src_sta_frame;
};

View file

@ -1000,7 +1000,7 @@ static int rtllib_rx_data_filter(struct rtllib_device *ieee, u16 fc,
/* Filter packets sent by an STA that will be forwarded by AP */
if (ieee->intel_promiscuous_md_info.promiscuous_on &&
ieee->intel_promiscuous_md_info.bFilterSourceStationFrame) {
ieee->intel_promiscuous_md_info.fltr_src_sta_frame) {
if ((fc & RTLLIB_FCTL_TODS) && !(fc & RTLLIB_FCTL_FROMDS) &&
!ether_addr_equal(dst, ieee->current_network.bssid) &&
ether_addr_equal(bssid, ieee->current_network.bssid)) {