Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1581175

[PATCH v3 1/8] net: stmmac: remove useless parenthesis

From Corentin Labbe <clabbe.montjoie@gmail.com>
Newsgroups linux.kernel
Subject [PATCH v3 1/8] net: stmmac: remove useless parenthesis
Date 2017-02-15 11:00 +0100
Message-ID <tb4xs-6HC-23@gated-at.bofh.it> (permalink)
References <tb4xs-6HC-5@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


This patch remove some useless parenthesis.

Signed-off-by: Corentin Labbe <clabbe.montjoie@gmail.com>
Acked-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
Reviewed-by: Giuseppe Cavallaro <peppe.cavallaro@st.com>
---
 drivers/net/ethernet/stmicro/stmmac/stmmac_main.c | 8 ++++----
 drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c | 2 +-
 2 files changed, 5 insertions(+), 5 deletions(-)

diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
index 7251871..ee1dbf4 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_main.c
@@ -716,15 +716,15 @@ static void stmmac_adjust_link(struct net_device *dev)
 			new_state = 1;
 			switch (phydev->speed) {
 			case 1000:
-				if (likely((priv->plat->has_gmac) ||
-					   (priv->plat->has_gmac4)))
+				if (likely(priv->plat->has_gmac ||
+					   priv->plat->has_gmac4))
 					ctrl &= ~priv->hw->link.port;
 				stmmac_hw_fix_mac_speed(priv);
 				break;
 			case 100:
 			case 10:
-				if (likely((priv->plat->has_gmac) ||
-					   (priv->plat->has_gmac4))) {
+				if (likely(priv->plat->has_gmac ||
+					   priv->plat->has_gmac4)) {
 					ctrl |= priv->hw->link.port;
 					if (phydev->speed == SPEED_100) {
 						ctrl |= priv->hw->link.speed;
diff --git a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
index d9893cf..a695773 100644
--- a/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
+++ b/drivers/net/ethernet/stmicro/stmmac/stmmac_mdio.c
@@ -257,7 +257,7 @@ int stmmac_mdio_register(struct net_device *ndev)
 			 * If an IRQ was provided to be assigned after
 			 * the bus probe, do it here.
 			 */
-			if ((!mdio_bus_data->irqs) &&
+			if (!mdio_bus_data->irqs &&
 			    (mdio_bus_data->probed_phy_irq > 0)) {
 				new_bus->irq[addr] =
 					mdio_bus_data->probed_phy_irq;
-- 
2.10.2

Back to linux.kernel | Previous | NextPrevious in thread | Next in thread | Find similar | Unroll thread


Thread

[PATCH v3 0/8] misc patchs Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-15 11:00 +0100
  [PATCH v3 1/8] net: stmmac: remove useless parenthesis Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-15 11:00 +0100
  [PATCH v3 3/8] net: stmmac: use SPEED_UNKNOWN/DUPLEX_UNKNOWN Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-15 11:00 +0100
  [PATCH v3 5/8] net: stmmac: run stmmac_hw_fix_mac_speed when speed is valid Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-15 11:00 +0100
  [PATCH v3 7/8] net: stmmac: reduce indentation by adding a continue Corentin Labbe <clabbe.montjoie@gmail.com> - 2017-02-15 11:00 +0100
  Re: [PATCH v3 0/8] misc patchs David Miller <davem@davemloft.net> - 2017-02-15 19:30 +0100

csiph-web