* [PATCH v2] staging: rtl8723bs: remove braces around single statements
@ 2025-03-26 9:53 Abraham Samuel Adekunle
0 siblings, 0 replies; 4+ messages in thread
From: Abraham Samuel Adekunle @ 2025-03-26 9:53 UTC (permalink / raw)
To: Greg Kroah-Hartman, Julia Lawall, linux-staging, linux-kernel
Cc: linux-staging, linux-kernel
The code contains braces around single statements in the if blocks
which are unnecessary according to the Linux kernel coding style.
Remove the braces to improve readability and maintain consistency.
Reported by checkpatch:
WARNING: braces {} are not necessary for single statement blocks
Signed-off-by: Abraham Samuel Adekunle <abrahamadekunle50@gmail.com>
---
Changes in v2:
- Remove extra blank line
drivers/staging/rtl8723bs/core/rtw_pwrctrl.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
index c60e179bb2e1..74a8fcf18e84 100644
--- a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
+++ b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
@@ -56,9 +56,8 @@ int _ips_leave(struct adapter *padapter)
pwrpriv->ips_leave_cnts++;
result = rtw_ips_pwr_up(padapter);
- if (result == _SUCCESS) {
+ if (result == _SUCCESS)
pwrpriv->rf_pwrstate = rf_on;
- }
pwrpriv->bips_processing = false;
pwrpriv->bkeepfwalive = false;
@@ -549,9 +548,8 @@ void LeaveAllPowerSaveMode(struct adapter *Adapter)
LPS_Leave_check(Adapter);
} else {
- if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off) {
+ if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off)
ips_leave(Adapter);
- }
}
}
--
2.34.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* [PATCH v2] staging: rtl8723bs: remove braces around single statements
@ 2025-03-26 9:59 Abraham Samuel Adekunle
2025-03-26 10:06 ` Julia Lawall
0 siblings, 1 reply; 4+ messages in thread
From: Abraham Samuel Adekunle @ 2025-03-26 9:59 UTC (permalink / raw)
To: outreachy
The code contains braces around single statements in the if blocks
which are unnecessary according to the Linux kernel coding style.
Remove the braces to improve readability and maintain consistency.
Reported by checkpatch:
WARNING: braces {} are not necessary for single statement blocks
Signed-off-by: Abraham Samuel Adekunle <abrahamadekunle50@gmail.com>
---
Changes in v2:
- Remove extra blank line
drivers/staging/rtl8723bs/core/rtw_pwrctrl.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
index c60e179bb2e1..74a8fcf18e84 100644
--- a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
+++ b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
@@ -56,9 +56,8 @@ int _ips_leave(struct adapter *padapter)
pwrpriv->ips_leave_cnts++;
result = rtw_ips_pwr_up(padapter);
- if (result == _SUCCESS) {
+ if (result == _SUCCESS)
pwrpriv->rf_pwrstate = rf_on;
- }
pwrpriv->bips_processing = false;
pwrpriv->bkeepfwalive = false;
@@ -549,9 +548,8 @@ void LeaveAllPowerSaveMode(struct adapter *Adapter)
LPS_Leave_check(Adapter);
} else {
- if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off) {
+ if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off)
ips_leave(Adapter);
- }
}
}
--
2.34.1
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH v2] staging: rtl8723bs: remove braces around single statements
2025-03-26 9:59 [PATCH v2] staging: rtl8723bs: remove braces around single statements Abraham Samuel Adekunle
@ 2025-03-26 10:06 ` Julia Lawall
2025-03-26 12:11 ` Samuel Abraham
0 siblings, 1 reply; 4+ messages in thread
From: Julia Lawall @ 2025-03-26 10:06 UTC (permalink / raw)
To: Abraham Samuel Adekunle; +Cc: outreachy
On Wed, 26 Mar 2025, Abraham Samuel Adekunle wrote:
> The code contains braces around single statements in the if blocks
> which are unnecessary according to the Linux kernel coding style.
>
> Remove the braces to improve readability and maintain consistency.
>
> Reported by checkpatch:
>
> WARNING: braces {} are not necessary for single statement blocks
Are there no other email addresses that shoudl receive this patch?
julia
>
> Signed-off-by: Abraham Samuel Adekunle <abrahamadekunle50@gmail.com>
> ---
> Changes in v2:
> - Remove extra blank line
>
> drivers/staging/rtl8723bs/core/rtw_pwrctrl.c | 6 ++----
> 1 file changed, 2 insertions(+), 4 deletions(-)
>
> diff --git a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
> index c60e179bb2e1..74a8fcf18e84 100644
> --- a/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
> +++ b/drivers/staging/rtl8723bs/core/rtw_pwrctrl.c
> @@ -56,9 +56,8 @@ int _ips_leave(struct adapter *padapter)
> pwrpriv->ips_leave_cnts++;
>
> result = rtw_ips_pwr_up(padapter);
> - if (result == _SUCCESS) {
> + if (result == _SUCCESS)
> pwrpriv->rf_pwrstate = rf_on;
> - }
> pwrpriv->bips_processing = false;
>
> pwrpriv->bkeepfwalive = false;
> @@ -549,9 +548,8 @@ void LeaveAllPowerSaveMode(struct adapter *Adapter)
>
> LPS_Leave_check(Adapter);
> } else {
> - if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off) {
> + if (adapter_to_pwrctl(Adapter)->rf_pwrstate == rf_off)
> ips_leave(Adapter);
> - }
> }
> }
>
> --
> 2.34.1
>
>
>
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH v2] staging: rtl8723bs: remove braces around single statements
2025-03-26 10:06 ` Julia Lawall
@ 2025-03-26 12:11 ` Samuel Abraham
0 siblings, 0 replies; 4+ messages in thread
From: Samuel Abraham @ 2025-03-26 12:11 UTC (permalink / raw)
To: Julia Lawall; +Cc: outreachy
On Wed, Mar 26, 2025 at 11:06 AM Julia Lawall <julia.lawall@inria.fr> wrote:
>
>
>
> On Wed, 26 Mar 2025, Abraham Samuel Adekunle wrote:
>
> > The code contains braces around single statements in the if blocks
> > which are unnecessary according to the Linux kernel coding style.
> >
> > Remove the braces to improve readability and maintain consistency.
> >
> > Reported by checkpatch:
> >
> > WARNING: braces {} are not necessary for single statement blocks
>
>
> Are there no other email addresses that shoudl receive this patch?
>
> julia
>
Yes I mistakenly omitted the Outreachy mailing list in the first v2
patch I sent. I will update and add all
recipients in a patch v3. Thank you
Adekunle
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2025-03-26 12:11 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-03-26 9:59 [PATCH v2] staging: rtl8723bs: remove braces around single statements Abraham Samuel Adekunle
2025-03-26 10:06 ` Julia Lawall
2025-03-26 12:11 ` Samuel Abraham
-- strict thread matches above, loose matches on Subject: below --
2025-03-26 9:53 Abraham Samuel Adekunle
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.