staging: rtl8188eu: do not use comparisons on bool tests
authorValentina Manea <valentina.manea.m@gmail.com>
Fri, 25 Oct 2013 08:39:56 +0000 (11:39 +0300)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 28 Oct 2013 21:26:45 +0000 (14:26 -0700)
This patch fixes coccinelle errors regarding comparisons
used in bool tests.

Signed-off-by: Valentina Manea <valentina.manea.m@gmail.com>
Reviewed-by: Rusty Russell <rusty@rustcorp.com.au>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8188eu/core/rtw_pwrctrl.c
drivers/staging/rtl8188eu/hal/HalPhyRf_8188e.c

index 58a1661f5a84714cdf377461c929eb617cc35397..b45461fe20fea50fe86da38e7240e9b18174c315 100644 (file)
@@ -193,7 +193,7 @@ void rtw_ps_processor(struct adapter *padapter)
        if (pwrpriv->ips_mode_req == IPS_NONE)
                goto exit;
 
-       if (rtw_pwr_unassociated_idle(padapter) == false)
+       if (!rtw_pwr_unassociated_idle(padapter))
                goto exit;
 
        if ((pwrpriv->rf_pwrstate == rf_on) && ((pwrpriv->pwr_state_check_cnts%4) == 0)) {
index bb43793fd1ec2f57ff6eb1d6019189957b9ed188..8a7947d8de7fe2678a48d9c72cde9fc6f47def36 100644 (file)
@@ -819,7 +819,7 @@ void _PHY_SaveADDARegisters(struct adapter *adapt, u32 *ADDAReg, u32 *ADDABackup
        struct hal_data_8188e   *pHalData = GET_HAL_DATA(adapt);
        struct odm_dm_struct *dm_odm = &pHalData->odmpriv;
 
-       if (ODM_CheckPowerStatus(adapt) == false)
+       if (!ODM_CheckPowerStatus(adapt))
                return;
 
        ODM_RT_TRACE(dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, ("Save ADDA parameters.\n"));
@@ -888,7 +888,7 @@ _PHY_PathADDAOn(
        ODM_RT_TRACE(dm_odm, ODM_COMP_CALIBRATION, ODM_DBG_LOUD, ("ADDA ON.\n"));
 
        pathOn = isPathAOn ? 0x04db25a4 : 0x0b1b25a4;
-       if (false == is2t) {
+       if (!is2t) {
                pathOn = 0x0bdb25a0;
                ODM_SetBBReg(dm_odm, ADDAReg[0], bMaskDWord, 0x0b1b25a0);
        } else {
@@ -1296,7 +1296,7 @@ void PHY_IQCalibrate_8188E(struct adapter *adapt, bool recovery)
        bool is2t;
 
        is2t = (dm_odm->RFType == ODM_2T2R) ? true : false;
-       if (ODM_CheckPowerStatus(adapt) == false)
+       if (!ODM_CheckPowerStatus(adapt))
                return;
 
        if (!(dm_odm->SupportAbility & ODM_RF_CALIBRATION))