2021-04-30 07:46:01

by Fabio Aiuto

[permalink] [raw]
Subject: [PATCH 02/43] staging: rlt8723bs: remove if-else blocks left empty by ODM_RT_TRACE deletion

remove if-else blocks left empty by ODM_RT_TRACE deletion.
remove unused variables to suppress compiler warnings.

Signed-off-by: Fabio Aiuto <[email protected]>
---
drivers/staging/rtl8723bs/hal/HalPhyRf.c | 13 -------------
drivers/staging/rtl8723bs/hal/HalPhyRf_8723B.c | 9 +--------
drivers/staging/rtl8723bs/hal/odm_PathDiv.c | 8 --------
3 files changed, 1 insertion(+), 29 deletions(-)

diff --git a/drivers/staging/rtl8723bs/hal/HalPhyRf.c b/drivers/staging/rtl8723bs/hal/HalPhyRf.c
index 2e10817bf3dd..b8e385fdda89 100644
--- a/drivers/staging/rtl8723bs/hal/HalPhyRf.c
+++ b/drivers/staging/rtl8723bs/hal/HalPhyRf.c
@@ -118,9 +118,6 @@ void ODM_TXPowerTrackingCallback_ThermalMeter(struct adapter *Adapter)

/* 4 3. Initialize ThermalValues of RFCalibrateInfo */

- if (pDM_Odm->RFCalibrateInfo.bReloadtxpowerindex)
- {}
-
/* 4 4. Calculate average thermal meter */

pDM_Odm->RFCalibrateInfo.ThermalValue_AVG[pDM_Odm->RFCalibrateInfo.ThermalValue_AVG_index] = ThermalValue;
@@ -273,16 +270,6 @@ void ODM_TXPowerTrackingCallback_ThermalMeter(struct adapter *Adapter)
/* to increase TX power. Otherwise, EVM will be bad. */
/* */
/* 2012/04/25 MH Add for tx power tracking to set tx power in tx agc for 88E. */
- if (ThermalValue > pDM_Odm->RFCalibrateInfo.ThermalValue) {
- if (c.RfPathCount > 1)
- {}
-
- } else if (ThermalValue < pDM_Odm->RFCalibrateInfo.ThermalValue) { /* Low temperature */
-
- if (c.RfPathCount > 1)
- {}
-
- }

if (ThermalValue > pHalData->EEPROMThermalMeter) {
for (p = ODM_RF_PATH_A; p < c.RfPathCount; p++)
diff --git a/drivers/staging/rtl8723bs/hal/HalPhyRf_8723B.c b/drivers/staging/rtl8723bs/hal/HalPhyRf_8723B.c
index 471418f3f724..858aafc24931 100644
--- a/drivers/staging/rtl8723bs/hal/HalPhyRf_8723B.c
+++ b/drivers/staging/rtl8723bs/hal/HalPhyRf_8723B.c
@@ -689,8 +689,7 @@ static u8 phy_PathA_RxIQK8723B(
(tmp < 0xf)
)
result |= 0x02;
- else /* if Tx not OK, ignore Rx */
- {}
+
return result;
}

@@ -988,8 +987,6 @@ static u8 phy_PathB_RxIQK8723B(struct adapter *padapter, bool configPathB)
(tmp < 0xf)
)
result |= 0x02;
- else
- {}

return result;
}
@@ -1500,7 +1497,6 @@ static void phy_IQCalibrate_8723B(
result[t][2] = (PHY_QueryBBReg(pDM_Odm->Adapter, rRx_Power_Before_IQK_A_2, bMaskDWord)&0x3FF0000)>>16;
result[t][3] = (PHY_QueryBBReg(pDM_Odm->Adapter, rRx_Power_After_IQK_A_2, bMaskDWord)&0x3FF0000)>>16;
break;
- } else {
}
}

@@ -1533,13 +1529,10 @@ static void phy_IQCalibrate_8723B(
result[t][6] = (PHY_QueryBBReg(pDM_Odm->Adapter, rRx_Power_Before_IQK_A_2, bMaskDWord)&0x3FF0000)>>16;
result[t][7] = (PHY_QueryBBReg(pDM_Odm->Adapter, rRx_Power_After_IQK_A_2, bMaskDWord)&0x3FF0000)>>16;
break;
- } else {
}
}

/* Allen end */
- if (0x00 == PathBOK) {
- }
}

/* Back to BB mode, load original value */
diff --git a/drivers/staging/rtl8723bs/hal/odm_PathDiv.c b/drivers/staging/rtl8723bs/hal/odm_PathDiv.c
index cfcbc3741803..bedce2c10b22 100644
--- a/drivers/staging/rtl8723bs/hal/odm_PathDiv.c
+++ b/drivers/staging/rtl8723bs/hal/odm_PathDiv.c
@@ -9,16 +9,8 @@

void odm_PathDiversityInit(void *pDM_VOID)
{
- struct dm_odm_t *pDM_Odm = (struct dm_odm_t *)pDM_VOID;
-
- if (!(pDM_Odm->SupportAbility & ODM_BB_PATH_DIV))
- {}
}

