* [PATCH] wireless: ipw2x00: Remove unnecessary parentheses
@ 2018-09-20 20:45 Nathan Chancellor
2018-09-24 18:21 ` Stanislav Yakovlev
2018-10-01 15:30 ` [PATCH] " Kalle Valo
0 siblings, 2 replies; 3+ messages in thread
From: Nathan Chancellor @ 2018-09-20 20:45 UTC (permalink / raw)
To: Stanislav Yakovlev, Kalle Valo
Cc: linux-wireless, netdev, linux-kernel, Nathan Chancellor
Clang warns when multiple pairs of parentheses are used for a single
conditional statement.
drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: warning: equality
comparison with extraneous parentheses [-Wparentheses-equality]
if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: remove
extraneous parentheses around the comparison to silence this warning
if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
~ ^ ~
drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: use '=' to
turn this equality comparison into an assignment
if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
^~
=
1 warning generated.
Link: https://github.com/ClangBuiltLinux/linux/issues/134
Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
---
drivers/net/wireless/intel/ipw2x00/ipw2200.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/net/wireless/intel/ipw2x00/ipw2200.c b/drivers/net/wireless/intel/ipw2x00/ipw2200.c
index 9644e7b93645..bbdca13c5a9f 100644
--- a/drivers/net/wireless/intel/ipw2x00/ipw2200.c
+++ b/drivers/net/wireless/intel/ipw2x00/ipw2200.c
@@ -5652,7 +5652,7 @@ static void ipw_merge_adhoc_network(struct work_struct *work)
}
mutex_lock(&priv->mutex);
- if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
+ if (priv->ieee->iw_mode == IW_MODE_ADHOC) {
IPW_DEBUG_MERGE("remove network %*pE\n",
priv->essid_len, priv->essid);
ipw_remove_current_network(priv);
--
2.19.0
^ permalink raw reply related [flat|nested] 3+ messages in thread
* Re: [PATCH] wireless: ipw2x00: Remove unnecessary parentheses
2018-09-20 20:45 [PATCH] wireless: ipw2x00: Remove unnecessary parentheses Nathan Chancellor
@ 2018-09-24 18:21 ` Stanislav Yakovlev
2018-10-01 15:30 ` [PATCH] " Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Stanislav Yakovlev @ 2018-09-24 18:21 UTC (permalink / raw)
To: Nathan Chancellor; +Cc: Kalle Valo, linux-wireless, netdev, linux-kernel
On 21/09/2018, Nathan Chancellor <natechancellor@gmail.com> wrote:
> Clang warns when multiple pairs of parentheses are used for a single
> conditional statement.
>
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: warning: equality
> comparison with extraneous parentheses [-Wparentheses-equality]
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: remove
> extraneous parentheses around the comparison to silence this warning
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ~ ^ ~
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: use '=' to
> turn this equality comparison into an assignment
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ^~
> =
> 1 warning generated.
>
> Link: https://github.com/ClangBuiltLinux/linux/issues/134
> Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
> ---
> drivers/net/wireless/intel/ipw2x00/ipw2200.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
Looks fine, thanks!
Stanislav.
^ permalink raw reply [flat|nested] 3+ messages in thread
* Re: [PATCH] ipw2x00: Remove unnecessary parentheses
2018-09-20 20:45 [PATCH] wireless: ipw2x00: Remove unnecessary parentheses Nathan Chancellor
2018-09-24 18:21 ` Stanislav Yakovlev
@ 2018-10-01 15:30 ` Kalle Valo
1 sibling, 0 replies; 3+ messages in thread
From: Kalle Valo @ 2018-10-01 15:30 UTC (permalink / raw)
To: Nathan Chancellor
Cc: Stanislav Yakovlev, linux-wireless, netdev, linux-kernel,
Nathan Chancellor
Nathan Chancellor <natechancellor@gmail.com> wrote:
> Clang warns when multiple pairs of parentheses are used for a single
> conditional statement.
>
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: warning: equality
> comparison with extraneous parentheses [-Wparentheses-equality]
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ~~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: remove
> extraneous parentheses around the comparison to silence this warning
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ~ ^ ~
> drivers/net/wireless/intel/ipw2x00/ipw2200.c:5655:28: note: use '=' to
> turn this equality comparison into an assignment
> if ((priv->ieee->iw_mode == IW_MODE_ADHOC)) {
> ^~
> =
> 1 warning generated.
>
> Link: https://github.com/ClangBuiltLinux/linux/issues/134
> Signed-off-by: Nathan Chancellor <natechancellor@gmail.com>
Patch applied to wireless-drivers-next.git, thanks.
c15ace868dd1 ipw2x00: Remove unnecessary parentheses
--
https://patchwork.kernel.org/patch/10608735/
https://wireless.wiki.kernel.org/en/developers/documentation/submittingpatches
^ permalink raw reply [flat|nested] 3+ messages in thread
end of thread, other threads:[~2018-10-01 15:30 UTC | newest]
Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-09-20 20:45 [PATCH] wireless: ipw2x00: Remove unnecessary parentheses Nathan Chancellor
2018-09-24 18:21 ` Stanislav Yakovlev
2018-10-01 15:30 ` [PATCH] " Kalle Valo
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.