staging: rtl8723bs: cleanup hal/hal_intf.c
cover staging: rtl8723bs: cleanup hal/hal_intf.c
This series removes some wrapper functions from hal/hal_intf.c and replaces them with direct calls to the wrapped functions. This will simplify the code and remove an unnecessary abstraction layer above the hardware.
Also renames several affected functions to snake_case to fix checkpatch.pl warnings.
Nikolay Kulikov (11):
staging: rtl8723bs: remove wrapper rtw_hal_chip_configure()
staging: rtl8723bs: remove wrapper rtw_hal_read_chip_info()
staging: rtl8723bs: remove wrapper rtw_hal_read_chip_version()
staging: rtl8723bs: remove wrapper rtw_hal_def_value_init()
staging: rtl8723bs: remove wrapper rtw_hal_free_data()
staging: rtl8723bs: remove wrapper rtw_hal_dm_init()
staging: rtl8723bs: remove wrapper rtw_hal_enable_interrupt()
staging: rtl8723bs: remove wrapper rtw_hal_disable_interrupt()
staging: rtl8723bs: rename ReadAdapterInfo8723BS() to snake_case
staging: rtl8723bs: rename EnableInterrupt8723BSdio() to snake_case
staging: rtl8723bs: rename DisableInterrupt8723BSdio() to snake_case
drivers/staging/rtl8723bs/hal/hal_intf.c | 41 ------------------- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 5 +-- drivers/staging/rtl8723bs/hal/sdio_ops.c | 36 +++++++--------- drivers/staging/rtl8723bs/include/hal_intf.h | 13 ------ .../staging/rtl8723bs/include/rtl8723b_recv.h | 2 +- drivers/staging/rtl8723bs/include/sdio_ops.h | 4 +- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 10 ++--- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 15 ++++--- 8 files changed, 31 insertions(+), 95 deletions(-)
Signature · 1 line
2.53.0
PATCH 1/11 staging: rtl8723bs: remove wrapper rtw_hal_chip_configure()
Remove the rtw_hal_chip_configure() function, as it's just a wrapper that calls rtl8723bs_interface_configure() directly. Instead, call rtl8723bs_interface_configure() from the appropriate places. This will reduce code complexity and improve readability by removing unnecessary abstraction.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 1 - drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 3 ++- 3 files changed, 2 insertions(+), 7 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -7,11 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_chip_configure (struct adapter *padapter) -{ -rtl8723bs_interface_configure (padapter); -} -void rtw_hal_read_chip_info (struct adapter *padapter) {ReadAdapterInfo8723BS (padapter);
drivers/staging/rtl8723bs/include/hal_intf.h +0 -1
@@ -195,7 +195,6 @@ void rtw_hal_get_hwreg(struct adapter *padapter, u8 variable, u8 *val);void rtw_hal_set_hwreg_with_buf (struct adapter *padapter,u8 variable,u8 *pbuf,int len); -void rtw_hal_chip_configure (struct adapter *padapter);void rtw_hal_read_chip_info (struct adapter *padapter);void rtw_hal_read_chip_version (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +2 -1
@@ -6,6 +6,7 @@******************************************************************************/ #include <drv_types.h> #include <hal_btcoex.h> +#include <hal_data.h> #include <linux/jiffies.h> #ifndef dev_to_sdio_func
@@ -265,7 +266,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const structrtw_hal_read_chip_version (padapter); -rtw_hal_chip_configure (padapter); +rtl8723bs_interface_configure (padapter);hal_btcoex_Initialize ((void *)padapter);
Signature · 1 line
2.53.0
PATCH 2/11 staging: rtl8723bs: remove wrapper rtw_hal_read_chip_info()
In reply to Nikolay KulikovRemove the rtw_hal_read_chip_info() function, as it's just a wrapper that calls ReadAdapterInfo8723BS() directly. Replace all its calls to the ReadAdapterInfo8723BS() function. This will remove an extra level of abstraction and simplify the code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 1 - drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 2 +- 3 files changed, 1 insertion(+), 7 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -7,11 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_read_chip_info (struct adapter *padapter) -{ -ReadAdapterInfo8723BS (padapter); -} -void rtw_hal_read_chip_version (struct adapter *padapter) {rtl8723b_read_chip_version (padapter);
drivers/staging/rtl8723bs/include/hal_intf.h +0 -1
@@ -195,7 +195,6 @@ void rtw_hal_get_hwreg(struct adapter *padapter, u8 variable, u8 *val);void rtw_hal_set_hwreg_with_buf (struct adapter *padapter,u8 variable,u8 *pbuf,int len); -void rtw_hal_read_chip_info (struct adapter *padapter);void rtw_hal_read_chip_version (struct adapter *padapter);u8 rtw_hal_get_def_var (struct adapter *padapter,enum hal_def_variable eVariable,void *pValue);
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +1 -1
@@ -271,7 +271,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const structhal_btcoex_Initialize ((void *)padapter);/* 3 6. read efuse/eeprom data */ -rtw_hal_read_chip_info (padapter); +ReadAdapterInfo8723BS (padapter);/* 3 7. init driver common data */ if (rtw_init_drv_sw (padapter) == _FAIL)
Signature · 1 line
2.53.0
PATCH 3/11 staging: rtl8723bs: remove wrapper rtw_hal_read_chip_version()
In reply to Nikolay KulikovRemove rtw_hal_read_chip_version() function, as it's just a wrapper that calls rtl8723b_read_chip_version() directly. Replace all its calls to the rtl8723b_read_chip_version(). This will remove an extra level of abstraction and simplify the code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 2 +- 3 files changed, 1 insertion(+), 8 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -7,11 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_read_chip_version (struct adapter *padapter) -{ -rtl8723b_read_chip_version (padapter); -} -void rtw_hal_def_value_init (struct adapter *padapter) {rtl8723bs_init_default_value (padapter);
drivers/staging/rtl8723bs/include/hal_intf.h +0 -2
@@ -195,8 +195,6 @@ void rtw_hal_get_hwreg(struct adapter *padapter, u8 variable, u8 *val);void rtw_hal_set_hwreg_with_buf (struct adapter *padapter,u8 variable,u8 *pbuf,int len); -void rtw_hal_read_chip_version (struct adapter *padapter); -u8 rtw_hal_get_def_var (struct adapter *padapter,enum hal_def_variable eVariable,void *pValue);void rtw_hal_set_odm_var (struct adapter *padapter,enum hal_odm_variable eVariable,void *pValue1,bool bSet);
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +1 -1
@@ -264,7 +264,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const structif (rtw_init_io_priv (padapter, sdio_set_intf_ops) == _FAIL) goto free_hal_data; -rtw_hal_read_chip_version (padapter); +rtl8723b_read_chip_version (padapter);rtl8723bs_interface_configure (padapter);
Signature · 1 line
2.53.0
PATCH 4/11 staging: rtl8723bs: remove wrapper rtw_hal_def_value_init()
In reply to Nikolay KulikovRemove unnecessary wrapper and call rtl8723bs_init_default_value() function directly to simplify code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 4 ++-- 3 files changed, 2 insertions(+), 9 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -7,11 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_def_value_init (struct adapter *padapter) -{ -rtl8723bs_init_default_value (padapter); -} -void rtw_hal_free_data (struct adapter *padapter) {/* free HAL Data */
drivers/staging/rtl8723bs/include/hal_intf.h +0 -2
@@ -181,8 +181,6 @@ typedef s32 (*c2h_id_filter)(u8 *c2h_evt);#define RX_PNOWakeUp 0x55#define AP_WakeUp 0x66 -void rtw_hal_def_value_init (struct adapter *padapter); -void rtw_hal_free_data (struct adapter *padapter);void rtw_hal_dm_init (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/os_intfs.c +2 -2
@@ -550,7 +550,7 @@ static void rtw_init_default_value(struct adapter *padapter)rtw_update_registrypriv_dev_network (padapter);/* hal_priv */ -rtw_hal_def_value_init (padapter); +rtl8723bs_init_default_value (padapter);/* misc. */ RTW_ENABLE_FUNC (padapter,DF_RX_BIT );
@@ -609,7 +609,7 @@ void rtw_reset_drv_sw(struct adapter *padapter)struct pwrctrl_priv *pwrctrlpriv =adapter_to_pwrctl (padapter);/* hal_priv */ -rtw_hal_def_value_init (padapter); +rtl8723bs_init_default_value (padapter);RTW_ENABLE_FUNC (padapter,DF_RX_BIT );RTW_ENABLE_FUNC (padapter,DF_TX_BIT );
Signature · 1 line
2.53.0
PATCH 5/11 staging: rtl8723bs: remove wrapper rtw_hal_free_data()
In reply to Nikolay KulikovRemove unnecessary wrapper and call rtw_hal_data_deinit() function directly to simplify code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 6 ------ drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- 3 files changed, 1 insertion(+), 9 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -6
@@ -7,12 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_free_data (struct adapter *padapter) -{ -/* free HAL Data */ -rtw_hal_data_deinit (padapter); -} -void rtw_hal_dm_init (struct adapter *padapter) {rtl8723b_init_dm_priv (padapter);
drivers/staging/rtl8723bs/include/hal_intf.h +0 -2
@@ -181,8 +181,6 @@ typedef s32 (*c2h_id_filter)(u8 *c2h_evt);#define RX_PNOWakeUp 0x55#define AP_WakeUp 0x66 -void rtw_hal_free_data (struct adapter *padapter); -void rtw_hal_dm_init (struct adapter *padapter);uint rtw_hal_init (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/os_intfs.c +1 -1
@@ -734,7 +734,7 @@ u8 rtw_free_drv_sw(struct adapter *padapter)/* kfree((void *)padapter); */ -rtw_hal_free_data (padapter); +rtw_hal_data_deinit (padapter);/* free the old_pnetdev */ if (padapter->rereg_nd_name_priv.old_pnetdev) {
Signature · 1 line
2.53.0
PATCH 6/11 staging: rtl8723bs: remove wrapper rtw_hal_dm_init()
In reply to Nikolay KulikovRemove unnecessary wrapper and call rtl8723b_init_dm_priv() function directly to simplify code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- 3 files changed, 1 insertion(+), 8 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -7,11 +7,6 @@#include <drv_types.h> #include <hal_data.h> -void rtw_hal_dm_init (struct adapter *padapter) -{ -rtl8723b_init_dm_priv (padapter); -} -static void rtw_hal_init_opmode (struct adapter *padapter) {enum ndis_802_11_network_infrastructure networkType = Ndis802_11InfrastructureMax;
drivers/staging/rtl8723bs/include/hal_intf.h +0 -2
@@ -181,8 +181,6 @@ typedef s32 (*c2h_id_filter)(u8 *c2h_evt);#define RX_PNOWakeUp 0x55#define AP_WakeUp 0x66 -void rtw_hal_dm_init (struct adapter *padapter); -uint rtw_hal_init (struct adapter *padapter);uint rtw_hal_deinit (struct adapter *padapter);void rtw_hal_stop (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/os_intfs.c +1 -1
@@ -674,7 +674,7 @@ u8 rtw_init_drv_sw(struct adapter *padapter)rtw_init_pwrctrl_priv (padapter); -rtw_hal_dm_init (padapter); +rtl8723b_init_dm_priv (padapter);return _SUCCESS;
Signature · 1 line
2.53.0
PATCH 7/11 staging: rtl8723bs: remove wrapper rtw_hal_enable_interrupt()
In reply to Nikolay KulikovRemove unnecessary wrapper and call EnableInterrupt8723BSdio() function directly to simplify code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/include/hal_intf.h | 1 - drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 3 +-- 3 files changed, 1 insertion(+), 8 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -94,11 +94,6 @@ void rtw_hal_set_odm_var(struct adapter *padapter, enum hal_odm_variable eVariabSetHalODMVar (padapter, eVariable, pValue1, bSet); } -void rtw_hal_enable_interrupt (struct adapter *padapter) -{ -EnableInterrupt8723BSdio (padapter); -} -void rtw_hal_disable_interrupt (struct adapter *padapter) {DisableInterrupt8723BSdio (padapter);
drivers/staging/rtl8723bs/include/hal_intf.h +0 -1
@@ -193,7 +193,6 @@ u8 rtw_hal_get_def_var(struct adapter *padapter, enum hal_def_variable eVariablevoid rtw_hal_set_odm_var (struct adapter *padapter,enum hal_odm_variable eVariable,void *pValue1,bool bSet); -void rtw_hal_enable_interrupt (struct adapter *padapter);void rtw_hal_disable_interrupt (struct adapter *padapter);u8 rtw_hal_check_ips_status (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +1 -2
@@ -204,8 +204,7 @@ static void sd_intf_start(struct adapter *padapter)if (!padapter)return ; -/* hal dep */ -rtw_hal_enable_interrupt (padapter); +EnableInterrupt8723BSdio (padapter); }static void sd_intf_stop (struct adapter *padapter)
Signature · 1 line
2.53.0
PATCH 8/11 staging: rtl8723bs: remove wrapper rtw_hal_disable_interrupt()
In reply to Nikolay KulikovRemove unnecessary wrapper and call DisableInterrupt8723BSdio() function directly to simplify the code.
--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 --- drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 5 ++--- 5 files changed, 3 insertions(+), 14 deletions(-)
drivers/staging/rtl8723bs/hal/hal_intf.c +0 -5
@@ -94,11 +94,6 @@ void rtw_hal_set_odm_var(struct adapter *padapter, enum hal_odm_variable eVariabSetHalODMVar (padapter, eVariable, pValue1, bSet); } -void rtw_hal_disable_interrupt (struct adapter *padapter) -{ -DisableInterrupt8723BSdio (padapter); -} -u8 rtw_hal_check_ips_status (struct adapter *padapter) {return CheckIPSStatus (padapter);
drivers/staging/rtl8723bs/hal/sdio_halinit.c +0 -3
@@ -640,9 +640,6 @@ u32 rtl8723bs_hal_init(struct adapter *padapter)return _SUCCESS; } -/* Disable Interrupt first. */ -/* rtw_hal_disable_interrupt(padapter); */ - ret =_InitPowerOn_8723BS (padapter);if (ret == _FAIL)return _FAIL;
drivers/staging/rtl8723bs/include/hal_intf.h +0 -2
@@ -193,8 +193,6 @@ u8 rtw_hal_get_def_var(struct adapter *padapter, enum hal_def_variable eVariablevoid rtw_hal_set_odm_var (struct adapter *padapter,enum hal_odm_variable eVariable,void *pValue1,bool bSet); -void rtw_hal_disable_interrupt (struct adapter *padapter); -u8 rtw_hal_check_ips_status (struct adapter *padapter);s32 rtw_hal_xmitframe_enqueue (struct adapter *padapter,struct xmit_frame *pxmitframe);
drivers/staging/rtl8723bs/os_dep/os_intfs.c +1 -1
@@ -1140,7 +1140,7 @@ static int rtw_resume_process_normal(struct adapter *padapter)if (ret) goto exit; } -rtw_hal_disable_interrupt (padapter); +DisableInterrupt8723BSdio (padapter);/* if (sdio_alloc_irq(adapter_to_dvobj(padapter)) != _SUCCESS) */ if ((padapter->intf_alloc_irq) && (padapter->intf_alloc_irq (adapter_to_dvobj (padapter)) != _SUCCESS)) { ret =-1 ;
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +2 -3
@@ -212,8 +212,7 @@ static void sd_intf_stop(struct adapter *padapter)if (!padapter)return ; -/* hal dep */ -rtw_hal_disable_interrupt (padapter); +DisableInterrupt8723BSdio (padapter); }
@@ -282,7 +281,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const struct/* set mac addr */ rtw_macaddr_cfg (&psdio->func->dev, padapter->eeprompriv.mac_addr); -rtw_hal_disable_interrupt (padapter); +DisableInterrupt8723BSdio (padapter); status = _SUCCESS;
Signature · 1 line
2.53.0
Greg KH
maintainerRe: [PATCH 08/11] staging: rtl8723bs: remove wrapper rtw_hal_disable_interrupt()
Quoted 11 lines · Nikolay Kulikov
Remove unnecessary wrapper and call
DisableInterrupt8723BSdio()function directly to simplify the code.Signed-off-by Nikolay Kulikov <[email protected]>--- drivers/staging/rtl8723bs/hal/hal_intf.c | 5 ----- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 3 --- drivers/staging/rtl8723bs/include/hal_intf.h | 2 -- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 5 ++--- 5 files changed, 3 insertions(+), 14 deletions(-)
This patch did not apply for some reason, maybe due to other changes from someone else?
thanks,
greg k-h
PATCH 9/11 staging: rtl8723bs: rename ReadAdapterInfo8723BS() to snake_case
In reply to Nikolay KulikovRename function ReadAdapterInfo8723BS() to rtw_read_adapter_info() to comply with Linux kernel coding style and fix checkpatch.pl warning.
--- drivers/staging/rtl8723bs/hal/sdio_halinit.c | 2 +- drivers/staging/rtl8723bs/include/rtl8723b_recv.h | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-)
drivers/staging/rtl8723bs/hal/sdio_halinit.c +1 -1
@@ -1115,7 +1115,7 @@ static s32 _ReadAdapterInfo8723BS(struct adapter *padapter)return _SUCCESS; } -void ReadAdapterInfo8723BS (struct adapter *padapter) +void rtw_read_adapter_info (struct adapter *padapter) {/* Read EEPROM size before call any EEPROM function */ padapter->EepromAddressSize =GetEEPROMSize8723B (padapter);
drivers/staging/rtl8723bs/include/rtl8723b_recv.h +1 -1
@@ -90,6 +90,6 @@ void rtl8723b_process_phy_info(struct adapter *padapter, void *prframe);void rtl8723b_read_chip_version (struct adapter *padapter);void rtl8723bs_init_default_value (struct adapter *padapter);void rtl8723bs_interface_configure (struct adapter *padapter); -void ReadAdapterInfo8723BS (struct adapter *padapter); +void rtw_read_adapter_info (struct adapter *padapter);#endif
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +1 -1
@@ -269,7 +269,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const structhal_btcoex_Initialize ((void *)padapter);/* 3 6. read efuse/eeprom data */ -ReadAdapterInfo8723BS (padapter); +rtw_read_adapter_info (padapter);/* 3 7. init driver common data */ if (rtw_init_drv_sw (padapter) == _FAIL)
Signature · 1 line
2.53.0
PATCH 10/11 staging: rtl8723bs: rename EnableInterrupt8723BSdio() to snake_case
In reply to Nikolay KulikovRename function EnableInterrupt8723BSdio() to rtw_sdio_enable_interrupt() and format its description to comply with Linux kernel coding style.
Declare this function without 'extern' prototype in the .h file to fix checkpatch.pl warning.
--- drivers/staging/rtl8723bs/hal/sdio_ops.c | 19 ++++++++----------- drivers/staging/rtl8723bs/include/sdio_ops.h | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 2 +- 3 files changed, 10 insertions(+), 13 deletions(-)
drivers/staging/rtl8723bs/hal/sdio_ops.c +8 -11
@@ -712,17 +712,14 @@ void InitSysInterrupt8723BSdio(struct adapter *adapter) haldata->SysIntrMask = (0 ); } -/* */ -/* Description: */ -/* Enalbe SDIO Host Interrupt Mask configuration on SDIO local domain. */ -/* */ -/* Assumption: */ -/* 1. Using SDIO Local register ONLY for configuration. */ -/* 2. PASSIVE LEVEL */ -/* */ -/* Created by Roger, 2011.02.11. */ -/* */ -void EnableInterrupt8723BSdio (struct adapter *adapter) +/* +* Enable SDIO Host Interrupt Mask configuration on SDIO local domain. +* +* Assumption: +* 1. Using SDIO Local register ONLY for configuration. +* 2. PASSIVE LEVEL +*/ +void rtw_sdio_enable_interrupt (struct adapter *adapter) {struct hal_com_data *haldata;__le32 himr;
drivers/staging/rtl8723bs/include/sdio_ops.h +1 -1
@@ -27,7 +27,7 @@ extern u8 CheckIPSStatus(struct adapter *padapter);extern void InitInterrupt8723BSdio (struct adapter *padapter);extern void InitSysInterrupt8723BSdio (struct adapter *padapter); -extern void EnableInterrupt8723BSdio (struct adapter *padapter); +void rtw_sdio_enable_interrupt (struct adapter *padapter);extern void DisableInterrupt8723BSdio (struct adapter *padapter);extern u8 HalQueryTxBufferStatus8723BSdio (struct adapter *padapter);extern void HalQueryTxOQTBufferStatus8723BSdio (struct adapter *padapter);
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +1 -1
@@ -204,7 +204,7 @@ static void sd_intf_start(struct adapter *padapter)if (!padapter)return ; -EnableInterrupt8723BSdio (padapter); +rtw_sdio_enable_interrupt (padapter); }static void sd_intf_stop (struct adapter *padapter)
Signature · 1 line
2.53.0
PATCH 11/11 staging: rtl8723bs: rename DisableInterrupt8723BSdio() to snake_case
In reply to Nikolay KulikovRename function DisableInterrupt8723BSdio() to rtw_sdio_disable_interrupt() and format its description to comply with Linux kernel coding style.
Declare this function without 'extern' prototype in the .h file to fix checkpatch.pl warning.
--- drivers/staging/rtl8723bs/hal/sdio_ops.c | 17 +++++++---------- drivers/staging/rtl8723bs/include/sdio_ops.h | 2 +- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 4 ++-- 4 files changed, 11 insertions(+), 14 deletions(-)
drivers/staging/rtl8723bs/hal/sdio_ops.c +7 -10
@@ -742,16 +742,13 @@ void rtw_sdio_enable_interrupt(struct adapter *adapter)rtw_write8 (adapter,REG_C2HEVT_CLEAR ,C2H_EVT_HOST_CLOSE ); } -/* */ -/* Description: */ -/* Disable SDIO Host IMR configuration to mask unnecessary interrupt service. */ -/* */ -/* Assumption: */ -/* Using SDIO Local register ONLY for configuration. */ -/* */ -/* Created by Roger, 2011.02.11. */ -/* */ -void DisableInterrupt8723BSdio (struct adapter *adapter) +/* +* Disable SDIO Host IMR configuration to mask unnecessary interrupt service. +* +* Assumption: +* Using SDIO Local register ONLY for configuration. +*/ +void rtw_sdio_disable_interrupt (struct adapter *adapter) {__le32 himr;
drivers/staging/rtl8723bs/include/sdio_ops.h +1 -1
@@ -28,7 +28,7 @@ extern u8 CheckIPSStatus(struct adapter *padapter);extern void InitInterrupt8723BSdio (struct adapter *padapter);extern void InitSysInterrupt8723BSdio (struct adapter *padapter);void rtw_sdio_enable_interrupt (struct adapter *padapter); -extern void DisableInterrupt8723BSdio (struct adapter *padapter); +void rtw_sdio_disable_interrupt (struct adapter *padapter);extern u8 HalQueryTxBufferStatus8723BSdio (struct adapter *padapter);extern void HalQueryTxOQTBufferStatus8723BSdio (struct adapter *padapter);#endif /* !__SDIO_OPS_H__ */
drivers/staging/rtl8723bs/os_dep/os_intfs.c +1 -1
@@ -1140,7 +1140,7 @@ static int rtw_resume_process_normal(struct adapter *padapter)if (ret) goto exit; } -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter);/* if (sdio_alloc_irq(adapter_to_dvobj(padapter)) != _SUCCESS) */ if ((padapter->intf_alloc_irq) && (padapter->intf_alloc_irq (adapter_to_dvobj (padapter)) != _SUCCESS)) { ret =-1 ;
drivers/staging/rtl8723bs/os_dep/sdio_intf.c +2 -2
@@ -212,7 +212,7 @@ static void sd_intf_stop(struct adapter *padapter)if (!padapter)return ; -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter); }
@@ -281,7 +281,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const struct/* set mac addr */ rtw_macaddr_cfg (&psdio->func->dev, padapter->eeprompriv.mac_addr); -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter); status = _SUCCESS;
Signature · 1 line
2.53.0
Greg KH
maintainerRe: [PATCH 11/11] staging: rtl8723bs: rename DisableInterrupt8723BSdio() to snake_case
Quoted 94 lines · Nikolay Kulikov
Rename function
DisableInterrupt8723BSdio()tortw_sdio_disable_interrupt()and format its description to comply with Linux kernel coding style.
Declare this function without 'extern' prototype in the .h file to fix checkpatch.pl warning.Signed-off-by Nikolay Kulikov <[email protected]>--- drivers/staging/rtl8723bs/hal/sdio_ops.c | 17 +++++++---------- drivers/staging/rtl8723bs/include/sdio_ops.h | 2 +- drivers/staging/rtl8723bs/os_dep/os_intfs.c | 2 +- drivers/staging/rtl8723bs/os_dep/sdio_intf.c | 4 ++-- 4 files changed, 11 insertions(+), 14 deletions(-)drivers/staging/rtl8723bs/hal/sdio_ops.c +7
-10@@ -742,16 +742,13 @@ void rtw_sdio_enable_interrupt(struct adapter *adapter)rtw_write8 (adapter,REG_C2HEVT_CLEAR ,C2H_EVT_HOST_CLOSE ); } -/* */ -/* Description: */ -/* Disable SDIO Host IMR configuration to mask unnecessary interrupt service. */ -/* */ -/* Assumption: */ -/* Using SDIO Local register ONLY for configuration. */ -/* */ -/* Created by Roger, 2011.02.11. */ -/* */ -void DisableInterrupt8723BSdio (struct adapter *adapter) +/* +* Disable SDIO Host IMR configuration to mask unnecessary interrupt service. +* +* Assumption: +* Using SDIO Local register ONLY for configuration. +*/ +void rtw_sdio_disable_interrupt (struct adapter *adapter) {__le32 himr;drivers/staging/rtl8723bs/include/sdio_ops.h +1
-1@@ -28,7 +28,7 @@ extern u8 CheckIPSStatus(struct adapter *padapter);extern void InitInterrupt8723BSdio (struct adapter *padapter);extern void InitSysInterrupt8723BSdio (struct adapter *padapter);void rtw_sdio_enable_interrupt (struct adapter *padapter); -extern void DisableInterrupt8723BSdio (struct adapter *padapter); +void rtw_sdio_disable_interrupt (struct adapter *padapter);extern u8 HalQueryTxBufferStatus8723BSdio (struct adapter *padapter);extern void HalQueryTxOQTBufferStatus8723BSdio (struct adapter *padapter);#endif /* !__SDIO_OPS_H__ */ drivers/staging/rtl8723bs/os_dep/os_intfs.c +1
-1@@ -1140,7 +1140,7 @@ static int rtw_resume_process_normal(struct adapter *padapter)if (ret) goto exit; } -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter);/* if (sdio_alloc_irq(adapter_to_dvobj(padapter)) != _SUCCESS) */ if ((padapter->intf_alloc_irq) && (padapter->intf_alloc_irq (adapter_to_dvobj (padapter)) != _SUCCESS)) { ret =-1 ;drivers/staging/rtl8723bs/os_dep/sdio_intf.c +2
-2@@ -212,7 +212,7 @@ static void sd_intf_stop(struct adapter *padapter)if (!padapter)return ; -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter); }@@ -281,7 +281,7 @@ static struct adapter *rtw_sdio_if1_init(struct dvobj_priv *dvobj, const struct/* set mac addr */ rtw_macaddr_cfg (&psdio->func->dev, padapter->eeprompriv.mac_addr); -DisableInterrupt8723BSdio (padapter); +rtw_sdio_disable_interrupt (padapter); status = _SUCCESS;Signature · 1 line
2.53.0
This one did not apply as well. Can you rebase those 2 patches on my staging-next branch when it shows up on kernel.org tomorrow, and resend them?
thanks,
greg k-h