]> Git Repo - linux.git/commitdiff
net: phy: dp83867: move dt parsing to probe
authorGrygorii Strashko <[email protected]>
Wed, 23 Oct 2019 14:48:46 +0000 (17:48 +0300)
committerDavid S. Miller <[email protected]>
Sat, 26 Oct 2019 02:24:47 +0000 (19:24 -0700)
Move DT parsing code to probe dp83867_probe() as it's one time operation.

Signed-off-by: Grygorii Strashko <[email protected]>
Reviewed-by: Andrew Lunn <[email protected]>
Reviewed-by: Florian Fainelli <[email protected]>
Signed-off-by: David S. Miller <[email protected]>
drivers/net/phy/dp83867.c

index cf4455bbf888a79cde9a248ceafc947c4e29459c..5816a06a94395beb693ee47c740989feb036a52a 100644 (file)
@@ -299,7 +299,7 @@ static int dp83867_probe(struct phy_device *phydev)
 
        phydev->priv = dp83867;
 
-       return 0;
+       return dp83867_of_init(phydev);
 }
 
 static int dp83867_config_init(struct phy_device *phydev)
@@ -308,10 +308,6 @@ static int dp83867_config_init(struct phy_device *phydev)
        int ret, val, bs;
        u16 delay;
 
-       ret = dp83867_of_init(phydev);
-       if (ret)
-               return ret;
-
        /* RX_DV/RX_CTRL strapped in mode 1 or mode 2 workaround */
        if (dp83867->rxctrl_strap_quirk)
                phy_clear_bits_mmd(phydev, DP83867_DEVADDR, DP83867_CFG4,
This page took 0.061431 seconds and 4 git commands to generate.