staging: r8188eu: Remove unnecessary parentheses
authorNathan Chancellor <nathan@kernel.org>
Thu, 5 Aug 2021 18:58:05 +0000 (11:58 -0700)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Thu, 5 Aug 2021 19:12:40 +0000 (21:12 +0200)
commit717d933d003c88668cbfab145d02c86ff3cf8756
tree44009c6fe7c31271a0df46a76be70b2a2f931739
parentd48401b8609ff19db0f461759ac6b5210cd81288
staging: r8188eu: Remove unnecessary parentheses

Clang warns several times across the driver along the lines of:

drivers/staging/r8188eu/core/rtw_pwrctrl.c:222:21: warning: equality
comparison with extraneous parentheses [-Wparentheses-equality]
        if ((pwrpriv->rpwm == pslv)) {
             ~~~~~~~~~~~~~~^~~~~~~
drivers/staging/r8188eu/core/rtw_pwrctrl.c:222:21: note: remove
extraneous parentheses around the comparison to silence this warning
        if ((pwrpriv->rpwm == pslv)) {
            ~              ^      ~
drivers/staging/r8188eu/core/rtw_pwrctrl.c:222:21: note: use '=' to turn
this equality comparison into an assignment
        if ((pwrpriv->rpwm == pslv)) {
                           ^~
                           =
1 warning generated.

The compilers have agreed that single parentheses are used for equality
and double parentheses are used for assignment within control flow
statements such as if and while so remove them in these places to fix
the warning.

Reviewed-by: Nick Desaulniers <ndesaulniers@google.com>
Signed-off-by: Nathan Chancellor <nathan@kernel.org>
Link: https://lore.kernel.org/r/20210805185807.3296077-2-nathan@kernel.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
drivers/staging/r8188eu/core/rtw_pwrctrl.c
drivers/staging/r8188eu/core/rtw_security.c
drivers/staging/r8188eu/core/rtw_wlan_util.c
drivers/staging/r8188eu/hal/odm.c
drivers/staging/r8188eu/hal/usb_halinit.c