staging: r8188eu: remove unneeded parameter from rtl8188e_SetHalODMVar
PATCH 1/1 staging: r8188eu: remove unneeded parameter from rtl8188e_SetHalODMVar
Function rtl8188e_SetHalODMVar is always called with HAL_ODM_STA_INFO. Remove the unneeded parameter eVariable from the function.
Signed-off-by Michael Straube <[email protected]>
--- drivers/staging/r8188eu/core/rtw_ap.c | 4 +-- drivers/staging/r8188eu/core/rtw_mlme.c | 4 +-- drivers/staging/r8188eu/core/rtw_sta_mgt.c | 2 +- .../staging/r8188eu/hal/rtl8188e_hal_init.c | 28 +++++++------------ drivers/staging/r8188eu/include/hal_intf.h | 7 +---- 5 files changed, 16 insertions(+), 29 deletions(-)
drivers/staging/r8188eu/core/rtw_ap.c +2 -2
@@ -447,7 +447,7 @@ void update_bmc_sta(struct adapter *padapter) init_rate =get_highest_rate_idx (tx_ra_bitmap &0x0fffffff ) &0x3f ;/* ap mode */ -rtl8188e_SetHalODMVar (padapter,HAL_ODM_STA_INFO , psta, true); +rtl8188e_SetHalODMVar (padapter, psta, true); {u8 arg =0 ;
@@ -499,7 +499,7 @@ void update_sta_info_apmode(struct adapter *padapter, struct sta_info *psta)DBG_88E ("%s\n" , __func__);/* ap mode */ -rtl8188e_SetHalODMVar (padapter,HAL_ODM_STA_INFO , psta, true); +rtl8188e_SetHalODMVar (padapter, psta, true);if (psecuritypriv->dot11AuthAlgrthm == dot11AuthAlgrthm_8021X) psta->ieee8021x_blocked = true;
drivers/staging/r8188eu/core/rtw_mlme.c +2 -2
@@ -913,7 +913,7 @@ static struct sta_info *rtw_joinbss_update_stainfo(struct adapter *padapter, str psta->aid = pnetwork->join_res; psta->mac_id =0 ;/* sta mode */ -rtl8188e_SetHalODMVar (padapter,HAL_ODM_STA_INFO , psta, true); +rtl8188e_SetHalODMVar (padapter, psta, true);/* security related */ if (padapter->securitypriv.dot11AuthAlgrthm == dot11AuthAlgrthm_8021X) { padapter->securitypriv.binstallGrpkey = false;
@@ -1198,7 +1198,7 @@ void rtw_stassoc_event_callback(struct adapter *adapter, u8 *pbuf) psta->mac_id = (uint )pstassoc->cam_id;DBG_88E ("%s\n" , __func__);/* for ad-hoc mode */ -rtl8188e_SetHalODMVar (adapter,HAL_ODM_STA_INFO , psta, true); +rtl8188e_SetHalODMVar (adapter, psta, true);rtw_sta_media_status_rpt (adapter, psta,1 );if (adapter->securitypriv.dot11AuthAlgrthm == dot11AuthAlgrthm_8021X) psta->dot118021XPrivacy = adapter->securitypriv.dot11PrivacyAlgrthm;
drivers/staging/r8188eu/core/rtw_sta_mgt.c +1 -1
@@ -310,7 +310,7 @@ u32 rtw_free_stainfo(struct adapter *padapter, struct sta_info *psta) }if (!(psta->state &WIFI_AP_STATE )) -rtl8188e_SetHalODMVar (padapter,HAL_ODM_STA_INFO , psta, false); +rtl8188e_SetHalODMVar (padapter, psta, false);spin_lock_bh (&pstapriv->auth_list_lock);if (!list_empty (&psta->auth_list)) {
drivers/staging/r8188eu/hal/rtl8188e_hal_init.c +10 -18
@@ -845,27 +845,19 @@ void rtl8188e_read_chip_version(struct adapter *padapter) pHalData->VersionID = ChipVersion; } -void rtl8188e_SetHalODMVar (struct adapter *Adapter,enum hal_odm_variable eVariable,void *pValue1,bool bSet) +void rtl8188e_SetHalODMVar (struct adapter *Adapter,void *pValue1,bool bSet) {struct hal_data_8188e *pHalData = &Adapter->haldata;struct odm_dm_struct *podmpriv = &pHalData->odmpriv; -switch (eVariable) { -case HAL_ODM_STA_INFO : - { -struct sta_info *psta = (struct sta_info *)pValue1; - -if (bSet) { -DBG_88E ("### Set STA_(%d) info\n" , psta->mac_id); - podmpriv->pODM_StaInfo[psta->mac_id] = psta; -ODM_RAInfo_Init (podmpriv, psta->mac_id); - }else { -DBG_88E ("### Clean STA_(%d) info\n" , psta->mac_id); - podmpriv->pODM_StaInfo[psta->mac_id] =NULL ; - } - } -break ; -default : -break ; +struct sta_info *psta = (struct sta_info *)pValue1; + +if (bSet) { +DBG_88E ("### Set STA_(%d) info\n" , psta->mac_id); + podmpriv->pODM_StaInfo[psta->mac_id] = psta; +ODM_RAInfo_Init (podmpriv, psta->mac_id); + }else { +DBG_88E ("### Clean STA_(%d) info\n" , psta->mac_id); + podmpriv->pODM_StaInfo[psta->mac_id] =NULL ; } }
drivers/staging/r8188eu/include/hal_intf.h +1 -6
@@ -94,10 +94,6 @@ enum hal_def_variable { HAL_DEF_DBG_DUMP_TXPKT, }; -enum hal_odm_variable { -HAL_ODM_STA_INFO , -}; -typedef s32 (*c2h_id_filter )(u8 id);#define is_boot_from_eeprom (adapter) (adapter->eeprompriv.EepromOrEfuse)
@@ -105,8 +101,7 @@ typedef s32 (*c2h_id_filter)(u8 id);void rtl8188eu_interface_configure (struct adapter *adapt);void ReadAdapterInfo8188EU (struct adapter *Adapter);void rtl8188eu_init_default_value (struct adapter *adapt); -void rtl8188e_SetHalODMVar (struct adapter *Adapter, -enum hal_odm_variable eVariable,void *pValue1,bool bSet); +void rtl8188e_SetHalODMVar (struct adapter *Adapter,void *pValue1,bool bSet);u32 rtl8188eu_InitPowerOn (struct adapter *adapt);void rtl8188e_EfusePowerSwitch (struct adapter *pAdapter,u8 PwrState);void rtl8188e_ReadEFuse (struct adapter *Adapter,u16 _offset,u16 _size_byte,u8 *pbuf);
Signature · 1 line
2.34.1