diff options
author | Tobias Klauser <tklauser@distanz.ch> | 2015-09-09 11:24:29 +0200 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2015-09-09 23:16:05 +0200 |
commit | 444c5f92ed152346aef0952316e0ea855129846c (patch) | |
tree | 09da0659252945169257a0b7ed986142a64ae06a /drivers/net/ethernet | |
parent | net: dsa: bcm_sf2: Fix 64-bits register writes (diff) | |
download | linux-444c5f92ed152346aef0952316e0ea855129846c.tar.xz linux-444c5f92ed152346aef0952316e0ea855129846c.zip |
net: ethoc: Remove unnecessary #ifdef CONFIG_OF
For !CONFIG_OF of_get_property() is defined to always return NULL. Thus
there's no need to protect the call to of_get_property() with #ifdef
CONFIG_OF.
Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net/ethernet')
-rw-r--r-- | drivers/net/ethernet/ethoc.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/drivers/net/ethernet/ethoc.c b/drivers/net/ethernet/ethoc.c index 442410cd2ca4..a2c96fd88393 100644 --- a/drivers/net/ethernet/ethoc.c +++ b/drivers/net/ethernet/ethoc.c @@ -1132,10 +1132,6 @@ static int ethoc_probe(struct platform_device *pdev) memcpy(netdev->dev_addr, pdata->hwaddr, IFHWADDRLEN); priv->phy_id = pdata->phy_id; } else { - priv->phy_id = -1; - -#ifdef CONFIG_OF - { const uint8_t *mac; mac = of_get_property(pdev->dev.of_node, @@ -1143,8 +1139,7 @@ static int ethoc_probe(struct platform_device *pdev) NULL); if (mac) memcpy(netdev->dev_addr, mac, IFHWADDRLEN); - } -#endif + priv->phy_id = -1; } /* Check that the given MAC address is valid. If it isn't, read the |