From: Martin Kaiser Date: Sat, 8 Jan 2022 12:49:56 +0000 (+0100) Subject: staging: r8188eu: CurrentCckTxPwrIdx is set but not used X-Git-Url: http://git.maquefel.me/?a=commitdiff_plain;h=e0d4a5e3b5512f2454b5377be84227ed627abf60;p=linux.git staging: r8188eu: CurrentCckTxPwrIdx is set but not used CurrentCckTxPwrIdx in struct hal_data_8188e is set but not used. It can be removed. The phy_PowerIndexCheck88E function is now empty. Remove it as well. Signed-off-by: Martin Kaiser Link: https://lore.kernel.org/r/20220108124959.313215-10-martin@kaiser.cx Signed-off-by: Greg Kroah-Hartman --- diff --git a/drivers/staging/r8188eu/hal/rtl8188e_phycfg.c b/drivers/staging/r8188eu/hal/rtl8188e_phycfg.c index a80f40fccf09e..c1639df8b1e74 100644 --- a/drivers/staging/r8188eu/hal/rtl8188e_phycfg.c +++ b/drivers/staging/r8188eu/hal/rtl8188e_phycfg.c @@ -581,14 +581,6 @@ static void getTxPowerIndex88E(struct adapter *Adapter, u8 channel, u8 *cckPower BW40PowerLevel[RF_PATH_A] = pHalData->Index24G_BW40_Base[index]; } -static void phy_PowerIndexCheck88E(struct adapter *Adapter, u8 channel, u8 *cckPowerLevel, - u8 *ofdmPowerLevel, u8 *BW20PowerLevel, u8 *BW40PowerLevel) -{ - struct hal_data_8188e *pHalData = &Adapter->haldata; - - pHalData->CurrentCckTxPwrIdx = cckPowerLevel[0]; -} - /*----------------------------------------------------------------------------- * Function: SetTxPowerLevel8190() * @@ -619,8 +611,6 @@ PHY_SetTxPowerLevel8188E( getTxPowerIndex88E(Adapter, channel, &cckPowerLevel[0], &ofdmPowerLevel[0], &BW20PowerLevel[0], &BW40PowerLevel[0]); - phy_PowerIndexCheck88E(Adapter, channel, &cckPowerLevel[0], &ofdmPowerLevel[0], &BW20PowerLevel[0], &BW40PowerLevel[0]); - rtl8188e_PHY_RF6052SetCckTxPower(Adapter, &cckPowerLevel[0]); rtl8188e_PHY_RF6052SetOFDMTxPower(Adapter, &ofdmPowerLevel[0], &BW20PowerLevel[0], &BW40PowerLevel[0], channel); } diff --git a/drivers/staging/r8188eu/include/rtl8188e_hal.h b/drivers/staging/r8188eu/include/rtl8188e_hal.h index fd2ee1739f884..a24cdbfa83de5 100644 --- a/drivers/staging/r8188eu/include/rtl8188e_hal.h +++ b/drivers/staging/r8188eu/include/rtl8188e_hal.h @@ -176,9 +176,6 @@ struct hal_data_8188e { u8 PwrGroupHT20[RF_PATH_MAX][CHANNEL_MAX_NUMBER]; u8 PwrGroupHT40[RF_PATH_MAX][CHANNEL_MAX_NUMBER]; - /* The current Tx Power Level */ - u8 CurrentCckTxPwrIdx; - /* Read/write are allow for following hardware information variables */ u8 pwrGroupCnt; u32 MCSTxPowerLevelOriginalOffset[MAX_PG_GROUP][16];