From: Madalin Bucur Date: Wed, 26 Aug 2015 14:58:47 +0000 (+0300) Subject: net: phy: fixed: propagate fixed link values to struct X-Git-Tag: next-20150828~140^2~2 X-Git-Url: http://git.osdn.net/view?p=uclinux-h8%2Flinux.git;a=commitdiff_plain;h=4b195360914583899070835a08ceb06ac7b848d6 net: phy: fixed: propagate fixed link values to struct The fixed link values parsed from the device tree are stored in the struct fixed_phy member status. The struct phy_device members speed, duplex were not updated. Signed-off-by: Madalin Bucur Reviewed-by: Florian Fainelli Signed-off-by: David S. Miller --- diff --git a/drivers/net/phy/fixed_phy.c b/drivers/net/phy/fixed_phy.c index 1960b46add65..d7a65247f952 100644 --- a/drivers/net/phy/fixed_phy.c +++ b/drivers/net/phy/fixed_phy.c @@ -290,6 +290,15 @@ struct phy_device *fixed_phy_register(unsigned int irq, return ERR_PTR(-EINVAL); } + /* propagate the fixed link values to struct phy_device */ + phy->link = status->link; + if (status->link) { + phy->speed = status->speed; + phy->duplex = status->duplex; + phy->pause = status->pause; + phy->asym_pause = status->asym_pause; + } + of_node_get(np); phy->dev.of_node = np;