All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] staging: rtl8723bs: add whitespace before operator
@ 2023-05-13 12:10 Atin Bainada
  2023-05-13 12:58 ` Greg KH
  0 siblings, 1 reply; 4+ messages in thread
From: Atin Bainada @ 2023-05-13 12:10 UTC (permalink / raw)
  To: gregkh; +Cc: linux-staging, Atin Bainada

fix the following post-commit hook checkpatch error:

spaces required around that '?' (ctx:VxW)
2278: FILE: rtl8723b_hal_init.c:2278:
+                       pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
                                                               ^

Signed-off-by: Atin Bainada <hi@atinb.me>
---
 drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
index c3c1b49674d3..abfaf1eebf5b 100644
--- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
+++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
@@ -2275,7 +2275,7 @@ void Hal_EfuseParseBTCoexistInfo_8723B(
 			pHalData->EEPROMBluetoothAntNum = tempval & BIT(0);
 			/*  EFUSE_0xC3[6] == 0, S1(Main)-RF_PATH_A; */
 			/*  EFUSE_0xC3[6] == 1, S0(Aux)-RF_PATH_B */
-			pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
+			pHalData->ant_path = (tempval & BIT(6)) ? RF_PATH_B : RF_PATH_A;
 		} else {
 			pHalData->EEPROMBluetoothAntNum = Ant_x1;
 			if (pHalData->PackageType == PACKAGE_QFN68)
-- 
2.40.0



^ permalink raw reply related	[flat|nested] 4+ messages in thread

* Re: [PATCH] staging: rtl8723bs: add whitespace before operator
  2023-05-13 12:10 [PATCH] staging: rtl8723bs: add whitespace before operator Atin Bainada
@ 2023-05-13 12:58 ` Greg KH
  2023-05-16 10:31   ` Atin
  0 siblings, 1 reply; 4+ messages in thread
From: Greg KH @ 2023-05-13 12:58 UTC (permalink / raw)
  To: Atin Bainada; +Cc: linux-staging

On Sat, May 13, 2023 at 12:10:16PM +0000, Atin Bainada wrote:
> fix the following post-commit hook checkpatch error:

We have no default "post-commit hooks" :)

You can run checkpatch.pl on a file, perhaps that is what you did here?

> spaces required around that '?' (ctx:VxW)
> 2278: FILE: rtl8723b_hal_init.c:2278:
> +                       pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
>                                                                ^
> 
> Signed-off-by: Atin Bainada <hi@atinb.me>
> ---
>  drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> index c3c1b49674d3..abfaf1eebf5b 100644
> --- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> +++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> @@ -2275,7 +2275,7 @@ void Hal_EfuseParseBTCoexistInfo_8723B(
>  			pHalData->EEPROMBluetoothAntNum = tempval & BIT(0);
>  			/*  EFUSE_0xC3[6] == 0, S1(Main)-RF_PATH_A; */
>  			/*  EFUSE_0xC3[6] == 1, S0(Aux)-RF_PATH_B */
> -			pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
> +			pHalData->ant_path = (tempval & BIT(6)) ? RF_PATH_B : RF_PATH_A;

Why not rewrite this as a real if () statement to make it more
understandable?

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] staging: rtl8723bs: add whitespace before operator
  2023-05-13 12:58 ` Greg KH
@ 2023-05-16 10:31   ` Atin
  2023-05-16 10:47     ` Dan Carpenter
  0 siblings, 1 reply; 4+ messages in thread
From: Atin @ 2023-05-16 10:31 UTC (permalink / raw)
  To: Greg KH; +Cc: linux-staging

I've sent an updated patch with the changes you suggested, please check.

Thanks,

Atin Bainada



------- Original Message -------
On Saturday, May 13th, 2023 at 6:28 PM, Greg KH <gregkh@linuxfoundation.org> wrote:


> 
> 
> On Sat, May 13, 2023 at 12:10:16PM +0000, Atin Bainada wrote:
> 
> > fix the following post-commit hook checkpatch error:
> 
> 
> We have no default "post-commit hooks" :)
> 
> You can run checkpatch.pl on a file, perhaps that is what you did here?
> 
> > spaces required around that '?' (ctx:VxW)
> > 2278: FILE: rtl8723b_hal_init.c:2278:
> > + pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
> > ^
> > 
> > Signed-off-by: Atin Bainada hi@atinb.me
> > ---
> > drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> > index c3c1b49674d3..abfaf1eebf5b 100644
> > --- a/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> > +++ b/drivers/staging/rtl8723bs/hal/rtl8723b_hal_init.c
> > @@ -2275,7 +2275,7 @@ void Hal_EfuseParseBTCoexistInfo_8723B(
> > pHalData->EEPROMBluetoothAntNum = tempval & BIT(0);
> > /* EFUSE_0xC3[6] == 0, S1(Main)-RF_PATH_A; /
> > / EFUSE_0xC3[6] == 1, S0(Aux)-RF_PATH_B */
> > - pHalData->ant_path = (tempval & BIT(6))? RF_PATH_B : RF_PATH_A;
> > + pHalData->ant_path = (tempval & BIT(6)) ? RF_PATH_B : RF_PATH_A;
> 
> 
> Why not rewrite this as a real if () statement to make it more
> understandable?
> 
> thanks,
> 
> greg k-h

^ permalink raw reply	[flat|nested] 4+ messages in thread

* Re: [PATCH] staging: rtl8723bs: add whitespace before operator
  2023-05-16 10:31   ` Atin
@ 2023-05-16 10:47     ` Dan Carpenter
  0 siblings, 0 replies; 4+ messages in thread
From: Dan Carpenter @ 2023-05-16 10:47 UTC (permalink / raw)
  To: Atin; +Cc: Greg KH, linux-staging

On Tue, May 16, 2023 at 10:31:07AM +0000, Atin wrote:
> I've sent an updated patch with the changes you suggested, please check.
> 

Please wait for a minimum of two weeks (not including the merge window)
before asking for feedback.

regards,
dan carpenter


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2023-05-16 10:52 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-05-13 12:10 [PATCH] staging: rtl8723bs: add whitespace before operator Atin Bainada
2023-05-13 12:58 ` Greg KH
2023-05-16 10:31   ` Atin
2023-05-16 10:47     ` Dan Carpenter

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.