* [patch] rndis_wlan: harmless issue calling set_bit()
@ 2015-05-14 8:37 Dan Carpenter
2015-05-26 10:55 ` Kalle Valo
0 siblings, 1 reply; 2+ messages in thread
From: Dan Carpenter @ 2015-05-14 8:37 UTC (permalink / raw)
To: Jussi Kivilinna; +Cc: Kalle Valo, linux-wireless, kernel-janitors, Joe Perches
These are used like:
set_bit(WORK_LINK_UP, &priv->work_pending);
The problem is that set_bit() takes the actual bit number and not a mask
so static checkers get upset. It doesn't affect run time because we do
it consistently, but we may as well clean it up.
Fixes: 6010ce07a66c ('rndis_wlan: do link-down state change in worker thread')
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
diff --git a/drivers/net/wireless/rndis_wlan.c b/drivers/net/wireless/rndis_wlan.c
index d72ff8e..96175a7 100644
--- a/drivers/net/wireless/rndis_wlan.c
+++ b/drivers/net/wireless/rndis_wlan.c
@@ -356,9 +356,9 @@ struct ndis_80211_pmkid {
#define CAP_MODE_80211G 4
#define CAP_MODE_MASK 7
-#define WORK_LINK_UP (1<<0)
-#define WORK_LINK_DOWN (1<<1)
-#define WORK_SET_MULTICAST_LIST (1<<2)
+#define WORK_LINK_UP 0
+#define WORK_LINK_DOWN 1
+#define WORK_SET_MULTICAST_LIST 2
#define RNDIS_WLAN_ALG_NONE 0
#define RNDIS_WLAN_ALG_WEP (1<<0)
^ permalink raw reply related [flat|nested] 2+ messages in thread
* Re: rndis_wlan: harmless issue calling set_bit()
2015-05-14 8:37 [patch] rndis_wlan: harmless issue calling set_bit() Dan Carpenter
@ 2015-05-26 10:55 ` Kalle Valo
0 siblings, 0 replies; 2+ messages in thread
From: Kalle Valo @ 2015-05-26 10:55 UTC (permalink / raw)
To: Dan Carpenter
Cc: Jussi Kivilinna, linux-wireless, kernel-janitors, Joe Perches
> These are used like:
>
> set_bit(WORK_LINK_UP, &priv->work_pending);
>
> The problem is that set_bit() takes the actual bit number and not a mask
> so static checkers get upset. It doesn't affect run time because we do
> it consistently, but we may as well clean it up.
>
> Fixes: 6010ce07a66c ('rndis_wlan: do link-down state change in worker thread')
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Thanks, applied to wireless-drivers-next.git.
Kalle Valo
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2015-05-26 13:22 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-05-14 8:37 [patch] rndis_wlan: harmless issue calling set_bit() Dan Carpenter
2015-05-26 10:55 ` Kalle Valo
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).