diff options
author | Joe Perches <joe@perches.com> | 2012-02-09 06:17:23 -0500 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2012-02-13 00:47:40 -0500 |
commit | 23677ce3172fcb93522a1df077d21019e73ee1e3 (patch) | |
tree | 9558b9c1f24d03d612f4bae999d453ae7ec637d6 /drivers/net/phy | |
parent | 1a0d6ae5795c376bae6d012fb25e8341e4c6d5f2 (diff) |
drivers/net: Remove boolean comparisons to true/false
Booleans should not be compared to true or false
but be directly tested or tested with !.
Done via cocci script:
@@
bool t;
@@
- t == true
+ t
@@
bool t;
@@
- t != true
+ !t
@@
bool t;
@@
- t == false
+ !t
@@
bool t;
@@
- t != false
+ t
Signed-off-by: Joe Perches <joe@perches.com>
Reviewed-by: Jeff Kirsher <jeffrey.t.kirsher@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/phy')
-rw-r--r-- | drivers/net/phy/broadcom.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/net/phy/broadcom.c b/drivers/net/phy/broadcom.c index e8be47d6d7d0..60338ff63092 100644 --- a/drivers/net/phy/broadcom.c +++ b/drivers/net/phy/broadcom.c | |||
@@ -355,8 +355,7 @@ static void bcm54xx_adjust_rxrefclk(struct phy_device *phydev) | |||
355 | } | 355 | } |
356 | } | 356 | } |
357 | 357 | ||
358 | if (clk125en == false || | 358 | if (!clk125en || (phydev->dev_flags & PHY_BRCM_AUTO_PWRDWN_ENABLE)) |
359 | (phydev->dev_flags & PHY_BRCM_AUTO_PWRDWN_ENABLE)) | ||
360 | val &= ~BCM54XX_SHD_SCR3_DLLAPD_DIS; | 359 | val &= ~BCM54XX_SHD_SCR3_DLLAPD_DIS; |
361 | else | 360 | else |
362 | val |= BCM54XX_SHD_SCR3_DLLAPD_DIS; | 361 | val |= BCM54XX_SHD_SCR3_DLLAPD_DIS; |
@@ -373,8 +372,7 @@ static void bcm54xx_adjust_rxrefclk(struct phy_device *phydev) | |||
373 | 372 | ||
374 | orig = val; | 373 | orig = val; |
375 | 374 | ||
376 | if (clk125en == false || | 375 | if (!clk125en || (phydev->dev_flags & PHY_BRCM_AUTO_PWRDWN_ENABLE)) |
377 | (phydev->dev_flags & PHY_BRCM_AUTO_PWRDWN_ENABLE)) | ||
378 | val |= BCM54XX_SHD_APD_EN; | 376 | val |= BCM54XX_SHD_APD_EN; |
379 | else | 377 | else |
380 | val &= ~BCM54XX_SHD_APD_EN; | 378 | val &= ~BCM54XX_SHD_APD_EN; |