Linux kernel staging patches
 help / color / mirror / Atom feed
* [PATCH v2 1/2] staging: rtl8723bs: remove unnecessary braces in rtl8723b_cmd
@ 2025-07-16 17:51 Ignacio Peña
  2025-07-16 17:51 ` [PATCH v2 2/2] staging: rtl8723bs: remove unnecessary commented code " Ignacio Peña
  0 siblings, 1 reply; 3+ messages in thread
From: Ignacio Peña @ 2025-07-16 17:51 UTC (permalink / raw)
  To: gregkh, linux-staging; +Cc: Ignacio Pena

From: Ignacio Pena <ignacio.pena87@gmail.com>

Remove braces that are not necessary for single statement blocks
to fix checkpatch warnings.

Signed-off-by: Ignacio Pena <ignacio.pena87@gmail.com>
---
Changes in v2:
- Dropped the yoda condition fix as Dan Carpenter suggested the
  function needs deeper cleanup
- Split patches to address one type of issue at a time

 drivers/staging/rtl8723bs/hal/rtl8723b_cmd.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/staging/rtl8723bs/hal/rtl8723b_cmd.c b/drivers/staging/rtl8723bs/hal/rtl8723b_cmd.c
index 56526056d..abc123def 100644
--- a/drivers/staging/rtl8723bs/hal/rtl8723b_cmd.c
+++ b/drivers/staging/rtl8723bs/hal/rtl8723b_cmd.c
@@ -57,13 +57,11 @@ s32 FillH2CCmd8723B(struct adapter *padapter, u8 ElementID, u32 CmdLen, u8 *pCmd
 	if (mutex_lock_interruptible(&(adapter_to_dvobj(padapter)->h2c_fwcmd_mutex)))
 		return ret;
 
-	if (!pCmdBuffer) {
+	if (!pCmdBuffer)
 		goto exit;
-	}
 
-	if (CmdLen > RTL8723B_MAX_CMD_LEN) {
+	if (CmdLen > RTL8723B_MAX_CMD_LEN)
 		goto exit;
-	}
 
 	if (padapter->bSurpriseRemoved)
 		goto exit;
-- 
2.39.5

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

end of thread, other threads:[~2025-07-24  9:28 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-16 17:51 [PATCH v2 1/2] staging: rtl8723bs: remove unnecessary braces in rtl8723b_cmd Ignacio Peña
2025-07-16 17:51 ` [PATCH v2 2/2] staging: rtl8723bs: remove unnecessary commented code " Ignacio Peña
2025-07-24  9:28   ` Greg KH

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox