Commit 67aa461c authored by Sergei Shtylyov's avatar Sergei Shtylyov Committed by Luis Henriques

xgene: get_phy_device() doesn't return NULL anymore

BugLink: https://launchpad.net/bugs/1632739

Now that get_phy_device() no longer returns NULL on error, we don't need
to check for it...
Signed-off-by: default avatarSergei Shtylyov <sergei.shtylyov@cogentembedded.com>
Reviewed-by: default avatarFlorian Fainelli <f.fainelli@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
(cherry picked from commit fb1116ab yakkety)
Signed-off-by: default avatarCraig Magina <craig.magina@canonical.com>
Acked-by: default avatarTim Gardner <tim.gardner@canonical.com>
Acked-by: default avatarSeth Forshee <seth.forshee@canonical.com>
Signed-off-by: default avatarSeth Forshee <seth.forshee@canonical.com>
parent ea22f6dd
......@@ -824,7 +824,7 @@ static int xgene_mdiobus_register(struct xgene_enet_pdata *pdata,
return -EINVAL;
phy = get_phy_device(mdio, phy_id, false);
if (!phy || IS_ERR(phy))
if (IS_ERR(phy))
return -EIO;
ret = phy_device_register(phy);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment