diff options
author | Andrew Lunn <andrew@lunn.ch> | 2016-01-06 22:11:10 +0300 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2016-01-07 22:31:25 +0300 |
commit | 84eff6d194df442bee62c129f2f47efb0dbd0468 (patch) | |
tree | dc3c76b19f8e2171416f2f3b42d6bdcbc6da927f /include/linux/phy.h | |
parent | 72ba48be3ec8e70937ad97d4420ef7144617c64b (diff) | |
download | linux-84eff6d194df442bee62c129f2f47efb0dbd0468.tar.xz |
phy: add phydev_name() wrapper
Add a phydev_name() function, to help with moving some structure members
from phy_device.
Signed-off-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/phy.h')
-rw-r--r-- | include/linux/phy.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/include/linux/phy.h b/include/linux/phy.h index dbcf9fdd960c..5f5cc3424b9e 100644 --- a/include/linux/phy.h +++ b/include/linux/phy.h @@ -783,6 +783,11 @@ static inline int phy_read_status(struct phy_device *phydev) #define phydev_dbg(_phydev, format, args...) \ dev_dbg(&_phydev->dev, format, ##args) +static inline const char *phydev_name(const struct phy_device *phydev) +{ + return dev_name(&phydev->dev); +} + int genphy_config_init(struct phy_device *phydev); int genphy_setup_forced(struct phy_device *phydev); int genphy_restart_aneg(struct phy_device *phydev); |