Lines Matching refs:mdio_bus
197 struct mii_bus *mdio_bus; in sxgbe_mdio_register() local
206 mdio_bus = mdiobus_alloc(); in sxgbe_mdio_register()
207 if (!mdio_bus) { in sxgbe_mdio_register()
218 mdio_bus->name = "sxgbe"; in sxgbe_mdio_register()
219 mdio_bus->read = sxgbe_mdio_read_c22; in sxgbe_mdio_register()
220 mdio_bus->write = sxgbe_mdio_write_c22; in sxgbe_mdio_register()
221 mdio_bus->read_c45 = sxgbe_mdio_read_c45; in sxgbe_mdio_register()
222 mdio_bus->write_c45 = sxgbe_mdio_write_c45; in sxgbe_mdio_register()
223 snprintf(mdio_bus->id, MII_BUS_ID_SIZE, "%s-%x", in sxgbe_mdio_register()
224 mdio_bus->name, priv->plat->bus_id); in sxgbe_mdio_register()
225 mdio_bus->priv = ndev; in sxgbe_mdio_register()
226 mdio_bus->phy_mask = mdio_data->phy_mask; in sxgbe_mdio_register()
227 mdio_bus->parent = priv->device; in sxgbe_mdio_register()
230 err = mdiobus_register(mdio_bus); in sxgbe_mdio_register()
237 struct phy_device *phy = mdiobus_get_phy(mdio_bus, phy_addr); in sxgbe_mdio_register()
283 priv->mii = mdio_bus; in sxgbe_mdio_register()
289 mdiobus_unregister(mdio_bus); in sxgbe_mdio_register()
291 mdiobus_free(mdio_bus); in sxgbe_mdio_register()