mirror of
https://github.com/torvalds/linux.git
synced 2024-11-27 14:41:39 +00:00
staging: rtl8188eu: clean up the useless code
The two bool variables singletone and carrier_sup are always false and the following if statement can't be true, these code are useless, so remove them. Reported-by: Tosk Robot <tencent_os_robot@tencent.com> Signed-off-by: Kaixu Xia <kaixuxia@tencent.com> Link: https://lore.kernel.org/r/1605442400-16108-1-git-send-email-kaixuxia@tencent.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
parent
6b8fb5ecf7
commit
9822b90444
@ -1200,7 +1200,6 @@ void rtl88eu_phy_iq_calibrate(struct adapter *adapt, bool recovery)
|
|||||||
bool pathaok, pathbok;
|
bool pathaok, pathbok;
|
||||||
s32 reg_e94, reg_e9c, reg_ea4, reg_eb4, reg_ebc, reg_ec4;
|
s32 reg_e94, reg_e9c, reg_ea4, reg_eb4, reg_ebc, reg_ec4;
|
||||||
bool is12simular, is13simular, is23simular;
|
bool is12simular, is13simular, is23simular;
|
||||||
bool singletone = false, carrier_sup = false;
|
|
||||||
u32 iqk_bb_reg_92c[IQK_BB_REG_NUM] = {
|
u32 iqk_bb_reg_92c[IQK_BB_REG_NUM] = {
|
||||||
rOFDM0_XARxIQImbalance, rOFDM0_XBRxIQImbalance,
|
rOFDM0_XARxIQImbalance, rOFDM0_XBRxIQImbalance,
|
||||||
rOFDM0_ECCAThreshold, rOFDM0_AGCRSSITable,
|
rOFDM0_ECCAThreshold, rOFDM0_AGCRSSITable,
|
||||||
@ -1214,9 +1213,6 @@ void rtl88eu_phy_iq_calibrate(struct adapter *adapt, bool recovery)
|
|||||||
if (!(dm_odm->SupportAbility & ODM_RF_CALIBRATION))
|
if (!(dm_odm->SupportAbility & ODM_RF_CALIBRATION))
|
||||||
return;
|
return;
|
||||||
|
|
||||||
if (singletone || carrier_sup)
|
|
||||||
return;
|
|
||||||
|
|
||||||
if (recovery) {
|
if (recovery) {
|
||||||
ODM_RT_TRACE(dm_odm, ODM_COMP_INIT, ODM_DBG_LOUD,
|
ODM_RT_TRACE(dm_odm, ODM_COMP_INIT, ODM_DBG_LOUD,
|
||||||
("phy_iq_calibrate: Return due to recovery!\n"));
|
("phy_iq_calibrate: Return due to recovery!\n"));
|
||||||
@ -1312,14 +1308,11 @@ void rtl88eu_phy_iq_calibrate(struct adapter *adapt, bool recovery)
|
|||||||
|
|
||||||
void rtl88eu_phy_lc_calibrate(struct adapter *adapt)
|
void rtl88eu_phy_lc_calibrate(struct adapter *adapt)
|
||||||
{
|
{
|
||||||
bool singletone = false, carrier_sup = false;
|
|
||||||
u32 timeout = 2000, timecount = 0;
|
u32 timeout = 2000, timecount = 0;
|
||||||
struct odm_dm_struct *dm_odm = &adapt->HalData->odmpriv;
|
struct odm_dm_struct *dm_odm = &adapt->HalData->odmpriv;
|
||||||
|
|
||||||
if (!(dm_odm->SupportAbility & ODM_RF_CALIBRATION))
|
if (!(dm_odm->SupportAbility & ODM_RF_CALIBRATION))
|
||||||
return;
|
return;
|
||||||
if (singletone || carrier_sup)
|
|
||||||
return;
|
|
||||||
|
|
||||||
while (*dm_odm->pbScanInProcess && timecount < timeout) {
|
while (*dm_odm->pbScanInProcess && timecount < timeout) {
|
||||||
mdelay(50);
|
mdelay(50);
|
||||||
|
Loading…
Reference in New Issue
Block a user