]> www.infradead.org Git - users/dwmw2/linux.git/commitdiff
staging: rtl8723bs: remove braces around single statements
authorAbraham Samuel Adekunle <abrahamadekunle50@gmail.com>
Wed, 26 Mar 2025 12:40:05 +0000 (13:40 +0100)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Mon, 7 Apr 2025 05:38:08 +0000 (06:38 +0100)
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>
Link: https://lore.kernel.org/r/Z+P1pfLSKpiRtpaF@HP-650
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/rtl8723bs/core/rtw_pwrctrl.c

index c60e179bb2e196fcde02903cb9dd03e59d3d2826..74a8fcf18e843af251e23d82971cd03b92940534 100644 (file)
@@ -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);
-               }
        }
 }