linux-wireless.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v2 3/5] batman: use BIT_ULL for NL80211_STA_INFO_* attribute types
@ 2018-06-14 10:12 Omer Efrat
  2018-06-14 10:40 ` Sven Eckelmann
  0 siblings, 1 reply; 6+ messages in thread
From: Omer Efrat @ 2018-06-14 10:12 UTC (permalink / raw)
  To: linux-wireless; +Cc: netdev, b.a.t.m.a.n, Omer Efrat

Since 'filled' member in station_info changed to u64, BIT_ULL macro
should be used with NL80211_STA_INFO_* attribute types instead of BIT.

The BIT macro uses unsigned long type which some architectures handle as 32bit
and this results in compilation warnings such as:

net/mac80211/sta_info.c:2223:2: warning: left shift count >= width of type
  sinfo->filled |= BIT(NL80211_STA_INFO_TID_STATS);
  ^

Signed-off-by: Omer Efrat <omer.efrat@tandemg.com>
---
 net/batman-adv/bat_v_elp.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/net/batman-adv/bat_v_elp.c b/net/batman-adv/bat_v_elp.c
index 71c20c1..71e6474 100644
--- a/net/batman-adv/bat_v_elp.c
+++ b/net/batman-adv/bat_v_elp.c
@@ -114,7 +114,7 @@ static u32 batadv_v_elp_get_throughput(struct batadv_hardif_neigh_node *neigh)
 		}
 		if (ret)
 			goto default_throughput;
-		if (!(sinfo.filled & BIT(NL80211_STA_INFO_EXPECTED_THROUGHPUT)))
+		if (!(sinfo.filled & BIT_ULL(NL80211_STA_INFO_EXPECTED_THROUGHPUT)))
 			goto default_throughput;
 
 		return sinfo.expected_throughput / 100;
-- 
2.7.4

^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2018-06-14 12:50 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-06-14 10:12 [PATCH v2 3/5] batman: use BIT_ULL for NL80211_STA_INFO_* attribute types Omer Efrat
2018-06-14 10:40 ` Sven Eckelmann
2018-06-14 10:53   ` [B.A.T.M.A.N.] " Sven Eckelmann
2018-06-14 11:05     ` Johannes Berg
2018-06-14 11:20       ` Sven Eckelmann
2018-06-14 12:50         ` Omer Efrat

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).