diff options
author | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 13:34:54 -0800 |
---|---|---|
committer | Greg Kroah-Hartman <gregkh@linuxfoundation.org> | 2014-02-24 13:34:54 -0800 |
commit | 58e868be77bda526cc8d4264488ed393bc607720 (patch) | |
tree | f95692355ca78239815c1df58fe2fee7dc79d80d /drivers/phy/phy-core.c | |
parent | d91f9ecfd147bbb2d3089b2e2a603087c668db82 (diff) | |
parent | cfbf8d4857c26a8a307fb7cd258074c9dcd8c691 (diff) | |
download | linux-58e868be77bda526cc8d4264488ed393bc607720.tar.gz linux-58e868be77bda526cc8d4264488ed393bc607720.tar.bz2 linux-58e868be77bda526cc8d4264488ed393bc607720.zip |
Merge 3.14-rc4 into char-misc-linus
Merge this to catch up with the other patches sent upstream.
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'drivers/phy/phy-core.c')
-rw-r--r-- | drivers/phy/phy-core.c | 14 |
1 files changed, 6 insertions, 8 deletions
diff --git a/drivers/phy/phy-core.c b/drivers/phy/phy-core.c index 5f5b0f4be5be..6c738376daff 100644 --- a/drivers/phy/phy-core.c +++ b/drivers/phy/phy-core.c @@ -176,6 +176,8 @@ int phy_init(struct phy *phy) dev_err(&phy->dev, "phy init failed --> %d\n", ret); goto out; } + } else { + ret = 0; /* Override possible ret == -ENOTSUPP */ } ++phy->init_count; @@ -232,6 +234,8 @@ int phy_power_on(struct phy *phy) dev_err(&phy->dev, "phy poweron failed --> %d\n", ret); goto out; } + } else { + ret = 0; /* Override possible ret == -ENOTSUPP */ } ++phy->power_count; mutex_unlock(&phy->mutex); @@ -404,17 +408,11 @@ struct phy *phy_get(struct device *dev, const char *string) index = of_property_match_string(dev->of_node, "phy-names", string); phy = of_phy_get(dev, index); - if (IS_ERR(phy)) { - dev_err(dev, "unable to find phy\n"); - return phy; - } } else { phy = phy_lookup(dev, string); - if (IS_ERR(phy)) { - dev_err(dev, "unable to find phy\n"); - return phy; - } } + if (IS_ERR(phy)) + return phy; if (!try_module_get(phy->ops->owner)) return ERR_PTR(-EPROBE_DEFER); |