diff mbox series

b43: remove Comparison of 0/1 to bool variable in phy_n.c

Message ID 20200504113300.40895-1-yanaijie@huawei.com (mailing list archive)
State Accepted
Commit e2b9ac59081028d48ec7aa9a3510981eda94c327
Delegated to: Kalle Valo
Headers show
Series b43: remove Comparison of 0/1 to bool variable in phy_n.c | expand

Commit Message

Jason Yan May 4, 2020, 11:33 a.m. UTC
Fix the following coccicheck warning:

drivers/net/wireless/broadcom/b43/phy_n.c:5510:19-32: WARNING:
Comparison of 0/1 to bool variable

Signed-off-by: Jason Yan <yanaijie@huawei.com>
---
 drivers/net/wireless/broadcom/b43/phy_n.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Kalle Valo May 6, 2020, 8:45 a.m. UTC | #1
Jason Yan <yanaijie@huawei.com> wrote:

> Fix the following coccicheck warning:
> 
> drivers/net/wireless/broadcom/b43/phy_n.c:5510:19-32: WARNING:
> Comparison of 0/1 to bool variable
> 
> Signed-off-by: Jason Yan <yanaijie@huawei.com>

Patch applied to wireless-drivers-next.git, thanks.

e2b9ac590810 b43: remove Comparison of 0/1 to bool variable in phy_n.c
diff mbox series

Patch

diff --git a/drivers/net/wireless/broadcom/b43/phy_n.c b/drivers/net/wireless/broadcom/b43/phy_n.c
index d3c001fa8eb4..c33b4235839d 100644
--- a/drivers/net/wireless/broadcom/b43/phy_n.c
+++ b/drivers/net/wireless/broadcom/b43/phy_n.c
@@ -5507,7 +5507,7 @@  static int b43_nphy_cal_tx_iq_lo(struct b43_wldev *dev,
 			core = (cmd & 0x3000) >> 12;
 			type = (cmd & 0x0F00) >> 8;
 
-			if (phy6or5x && updated[core] == 0) {
+			if (phy6or5x && !updated[core]) {
 				b43_nphy_update_tx_cal_ladder(dev, core);
 				updated[core] = true;
 			}