diff options
author | Oleksij Rempel <o.rempel@pengutronix.de> | 2022-10-03 09:51:59 +0300 |
---|---|---|
committer | Jakub Kicinski <kuba@kernel.org> | 2022-10-04 03:33:57 +0300 |
commit | 5e82147de1cbd758bb280908daa39d95ed467538 (patch) | |
tree | ef736552209fe3f6d34b180cde829cb921161f63 /drivers/net/phy | |
parent | cfaa202a73eafaf91a3d0a86b5e5df006562f5c0 (diff) | |
download | linux-5e82147de1cbd758bb280908daa39d95ed467538.tar.xz |
net: mdiobus: search for PSE nodes by parsing PHY nodes.
Some PHYs can be linked with PSE (Power Sourcing Equipment), so search
for related nodes and attach it to the phydev.
Signed-off-by: Oleksij Rempel <o.rempel@pengutronix.de>
Reviewed-by: Andrew Lunn <andrew@lunn.ch>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Diffstat (limited to 'drivers/net/phy')
-rw-r--r-- | drivers/net/phy/phy_device.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/drivers/net/phy/phy_device.c b/drivers/net/phy/phy_device.c index a4f5f151014a..57849ac0384e 100644 --- a/drivers/net/phy/phy_device.c +++ b/drivers/net/phy/phy_device.c @@ -26,6 +26,7 @@ #include <linux/netdevice.h> #include <linux/phy.h> #include <linux/phy_led_triggers.h> +#include <linux/pse-pd/pse.h> #include <linux/property.h> #include <linux/sfp.h> #include <linux/skbuff.h> @@ -991,6 +992,7 @@ EXPORT_SYMBOL(phy_device_register); void phy_device_remove(struct phy_device *phydev) { unregister_mii_timestamper(phydev->mii_ts); + pse_control_put(phydev->psec); device_del(&phydev->mdio.dev); |