Lines Matching refs:phy_addr
57 static int fixed_mdio_read(struct mii_bus *bus, int phy_addr, int reg_num) in fixed_mdio_read() argument
63 if (fp->addr == phy_addr) { in fixed_mdio_read()
85 static int fixed_mdio_write(struct mii_bus *bus, int phy_addr, int reg_num, in fixed_mdio_write() argument
149 int fixed_phy_add(unsigned int irq, int phy_addr, in fixed_phy_add() argument
168 fmb->mii_bus->irq[phy_addr] = irq; in fixed_phy_add()
170 fp->addr = phy_addr; in fixed_phy_add()
195 static void fixed_phy_del(int phy_addr) in fixed_phy_del() argument
201 if (fp->addr == phy_addr) { in fixed_phy_del()
206 ida_simple_remove(&phy_fixed_ida, phy_addr); in fixed_phy_del()
219 int phy_addr; in fixed_phy_register() local
226 phy_addr = ida_simple_get(&phy_fixed_ida, 0, PHY_MAX_ADDR, GFP_KERNEL); in fixed_phy_register()
227 if (phy_addr < 0) in fixed_phy_register()
228 return ERR_PTR(phy_addr); in fixed_phy_register()
230 ret = fixed_phy_add(irq, phy_addr, status, link_gpio); in fixed_phy_register()
232 ida_simple_remove(&phy_fixed_ida, phy_addr); in fixed_phy_register()
236 phy = get_phy_device(fmb->mii_bus, phy_addr, false); in fixed_phy_register()
238 fixed_phy_del(phy_addr); in fixed_phy_register()
271 fixed_phy_del(phy_addr); in fixed_phy_register()