net: wireless: brcmsmac: Remove unnecessary parentheses
PATCH 1/1 net: wireless: brcmsmac: Remove unnecessary parentheses
This patch fixes the clang warning of extraneous parentheses, with the following coccinelle script.
@@
identifier i;
expression e;
statement s;
@@
if (
-(i == e)
+i == e
)
s
Suggested-by Lukas Bulwahn <[email protected]>
Signed-off-by Varsha Rao <[email protected]>
--- drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_cmn.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/broadcom/brcm80211/brcmsmac/phy/phy_cmn.c +1 -1
@@ -159,7 +159,7 @@ u16 read_radio_reg(struct brcms_phy *pi, u16 addr) {u16 data; -if ((addr ==RADIO_IDCODE )) +if (addr ==RADIO_IDCODE )return 0xffff ;switch (pi->pubpi.phy_type) {
Signature · 1 line
2.17.0
Re: brcmsmac: Remove unnecessary parentheses
Quoted 14 lines · Varsha Rao
This patch fixes the clang warning of extraneous parentheses, with the following coccinelle script.
@@
identifier i;
expression e;
statement s;
@@
if ((quoted diff) +1
-1-(i == e) +i == e )s
Quoted 2 lines
Suggested-by Lukas Bulwahn <[email protected]>Signed-off-by Varsha Rao <[email protected]>
Patch applied to wireless-drivers-next.git, thanks.
eb5d2f3afc0f brcmsmac: Remove unnecessary parentheses
Signature · 3 lines
https://patchwork.kernel.org/patch/10442401/ https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches