linux/drivers/net/mdio
Heiner Kallweit c57da33f63 net: phy: fixed_phy: let fixed_phy_unregister free the phy_device
[ Upstream commit a0f849c1cc ]

fixed_phy_register() creates and registers the phy_device. To be
symmetric, we should not only unregister, but also free the phy_device
in fixed_phy_unregister(). This allows to simplify code in users.

Note wrt of_phy_deregister_fixed_link():
put_device(&phydev->mdio.dev) and phy_device_free(phydev) are identical.

Signed-off-by: Heiner Kallweit <hkallweit1@gmail.com>
Reviewed-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
Link: https://patch.msgid.link/ad8dda9a-10ed-4060-916b-3f13bdbb899d@gmail.com
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Signed-off-by: Sasha Levin <sashal@kernel.org>
History 2025-11-13 15:34:15 -05:00
..
acpi_mdio.c net: mdio: fill in missing MODULE_DESCRIPTION()s 2023-11-01 21:50:57 -07:00
fwnode_mdio.c net: mdiobus: fix an OF node reference leak 2024-12-27 14:02:06 +01:00
Kconfig net: mdio: Introduce a regmap-based mdio driver 2023-06-05 09:56:36 +01:00
Makefile net: mdio: Introduce a regmap-based mdio driver 2023-06-05 09:56:36 +01:00
mdio-aspeed.c net: mdio: fill in missing MODULE_DESCRIPTION()s 2023-11-01 21:50:57 -07:00
mdio-bcm-iproc.c net: mdio: bcm-iproc: Convert to platform remove callback returning void 2023-09-20 10:29:33 +01:00
mdio-bcm-unimac.c net: mdio: mdio-bcm-unimac: Correct rate fallback logic 2025-08-15 12:14:06 +02:00
mdio-bitbang.c net: mdio: fill in missing MODULE_DESCRIPTION()s 2023-11-01 21:50:57 -07:00
mdio-cavium.c net: mdio: cavium: Remove unneeded simicolons 2023-01-17 13:19:05 +01:00
mdio-cavium.h net: mdio: cavium: Separate C22 and C45 transactions 2023-01-13 21:40:53 -08:00
mdio-gpio.c net: mdio-gpio: Use device_is_compatible() 2024-04-08 11:05:09 +01:00
mdio-hisi-femac.c net: mdio: hisi-femac: Convert to platform remove callback returning void 2023-09-20 10:29:33 +01:00
mdio-i2c.c net: mdio: i2c: fix rollball accessors 2023-05-15 10:15:57 +01:00
mdio-ipq4019.c net: mdio-ipq4019: add missing error check 2024-12-05 14:02:32 +01:00
mdio-ipq8064.c net: mdio: ipq8064: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-moxart.c net: mdio: moxart: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-mscc-miim.c net: mdio: mscc-miim: Handle the switch reset 2024-06-21 12:12:42 +01:00
mdio-mux-bcm-iproc.c net: mdio: mux-bcm-iproc: Use alignment helpers and SZ_4K 2024-01-03 16:40:59 -08:00
mdio-mux-bcm6368.c net: mdio: mux-bcm6368: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-mux-gpio.c net: mdio: mux-gpio: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-mux-meson-g12a.c net: mdio: mux-meson-g12a: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-mux-meson-gxl.c net: mdio: mux-meson-gxl: set reversed bit when using internal phy 2025-05-09 09:50:43 +02:00
mdio-mux-mmioreg.c net: mdio: mux-mmioreg: Simplified with dev_err_probe() 2024-09-03 12:54:43 +02:00
mdio-mux-multiplexer.c net: mdio: mux-multiplexer: Convert to platform remove callback returning void 2023-09-20 10:29:34 +01:00
mdio-mux.c net: mdio-mux: be compatible with parent buses which only support C45 2023-12-14 18:55:38 -08:00
mdio-mvusb.c net: mdio: mvusb: Fix an error handling path in mvusb_mdio_probe() 2023-05-07 14:59:02 +01:00
mdio-octeon.c net: mdio: octeon: Convert to platform remove callback returning void 2023-09-20 10:29:35 +01:00
mdio-regmap.c net: mdio: Introduce a regmap-based mdio driver 2023-06-05 09:56:36 +01:00
mdio-sun4i.c net: mdio: sun4i: Convert to platform remove callback returning void 2023-09-20 10:29:35 +01:00
mdio-thunder.c net: mdio: thunder: Add missing fwnode_handle_put() 2023-03-23 08:46:55 +00:00
mdio-xgene.c net: mdio: xgene: Fix unused xgene_mdio_of_match warning for !CONFIG_OF 2023-10-23 10:16:47 -07:00
of_mdio.c net: phy: fixed_phy: let fixed_phy_unregister free the phy_device 2025-11-13 15:34:15 -05:00