From f83113d3e6f2cef66890a90d01c5347ece4ecd97 Mon Sep 17 00:00:00 2001 From: Luca Ceresoli Date: Wed, 15 Jul 2015 00:44:54 +0200 Subject: staging: rtl8188eu: remove unused rtw_hal_set_def_var rtw_hal_set_def_var() is never referenced, so remove it. It used to be the only place where the SetHalDefVarHandler callback was called, so get rid of the function pointer as well. Also remove the callback itself, SetHalDefVar8188EUsb(), which was not called anywhere else. Signed-off-by: Luca Ceresoli Cc: Greg Kroah-Hartman Cc: Larry Finger Signed-off-by: Greg Kroah-Hartman --- drivers/staging/rtl8188eu/hal/usb_halinit.c | 70 ----------------------------- 1 file changed, 70 deletions(-) (limited to 'drivers/staging/rtl8188eu/hal/usb_halinit.c') diff --git a/drivers/staging/rtl8188eu/hal/usb_halinit.c b/drivers/staging/rtl8188eu/hal/usb_halinit.c index ffcca6b..6dc0869 100644 --- a/drivers/staging/rtl8188eu/hal/usb_halinit.c +++ b/drivers/staging/rtl8188eu/hal/usb_halinit.c @@ -1961,75 +1961,6 @@ GetHalDefVar8188EUsb( return bResult; } -/* */ -/* Description: */ -/* Change default setting of specified variable. */ -/* */ -static u8 SetHalDefVar8188EUsb(struct adapter *Adapter, enum hal_def_variable eVariable, void *pValue) -{ - struct hal_data_8188e *haldata = GET_HAL_DATA(Adapter); - u8 bResult = _SUCCESS; - - switch (eVariable) { - case HAL_DEF_DBG_DM_FUNC: - { - u8 dm_func = *((u8 *)pValue); - struct odm_dm_struct *podmpriv = &haldata->odmpriv; - - if (dm_func == 0) { /* disable all dynamic func */ - podmpriv->SupportAbility = DYNAMIC_FUNC_DISABLE; - DBG_88E("==> Disable all dynamic function...\n"); - } else if (dm_func == 1) {/* disable DIG */ - podmpriv->SupportAbility &= (~DYNAMIC_BB_DIG); - DBG_88E("==> Disable DIG...\n"); - } else if (dm_func == 2) {/* disable High power */ - podmpriv->SupportAbility &= (~DYNAMIC_BB_DYNAMIC_TXPWR); - } else if (dm_func == 3) {/* disable tx power tracking */ - podmpriv->SupportAbility &= (~DYNAMIC_RF_CALIBRATION); - DBG_88E("==> Disable tx power tracking...\n"); - } else if (dm_func == 5) {/* disable antenna diversity */ - podmpriv->SupportAbility &= (~DYNAMIC_BB_ANT_DIV); - } else if (dm_func == 6) {/* turn on all dynamic func */ - if (!(podmpriv->SupportAbility & DYNAMIC_BB_DIG)) { - struct rtw_dig *pDigTable = &podmpriv->DM_DigTable; - pDigTable->CurIGValue = usb_read8(Adapter, 0xc50); - } - podmpriv->SupportAbility = DYNAMIC_ALL_FUNC_ENABLE; - DBG_88E("==> Turn on all dynamic function...\n"); - } - } - break; - case HAL_DEF_DBG_DUMP_RXPKT: - haldata->bDumpRxPkt = *((u8 *)pValue); - break; - case HAL_DEF_DBG_DUMP_TXPKT: - haldata->bDumpTxPkt = *((u8 *)pValue); - break; - case HW_DEF_FA_CNT_DUMP: - { - u8 bRSSIDump = *((u8 *)pValue); - struct odm_dm_struct *dm_ocm = &(haldata->odmpriv); - if (bRSSIDump) - dm_ocm->DebugComponents = ODM_COMP_DIG|ODM_COMP_FA_CNT; - else - dm_ocm->DebugComponents = 0; - } - break; - case HW_DEF_ODM_DBG_FLAG: - { - u64 DebugComponents = *((u64 *)pValue); - struct odm_dm_struct *dm_ocm = &(haldata->odmpriv); - dm_ocm->DebugComponents = DebugComponents; - } - break; - default: - bResult = _FAIL; - break; - } - - return bResult; -} - static void UpdateHalRAMask8188EUsb(struct adapter *adapt, u32 mac_id, u8 rssi_level) { u8 init_rate = 0; @@ -2200,7 +2131,6 @@ void rtl8188eu_set_hal_ops(struct adapter *adapt) halfunc->SetHwRegHandler = &SetHwReg8188EU; halfunc->GetHwRegHandler = &GetHwReg8188EU; halfunc->GetHalDefVarHandler = &GetHalDefVar8188EUsb; - halfunc->SetHalDefVarHandler = &SetHalDefVar8188EUsb; halfunc->UpdateRAMaskHandler = &UpdateHalRAMask8188EUsb; halfunc->SetBeaconRelatedRegistersHandler = &SetBeaconRelatedRegisters8188EUsb; -- cgit v1.1