void odm_PathDiversity(void *pDM_VOID)
{
- struct dm_odm_t *pDM_Odm = (struct dm_odm_t *)pDM_VOID;
-
- if (!(pDM_Odm->SupportAbility & ODM_BB_PATH_DIV))
- {}
}
--
2.20.1


2021-04-30 14:32:23

by Bryan Brattlof

[permalink] [raw]
Subject: Re: [PATCH 02/43] staging: rlt8723bs: remove if-else blocks left empty by ODM_RT_TRACE deletion

On Fri, Apr 30, 2021 at 09:43:20AM +0200, Fabio Aiuto wrote:
>remove if-else blocks left empty by ODM_RT_TRACE deletion.
>remove unused variables to suppress compiler warnings.
>
>Signed-off-by: Fabio Aiuto <[email protected]>
>

Hi Fabio!

I just wanted to point out a spelling mistake in the title 'rlt8723bs'
in the off chance you submit a v2.

Way to go switching this over to netdev btw.
--
~Bryan

2021-04-30 14:50:59

by Fabio Aiuto

[permalink] [raw]
Subject: Re: [PATCH 02/43] staging: rlt8723bs: remove if-else blocks left empty by ODM_RT_TRACE deletion

On Fri, Apr 30, 2021 at 02:31:08PM +0000, Bryan Brattlof wrote:
> On Fri, Apr 30, 2021 at 09:43:20AM +0200, Fabio Aiuto wrote:
> >remove if-else blocks left empty by ODM_RT_TRACE deletion.
> >remove unused variables to suppress compiler warnings.
> >
> >Signed-off-by: Fabio Aiuto <[email protected]>
> >
>
> Hi Fabio!
>
> I just wanted to point out a spelling mistake in the title 'rlt8723bs'
> in the off chance you submit a v2.
>
> Way to go switching this over to netdev btw.

what do you mean exactly?

> --
> ~Bryan
>

Hi Brian,

thank you! Ouch I've just sent a v2 for other issues...
no problem I will send a v3, sorry all for spamming.

fabio

2021-04-30 15:04:06

by Bryan Brattlof

[permalink] [raw]
Subject: Re: [PATCH 02/43] staging: rlt8723bs: remove if-else blocks left empty by ODM_RT_TRACE deletion

On Fri, Apr 30, 2021 at 04:50:00PM +0200, Fabio Aiuto wrote:
>On Fri, Apr 30, 2021 at 02:31:08PM +0000, Bryan Brattlof wrote:
>> On Fri, Apr 30, 2021 at 09:43:20AM +0200, Fabio Aiuto wrote:
>> >remove if-else blocks left empty by ODM_RT_TRACE deletion.
>> >remove unused variables to suppress compiler warnings.
>> >
>> >Signed-off-by: Fabio Aiuto <[email protected]>
>> >
>>
>> Hi Fabio!
>>
>> I just wanted to point out a spelling mistake in the title 'rlt8723bs'
>> in the off chance you submit a v2.
>>
>> Way to go switching this over to netdev btw.
>
>what do you mean exactly?
>

I was just praising you for all the work you are putting into this
driver. :)

>
>> --
>> ~Bryan
>>
>
>Hi Brian,
>
>thank you! Ouch I've just sent a v2 for other issues...
>no problem I will send a v3, sorry all for spamming.
>

Don't worry about me. I would wait until Greg and others have feedback
on your v2 before sending a v3 with this minor nitpick.

--
~Bryan

2021-04-30 15:10:00

by Fabio Aiuto

[permalink] [raw]
Subject: Re: [PATCH 02/43] staging: rlt8723bs: remove if-else blocks left empty by ODM_RT_TRACE deletion

On Fri, Apr 30, 2021 at 03:02:38PM +0000, Bryan Brattlof wrote:
> On Fri, Apr 30, 2021 at 04:50:00PM +0200, Fabio Aiuto wrote:
> >On Fri, Apr 30, 2021 at 02:31:08PM +0000, Bryan Brattlof wrote:
> >> On Fri, Apr 30, 2021 at 09:43:20AM +0200, Fabio Aiuto wrote:
> >> >remove if-else blocks left empty by ODM_RT_TRACE deletion.
> >> >remove unused variables to suppress compiler warnings.
> >> >
> >> >Signed-off-by: Fabio Aiuto <[email protected]>
> >> >
> >>
> >> Hi Fabio!
> >>
> >> I just wanted to point out a spelling mistake in the title 'rlt8723bs'
> >> in the off chance you submit a v2.
> >>
> >> Way to go switching this over to netdev btw.
> >
> >what do you mean exactly?
> >
>
> I was just praising you for all the work you are putting into this
> driver. :)

thank you Bryan, I'm not to praise for my english :-D

>
> >
> >> --
> >> ~Bryan
> >>
> >
> >Hi Brian,
> >
> >thank you! Ouch I've just sent a v2 for other issues...
> >no problem I will send a v3, sorry all for spamming.
> >
>
> Don't worry about me. I would wait until Greg and others have feedback
> on your v2 before sending a v3 with this minor nitpick.
>
> --
> ~Bryan
>

too late, v3 submitted:(. But I understand what you say and agreed.
So let's wait a little more next time.

thank you,

fabio.