Skip to contentSkip to conversation

Staging: rtl8723au: remove unnecessary break after return

PATCH Superseded Melike Yurtoglu 2 participants 2 messages Feb 25, 2015 Staging

v1 of 2 Superseded Latest is v2 →

lore
Share & tools
lore
#0 lore raw

PATCH 1/1 Staging: rtl8723au: remove unnecessary break after return

WARNING: break is not useful after a goto or return.
return after the break value is removed unnecessary. That was found by running checkpatch.

---
 drivers/staging/rtl8723au/hal/HalPwrSeqCmd.c | 1 -
 1 file changed, 1 deletion(-)
drivers/staging/rtl8723au/hal/HalPwrSeqCmd.c +0 -1
index 33777d2..2dc1856 100644
@@ -148,7 +148,6 @@ u8 HalPwrSeqCmdParsing23a(struct rtw_adapter *padapter, u8 CutVersion,
 					 ("HalPwrSeqCmdParsing23a: "
 					  "PWR_CMD_END\n"));
 				return true;
-				break;
 
 			default:
 				RT_TRACE(_module_hal_init_c_, _drv_err_,
Signature · 1 line
1.8.3.2
#1 lore raw
Quoted 2 lines · Melike Yurtoglu

WARNING: break is not useful after a goto or return.
return after the break value is removed unnecessary. That was found by running checkpatch.

"return after the break value" is confusing, because it is the break that is after the return.

Also, break has no value. It just changes the control flow.

Please check that your commit messages stay within 80 characters.

julia

Quoted 28 lines
---
 drivers/staging/rtl8723au/hal/HalPwrSeqCmd.c | 1 -
 1 file changed, 1 deletion(-)
drivers/staging/rtl8723au/hal/HalPwrSeqCmd.c +0 -1
index 33777d2..2dc1856 100644
@@ -148,7 +148,6 @@ u8 HalPwrSeqCmdParsing23a(struct rtw_adapter *padapter, u8 CutVersion,
 					 ("HalPwrSeqCmdParsing23a: "
 					  "PWR_CMD_END\n"));
 				return true;
-				break;
 
 			default:
 				RT_TRACE(_module_hal_init_c_, _drv_err_,
Signature · 8 lines
1.8.3.2

-- 
You received this message because you are subscribed to the Google Groups "outreachy-kernel" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [email protected].
To post to this group, send email to [email protected].
To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/1424901617-9037-1-git-send-email-aysemelikeyurtoglu%40gmail.com.
For more options, visit https://groups.google.com/d/optout.