mdio: Abstract device_remove() and device_free()
Make device_free and device_remove operations in the mdio device structure, so the core code does not need to differentiate between phy devices and generic mdio devices. Signed-off-by: Andrew Lunn <andrew@lunn.ch> Reviewed-by: Florian Fainelli <f.fainelli@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
This commit is contained in:

committed by
David S. Miller

parent
a9049e0c51
commit
711fdba37a
@@ -46,6 +46,8 @@ struct mdio_device *mdio_device_create(struct mii_bus *bus, int addr)
|
||||
mdiodev->dev.release = mdio_device_release;
|
||||
mdiodev->dev.parent = &bus->dev;
|
||||
mdiodev->dev.bus = &mdio_bus_type;
|
||||
mdiodev->device_free = mdio_device_free;
|
||||
mdiodev->device_remove = mdio_device_remove;
|
||||
mdiodev->bus = bus;
|
||||
mdiodev->addr = addr;
|
||||
|
||||
|
Reference in New Issue
Block a user