pBandType is never set, it stays at the default value 0. Remove it from odm_dm_struct and remove related unneeded code. Signed-off-by: Michael Straube <straube.linux@xxxxxxxxx> --- drivers/staging/r8188eu/hal/HalPhyRf_8188e.c | 2 +- drivers/staging/r8188eu/hal/odm.c | 3 --- drivers/staging/r8188eu/include/odm.h | 8 -------- 3 files changed, 1 insertion(+), 12 deletions(-) diff --git a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c index f01ee3cd8795..8e9fbc9cf84d 100644 --- a/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c +++ b/drivers/staging/r8188eu/hal/HalPhyRf_8188e.c @@ -317,7 +317,7 @@ odm_TXPowerTrackingCallback_ThermalMeter_8188E( X = dm_odm->RFCalibrateInfo.IQKMatrixRegSetting.Value[0][4]; Y = dm_odm->RFCalibrateInfo.IQKMatrixRegSetting.Value[0][5]; - if ((X != 0) && (*dm_odm->pBandType == ODM_BAND_2_4G)) { + if (X != 0) { if ((X & 0x00000200) != 0) /* consider minus */ X = X | 0xFFFFFC00; ele_A = ((X * ele_D) >> 8) & 0x000003FF; diff --git a/drivers/staging/r8188eu/hal/odm.c b/drivers/staging/r8188eu/hal/odm.c index d3d13164ca8f..85bc5050cda5 100644 --- a/drivers/staging/r8188eu/hal/odm.c +++ b/drivers/staging/r8188eu/hal/odm.c @@ -243,9 +243,6 @@ void ODM_CmnInfoHook(struct odm_dm_struct *pDM_Odm, enum odm_common_info_def Cmn case ODM_CMNINFO_WM_MODE: pDM_Odm->pWirelessMode = (u8 *)pValue; break; - case ODM_CMNINFO_BAND: - pDM_Odm->pBandType = (u8 *)pValue; - break; case ODM_CMNINFO_SEC_CHNL_OFFSET: pDM_Odm->pSecChOffset = (u8 *)pValue; break; diff --git a/drivers/staging/r8188eu/include/odm.h b/drivers/staging/r8188eu/include/odm.h index a8e9089433ba..9745069060d7 100644 --- a/drivers/staging/r8188eu/include/odm.h +++ b/drivers/staging/r8188eu/include/odm.h @@ -273,7 +273,6 @@ enum odm_common_info_def { ODM_CMNINFO_TX_UNI, ODM_CMNINFO_RX_UNI, ODM_CMNINFO_WM_MODE, /* ODM_WIRELESS_MODE_E */ - ODM_CMNINFO_BAND, /* ODM_BAND_TYPE_E */ ODM_CMNINFO_SEC_CHNL_OFFSET, /* ODM_SEC_CHNL_OFFSET_E */ ODM_CMNINFO_SEC_MODE, /* ODM_SECURITY_E */ ODM_CMNINFO_BW, /* ODM_BW_E */ @@ -405,11 +404,6 @@ enum odm_wireless_mode { ODM_WM_AUTO = BIT(5), }; -/* ODM_CMNINFO_BAND */ -enum odm_band_type { - ODM_BAND_2_4G = BIT(0), -}; - /* ODM_CMNINFO_SEC_CHNL_OFFSET */ enum odm_sec_chnl_offset { ODM_DONT_CARE = 0, @@ -635,8 +629,6 @@ struct odm_dm_struct { u64 *pNumRxBytesUnicast; /* Wireless mode B/G/A/N = BIT(0)/BIT(1)/BIT(2)/BIT(3) */ u8 *pWirelessMode; /* ODM_WIRELESS_MODE_E */ - /* Frequence band 2.4G/5G = 0/1 */ - u8 *pBandType; /* Secondary channel offset don't_care/below/above = 0/1/2 */ u8 *pSecChOffset; /* Security mode Open/WEP/AES/TKIP = 0/1/2/3 */ -- 2.33.0