Skip to content

Commit ecc11b4

Browse files
simransinghalgregkh
authored andcommitted
staging: rtl8723bs: hal: Compress return logic
Simplify function returns by merging assignment and return into one command line. Found with Coccinelle @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Simran Singhal <[email protected]> Link: https://lore.kernel.org/r/20200325214312.GA1936@simran-Inspiron-5558 Signed-off-by: Greg Kroah-Hartman <[email protected]>
1 parent 1b590af commit ecc11b4

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

drivers/staging/rtl8723bs/hal/hal_com_phycfg.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1498,9 +1498,7 @@ s8 PHY_GetTxPowerByRate(
14981498
return value;
14991499
}
15001500

1501-
value = pHalData->TxPwrByRateOffset[Band][RFPath][TxNum][rateIndex];
1502-
1503-
return value;
1501+
return pHalData->TxPwrByRateOffset[Band][RFPath][TxNum][rateIndex];
15041502

15051503
}
15061504

0 commit comments

Comments
 (0)