Trivial code cleanup patches
v3 cover Trivial code cleanup patches
Rename variables in struct rtllib_device to avoid CamelCase which is not accepted by checkpatch.
---
v3: The driver is split into 2 modules, calling the functions directly which
the v2 of the patchset does breaks compile. So reverting back to v1 of the patch as suggested by Greg Kroah-Hartman <[email protected]>.
v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.
Yogesh Hegde (4):
staging: rtl8192e: Rename variable SetWirelessMode
staging: rtl8192e: Rename variable SetBWModeHandler
staging: rtl8192e: Rename variable LeisurePSLeave
staging: rtl8192e: Rename variable InitialGainHandler
drivers/staging/rtl8192e/rtl8192e/r8192E_phy.c | 4 ++-- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 8 ++++---- drivers/staging/rtl8192e/rtl819x_HTProc.c | 4 ++-- drivers/staging/rtl8192e/rtllib.h | 12 ++++++------ drivers/staging/rtl8192e/rtllib_rx.c | 2 +- drivers/staging/rtl8192e/rtllib_softmac.c | 12 ++++++------ drivers/staging/rtl8192e/rtllib_softmac_wx.c | 6 +++--- 7 files changed, 24 insertions(+), 24 deletions(-)
Signature · 1 line
2.34.1
PATCH v3 1/4 staging: rtl8192e: Rename variable SetWirelessMode
Rename variable SetWirelessMode to set_wireless_mode to avoid CamelCase which is not accepted by checkpatch.
---
v3: Revert back to v1 of the patch as suggested by Greg Kroah-Hartman
<[email protected]>.
v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.
--- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 2 +- drivers/staging/rtl8192e/rtllib.h | 2 +- drivers/staging/rtl8192e/rtllib_softmac.c | 12 ++++++------ 3 files changed, 8 insertions(+), 8 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_core.c +1 -1
@@ -716,7 +716,7 @@ static void _rtl92e_init_priv_handler(struct net_device *dev) priv->rtllib->check_nic_enough_desc = _rtl92e_check_nic_enough_desc; priv->rtllib->handle_assoc_response = _rtl92e_handle_assoc_response; priv->rtllib->handle_beacon = _rtl92e_handle_beacon; - priv->rtllib->SetWirelessMode = rtl92e_set_wireless_mode; + priv->rtllib->set_wireless_mode = rtl92e_set_wireless_mode; priv->rtllib->LeisurePSLeave = rtl92e_leisure_ps_leave; priv->rtllib->SetBWModeHandler = rtl92e_set_bw_mode; priv->rf_set_chan = rtl92e_set_channel;
drivers/staging/rtl8192e/rtllib.h +1 -1
@@ -1708,7 +1708,7 @@ struct rtllib_device {enum ht_channel_width bandwidth, enum ht_extchnl_offset Offset);bool (*GetNmodeSupportBySecCfg)(struct net_device *dev); -void (*SetWirelessMode)(struct net_device *dev,u8 wireless_mode); +void (*set_wireless_mode)(struct net_device *dev,u8 wireless_mode);bool (*GetHalfNmodeSupportByAPsHandler)(struct net_device *dev);u8 (*rtllib_ap_sec_type)(struct rtllib_device *ieee);void (*InitialGainHandler)(struct net_device *dev,u8 Operation);
drivers/staging/rtl8192e/rtllib_softmac.c +6 -6
@@ -1472,7 +1472,7 @@ static void rtllib_associate_complete_wq(void *data)netdev_info (ieee->dev,"Using G rates:%d\n" , ieee->rate); }else { ieee->rate =22 ; - ieee->SetWirelessMode (ieee->dev,IEEE_B ); + ieee->set_wireless_mode (ieee->dev,IEEE_B );netdev_info (ieee->dev,"Using B rates:%d\n" , ieee->rate); }if (ieee->ht_info->bCurrentHTSupport && ieee->ht_info->enable_ht) {
@@ -1656,13 +1656,13 @@ inline void rtllib_softmac_new_net(struct rtllib_device *ieee, (ieee->modulation & RTLLIB_OFDM_MODULATION)) { ieee->rate = 108; - ieee->SetWirelessMode(ieee->dev, + ieee->set_wireless_mode(ieee->dev, IEEE_G); netdev_info(ieee->dev, "Using G rates\n"); } else { ieee->rate =22 ; - ieee->SetWirelessMode (ieee->dev, + ieee->set_wireless_mode (ieee->dev,IEEE_B );netdev_info (ieee->dev,"Using B rates\n" );
@@ -2237,11 +2237,11 @@ static void rtllib_rx_auth_resp(struct rtllib_device *ieee, struct sk_buff *skb) }/* Dummy wirless mode setting to avoid encryption issue */ if (bSupportNmode) { - ieee->SetWirelessMode (ieee->dev, + ieee->set_wireless_mode (ieee->dev, ieee->current_network.mode); }else {/*TODO*/ - ieee->SetWirelessMode (ieee->dev,IEEE_G ); + ieee->set_wireless_mode (ieee->dev,IEEE_G ); } if ((ieee->current_network.mode == IEEE_N_24G) &&
@@ -2570,7 +2570,7 @@ static void rtllib_start_ibss_wq(void *data) } ieee->current_network.qos_data.supported =0 ; - ieee->SetWirelessMode (ieee->dev,IEEE_G ); + ieee->set_wireless_mode (ieee->dev,IEEE_G ); ieee->current_network.mode = ieee->mode; ieee->current_network.atim_window =0 ; ieee->current_network.capability =WLAN_CAPABILITY_IBSS ;
Signature · 1 line
2.34.1
PATCH v3 2/4 staging: rtl8192e: Rename variable SetBWModeHandler
In reply to Yogesh HegdeRename variable SetBWModeHandler to set_bw_mode_handler to avoid CamelCase which is not accepted by checkpatch.
---
v3: Revert back to v1 of the patch as suggested by Greg Kroah-Hartman
<[email protected]>.
v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.
--- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 2 +- drivers/staging/rtl8192e/rtl819x_HTProc.c | 4 ++-- drivers/staging/rtl8192e/rtllib.h | 6 +++--- drivers/staging/rtl8192e/rtllib_softmac_wx.c | 4 ++-- 4 files changed, 8 insertions(+), 8 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_core.c +1 -1
@@ -718,7 +718,7 @@ static void _rtl92e_init_priv_handler(struct net_device *dev) priv->rtllib->handle_beacon = _rtl92e_handle_beacon; priv->rtllib->set_wireless_mode = rtl92e_set_wireless_mode; priv->rtllib->LeisurePSLeave = rtl92e_leisure_ps_leave; - priv->rtllib->SetBWModeHandler = rtl92e_set_bw_mode; + priv->rtllib->set_bw_mode_handler = rtl92e_set_bw_mode; priv->rf_set_chan = rtl92e_set_channel; priv->rtllib->start_send_beacons = rtl92e_start_beacon;
drivers/staging/rtl8192e/rtl819x_HTProc.c +2 -2
@@ -835,11 +835,11 @@ static void HTSetConnectBwModeCallback(struct rtllib_device *ieee) ieee->set_chan (ieee->dev, ieee->current_network.channel); - ieee->SetBWModeHandler (ieee->dev,HT_CHANNEL_WIDTH_20_40 , + ieee->set_bw_mode_handler (ieee->dev,HT_CHANNEL_WIDTH_20_40 , ht_info->CurSTAExtChnlOffset); }else { ieee->set_chan (ieee->dev, ieee->current_network.channel); - ieee->SetBWModeHandler (ieee->dev,HT_CHANNEL_WIDTH_20 , + ieee->set_bw_mode_handler (ieee->dev,HT_CHANNEL_WIDTH_20 ,HT_EXTCHNL_OFFSET_NO_EXT ); }
drivers/staging/rtl8192e/rtllib.h +3 -3
@@ -1704,9 +1704,9 @@ struct rtllib_device {/* check whether Tx hw resource available */ short (*check_nic_enough_desc)(struct net_device *dev,int queue_index); -void (*SetBWModeHandler)(struct net_device *dev, -enum ht_channel_width bandwidth, -enum ht_extchnl_offset Offset); +void (*set_bw_mode_handler)(struct net_device *dev, +enum ht_channel_width bandwidth, +enum ht_extchnl_offset Offset);bool (*GetNmodeSupportBySecCfg)(struct net_device *dev);void (*set_wireless_mode)(struct net_device *dev,u8 wireless_mode);bool (*GetHalfNmodeSupportByAPsHandler)(struct net_device *dev);
drivers/staging/rtl8192e/rtllib_softmac_wx.c +2 -2
@@ -335,7 +335,7 @@ void rtllib_wx_sync_scan_wq(void *data) b40M =1 ; chan_offset = ieee->ht_info->CurSTAExtChnlOffset; bandwidth = (enum ht_channel_width )ieee->ht_info->bCurBW40MHz; - ieee->SetBWModeHandler (ieee->dev,HT_CHANNEL_WIDTH_20 , + ieee->set_bw_mode_handler (ieee->dev,HT_CHANNEL_WIDTH_20 ,HT_EXTCHNL_OFFSET_NO_EXT ); }
@@ -348,7 +348,7 @@ void rtllib_wx_sync_scan_wq(void *data) ieee->set_chan (ieee->dev, chan -2 ); else ieee->set_chan(ieee->dev, chan); - ieee->SetBWModeHandler (ieee->dev, bandwidth, chan_offset); + ieee->set_bw_mode_handler (ieee->dev, bandwidth, chan_offset); }else { ieee->set_chan (ieee->dev, chan); }
Signature · 1 line
2.34.1
PATCH v3 3/4 staging: rtl8192e: Rename variable LeisurePSLeave
In reply to Yogesh HegdeRename variable LeisurePSLeave to leisure_ps_leave to avoid CamelCase which is not accepted by checkpatch.
---
v3: Revert back to v1 of the patch as suggested by Greg Kroah-Hartman
<[email protected]>.
v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.
--- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 2 +- drivers/staging/rtl8192e/rtllib.h | 2 +- drivers/staging/rtl8192e/rtllib_rx.c | 2 +- drivers/staging/rtl8192e/rtllib_softmac_wx.c | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-)
drivers/staging/rtl8192e/rtl8192e/rtl_core.c +1 -1
@@ -717,7 +717,7 @@ static void _rtl92e_init_priv_handler(struct net_device *dev) priv->rtllib->handle_assoc_response = _rtl92e_handle_assoc_response; priv->rtllib->handle_beacon = _rtl92e_handle_beacon; priv->rtllib->set_wireless_mode = rtl92e_set_wireless_mode; - priv->rtllib->LeisurePSLeave = rtl92e_leisure_ps_leave; + priv->rtllib->leisure_ps_leave = rtl92e_leisure_ps_leave; priv->rtllib->set_bw_mode_handler = rtl92e_set_bw_mode; priv->rf_set_chan = rtl92e_set_channel;
drivers/staging/rtl8192e/rtllib.h +1 -1
@@ -1721,7 +1721,7 @@ struct rtllib_device {void (*rtllib_ips_leave_wq)(struct net_device *dev);void (*rtllib_ips_leave)(struct net_device *dev); -void (*LeisurePSLeave)(struct net_device *dev); +void (*leisure_ps_leave)(struct net_device *dev);/* This must be the last item so that it points to the data * allocated beyond this structure by alloc_rtllib
drivers/staging/rtl8192e/rtllib_rx.c +1 -1
@@ -1200,7 +1200,7 @@ static void rtllib_rx_check_leave_lps(struct rtllib_device *ieee, u8 unicast,if (((ieee->link_detect_info.NumRxUnicastOkInPeriod + ieee->link_detect_info.NumTxOkInPeriod) >8 ) || (ieee->link_detect_info.NumRxUnicastOkInPeriod >2 )) { - ieee->LeisurePSLeave (ieee->dev); + ieee->leisure_ps_leave (ieee->dev); } } }
drivers/staging/rtl8192e/rtllib_softmac_wx.c +1 -1
@@ -316,7 +316,7 @@ void rtllib_wx_sync_scan_wq(void *data) chan = ieee->current_network.channel; - ieee->LeisurePSLeave (ieee->dev); + ieee->leisure_ps_leave (ieee->dev);/* notify AP to be in PS mode */ rtllib_sta_ps_send_null_frame (ieee,1 );rtllib_sta_ps_send_null_frame (ieee,1 );
Signature · 1 line
2.34.1
PATCH v3 4/4 staging: rtl8192e: Rename variable InitialGainHandler
In reply to Yogesh HegdeRename variable InitialGainHandler to init_gain_handler to avoid CamelCase which is not accepted by checkpatch.
---
v3: Revert back to v1 of the patch as suggested by Greg Kroah-Hartman
<[email protected]>.
v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.
--- drivers/staging/rtl8192e/rtl8192e/r8192E_phy.c | 4 ++-- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 2 +- drivers/staging/rtl8192e/rtllib.h | 2 +- 3 files changed, 4 insertions(+), 4 deletions(-)
drivers/staging/rtl8192e/rtl8192e/r8192E_phy.c +2 -2
@@ -1109,11 +1109,11 @@ void rtl92e_scan_op_backup(struct net_device *dev, u8 Operation)if (priv->up) {switch (Operation) {case SCAN_OPT_BACKUP : - priv->rtllib->InitialGainHandler (dev, IG_Backup); + priv->rtllib->init_gain_handler (dev, IG_Backup);break ;case SCAN_OPT_RESTORE : - priv->rtllib->InitialGainHandler (dev, IG_Restore); + priv->rtllib->init_gain_handler (dev, IG_Restore);break ; } }
drivers/staging/rtl8192e/rtl8192e/rtl_core.c +1 -1
@@ -734,7 +734,7 @@ static void _rtl92e_init_priv_handler(struct net_device *dev) priv->rtllib->SetHwRegHandler = rtl92e_set_reg; priv->rtllib->AllowAllDestAddrHandler = rtl92e_set_monitor_mode; - priv->rtllib->InitialGainHandler = rtl92e_init_gain; + priv->rtllib->init_gain_handler = rtl92e_init_gain; priv->rtllib->rtllib_ips_leave_wq = rtl92e_rtllib_ips_leave_wq; priv->rtllib->rtllib_ips_leave = rtl92e_rtllib_ips_leave; priv->rtllib->ScanOperationBackupHandler = rtl92e_scan_op_backup;
drivers/staging/rtl8192e/rtllib.h +1 -1
@@ -1711,7 +1711,7 @@ struct rtllib_device {void (*set_wireless_mode)(struct net_device *dev,u8 wireless_mode);bool (*GetHalfNmodeSupportByAPsHandler)(struct net_device *dev);u8 (*rtllib_ap_sec_type)(struct rtllib_device *ieee); -void (*InitialGainHandler)(struct net_device *dev,u8 Operation); +void (*init_gain_handler)(struct net_device *dev,u8 Operation);void (*ScanOperationBackupHandler)(struct net_device *dev,u8 Operation);void (*SetHwRegHandler)(struct net_device *dev,u8 variable,u8 *val);
Signature · 1 line
2.34.1
Quoted 20 lines · Yogesh Hegde
Rename variables in struct
rtllib_deviceto avoid CamelCase which is not accepted by checkpatch.---
v3: The driver is split into 2 modules, calling the functions directly which
the v2 of the patchset does breaks compile. So reverting back to v1 of the patch as suggested by Greg Kroah-Hartman <[email protected]>.v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.Yogesh Hegde (4):
staging: rtl8192e: Rename variable SetWirelessMode
staging: rtl8192e: Rename variable SetBWModeHandler
staging: rtl8192e: Rename variable LeisurePSLeave
staging: rtl8192e: Rename variable InitialGainHandler
Quoted 9 lines
drivers/staging/rtl8192e/rtl8192e/r8192E_phy.c | 4 ++-- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 8 ++++---- drivers/staging/rtl8192e/rtl819x_HTProc.c | 4 ++-- drivers/staging/rtl8192e/rtllib.h | 12 ++++++------ drivers/staging/rtl8192e/rtllib_rx.c | 2 +- drivers/staging/rtl8192e/rtllib_softmac.c | 12 ++++++------ drivers/staging/rtl8192e/rtllib_softmac_wx.c | 6 +++--- 7 files changed, 24 insertions(+), 24 deletions(-)
This patch series alone is fine. But when my patch series ([PATCH 0/9] staging: rtl8192e: Remove unsupported modes a and 5G) is applied before it fails as we change same lines. Will see what happens.
Greg Kroah-Hartman
maintainerQuoted 30 lines · Philipp Hortmann
Quoted 20 lines · Yogesh Hegde
Rename variables in struct
rtllib_deviceto avoid CamelCase which is not accepted by checkpatch.---
v3: The driver is split into 2 modules, calling the functions directly which
the v2 of the patchset does breaks compile. So reverting back to v1 of the patch as suggested by Greg Kroah-Hartman <[email protected]>.v2: Removed the variable and called the function directly instead of
just renaming the variable as suggested by Greg Kroah-Hartman <[email protected]>.Yogesh Hegde (4):
staging: rtl8192e: Rename variable SetWirelessMode
staging: rtl8192e: Rename variable SetBWModeHandler
staging: rtl8192e: Rename variable LeisurePSLeave
staging: rtl8192e: Rename variable InitialGainHandlerQuoted 9 lines
drivers/staging/rtl8192e/rtl8192e/r8192E_phy.c | 4 ++-- drivers/staging/rtl8192e/rtl8192e/rtl_core.c | 8 ++++---- drivers/staging/rtl8192e/rtl819x_HTProc.c | 4 ++-- drivers/staging/rtl8192e/rtllib.h | 12 ++++++------ drivers/staging/rtl8192e/rtllib_rx.c | 2 +- drivers/staging/rtl8192e/rtllib_softmac.c | 12 ++++++------ drivers/staging/rtl8192e/rtllib_softmac_wx.c | 6 +++--- 7 files changed, 24 insertions(+), 24 deletions(-)
Quoted 3 lines
This patch series alone is fine. But when my patch series ([PATCH 0/9]
staging: rtl8192e: Remove unsupported modes a and 5G) is applied before it fails as we change same lines. Will see what happens.
Yes, none of these apply :(
Yogesh, can you rebase this on my staging-next branch and resend?
thanks,
greg k-h
Hi Greg,
Quoted 8 lines · Greg Kroah-Hartman
Quoted 3 lines · Philipp Hortmann
This patch series alone is fine. But when my patch series ([PATCH 0/9]
staging: rtl8192e: Remove unsupported modes a and 5G) is applied before it fails as we change same lines. Will see what happens.Yes, none of these apply :(
Yogesh, can you rebase this on my staging-next branch and resend?
Sure, will rebase and resend. Did you mean staging-testing branch instead of staging-next branch ?
The patch series is rebased to commit "f99bbb4412ce axis-fifo: remove the unnecessary dev_info()" which is the HEAD of staging-next. Latest changes by Philipp are merged into staging-testing branch. Let me know if you still want to rebase it to staging-next branch.
Regards
Yogesh
Greg Kroah-Hartman
maintainerQuoted 7 lines · Yogesh Hegde
Hi Greg,
Quoted 5 lines · Greg Kroah-Hartman
Quoted 3 lines · Philipp Hortmann
This patch series alone is fine. But when my patch series ([PATCH 0/9]
staging: rtl8192e: Remove unsupported modes a and 5G) is applied before it fails as we change same lines. Will see what happens.
Quoted 5 lines
Quoted 3 lines
Yes, none of these apply :(
Yogesh, can you rebase this on my staging-next branch and resend?
Sure, will rebase and resend. Did you mean staging-testing branch instead of staging-next branch ?
Yes, sorry.