diff options
author | John W. Linville <linville@tuxdriver.com> | 2010-07-22 00:36:06 +0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2010-07-26 23:09:03 +0400 |
commit | 28eb3e5acfddf1e1c8892df9901e4f32f7f537eb (patch) | |
tree | ecfb4513e99fc6b76c765c5c738e27a51d80cdf7 /drivers/net/wireless/rtl818x | |
parent | 8b73fb8e29e9ae0458d36cc0dc25e2717587dfd4 (diff) | |
download | linux-28eb3e5acfddf1e1c8892df9901e4f32f7f537eb.tar.xz |
rtl8180: silence "dubious: x | !y" sparse warning
CHECK drivers/net/wireless/rtl818x/rtl8180_rtl8225.c
drivers/net/wireless/rtl818x/rtl8180_rtl8225.c:53:33: warning: dubious: x | !y
The existing code is clever and works fine, but it's not worth even a
single line of Sparse warning SPAM...
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/rtl818x')
-rw-r--r-- | drivers/net/wireless/rtl818x/rtl8180_rtl8225.c | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/drivers/net/wireless/rtl818x/rtl8180_rtl8225.c b/drivers/net/wireless/rtl818x/rtl8180_rtl8225.c index 4d2be0d9672b..69e4d4745dae 100644 --- a/drivers/net/wireless/rtl818x/rtl8180_rtl8225.c +++ b/drivers/net/wireless/rtl818x/rtl8180_rtl8225.c @@ -50,7 +50,10 @@ static void rtl8225_write(struct ieee80211_hw *dev, u8 addr, u16 data) udelay(10); for (i = 15; i >= 0; i--) { - u16 reg = reg80 | !!(bangdata & (1 << i)); + u16 reg = reg80; + + if (bangdata & (1 << i)) + reg |= 1; if (i & 1) rtl818x_iowrite16(priv, &priv->map->RFPinsOutput, reg); |