[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1583844684-28202-2-git-send-email-claudiu.manoil@nxp.com>
Date: Tue, 10 Mar 2020 14:51:21 +0200
From: Claudiu Manoil <claudiu.manoil@....com>
To: netdev@...r.kernel.org
Cc: Vladimir Oltean <vladimir.oltean@....com>,
"Y . b . Lu" <yangbo.lu@....com>,
"David S . Miller" <davem@...emloft.net>
Subject: [PATCH net-next 1/4] enetc: Drop redundant device node check
The existence of the DT port node is the first thing checked
at probe time, and probing won't reach this point if the node
is missing.
Signed-off-by: Claudiu Manoil <claudiu.manoil@....com>
---
drivers/net/ethernet/freescale/enetc/enetc_pf.c | 5 -----
1 file changed, 5 deletions(-)
diff --git a/drivers/net/ethernet/freescale/enetc/enetc_pf.c b/drivers/net/ethernet/freescale/enetc/enetc_pf.c
index 545a344bce00..4e4a49179f0b 100644
--- a/drivers/net/ethernet/freescale/enetc/enetc_pf.c
+++ b/drivers/net/ethernet/freescale/enetc/enetc_pf.c
@@ -797,11 +797,6 @@ static int enetc_of_get_phy(struct enetc_ndev_priv *priv)
struct device_node *mdio_np;
int err;
- if (!np) {
- dev_err(priv->dev, "missing ENETC port node\n");
- return -ENODEV;
- }
-
priv->phy_node = of_parse_phandle(np, "phy-handle", 0);
if (!priv->phy_node) {
if (!of_phy_is_fixed_link(np)) {
--
2.17.1
Powered by blists - more mailing lists