ar8216: Inline function ar8xxx_create_mii
Inline function ar8xxx_create_mii. Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com> SVN-Revision: 43743
This commit is contained in:
parent
2289c7a010
commit
2f9b042d69
1 changed files with 3 additions and 13 deletions
|
@ -2775,18 +2775,6 @@ ar8xxx_free(struct ar8xxx_priv *priv)
|
||||||
kfree(priv);
|
kfree(priv);
|
||||||
}
|
}
|
||||||
|
|
||||||
static struct ar8xxx_priv *
|
|
||||||
ar8xxx_create_mii(struct mii_bus *bus)
|
|
||||||
{
|
|
||||||
struct ar8xxx_priv *priv;
|
|
||||||
|
|
||||||
priv = ar8xxx_create();
|
|
||||||
if (priv)
|
|
||||||
priv->mii_bus = bus;
|
|
||||||
|
|
||||||
return priv;
|
|
||||||
}
|
|
||||||
|
|
||||||
static int
|
static int
|
||||||
ar8xxx_probe_switch(struct ar8xxx_priv *priv)
|
ar8xxx_probe_switch(struct ar8xxx_priv *priv)
|
||||||
{
|
{
|
||||||
|
@ -2990,12 +2978,14 @@ ar8xxx_phy_probe(struct phy_device *phydev)
|
||||||
if (priv->mii_bus == phydev->bus)
|
if (priv->mii_bus == phydev->bus)
|
||||||
goto found;
|
goto found;
|
||||||
|
|
||||||
priv = ar8xxx_create_mii(phydev->bus);
|
priv = ar8xxx_create();
|
||||||
if (priv == NULL) {
|
if (priv == NULL) {
|
||||||
ret = -ENOMEM;
|
ret = -ENOMEM;
|
||||||
goto unlock;
|
goto unlock;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
priv->mii_bus = phydev->bus;
|
||||||
|
|
||||||
ret = ar8xxx_probe_switch(priv);
|
ret = ar8xxx_probe_switch(priv);
|
||||||
if (ret)
|
if (ret)
|
||||||
goto free_priv;
|
goto free_priv;
|
||||||
|
|
Loading…
Reference in a new issue