net/wireless/brcm80211/brcmfmac: Make return type and name reflect actual semantics
authorRasmus Villemoes <linux@rasmusvillemoes.dk>
Sun, 22 Jun 2014 18:50:40 +0000 (20:50 +0200)
committerJohn W. Linville <linville@tuxdriver.com>
Wed, 25 Jun 2014 19:32:47 +0000 (15:32 -0400)
commite843bb199ba58ce5d1364d4c82fcf6975f08eec2
treef40052d5af78b985f7c19ebff2a7ea9b99d85b8b
parent363c1b4f75d7a8cec61b74ee163f1f315a56f639
net/wireless/brcm80211/brcmfmac: Make return type and name reflect actual semantics

Applying ++ to a bool is equivalent to setting it true, regardless of
its initial value (bools are not uint1_t). Hence the function
wl_get_vif_state_all can only ever return true/false. The only in-tree
caller uses its return value as a boolean. So update its return type,
and since the list traversal and bit testing have no side effects,
just return true immediately. Its return value tells if any vif is in
the specified state, so also rename it to brcmf_get_vif_state_any.

Reviewed-by: Arend van Spriel<arend@broadcom.com>
Signed-off-by: Rasmus Villemoes <linux@rasmusvillemoes.dk>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
drivers/net/wireless/brcm80211/brcmfmac/p2p.c
drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.c
drivers/net/wireless/brcm80211/brcmfmac/wl_cfg80211.h