Lines Matching refs:phy
22 struct rt_phy_device *phy = (struct rt_phy_device *)dev->user_data; in phy_device_read() local
24 return phy->bus->ops->read(phy->bus, phy->addr, msg->reg, &(msg->value), 4); in phy_device_read()
28 struct rt_phy_device *phy = (struct rt_phy_device *)dev->user_data; in phy_device_write() local
30 return phy->bus->ops->write(phy->bus, phy->addr, msg->reg, &(msg->value), 4); in phy_device_write()
48 rt_err_t rt_hw_phy_register(struct rt_phy_device *phy, const char *name) in rt_hw_phy_register() argument
53 device = &(phy->parent); in rt_hw_phy_register()
69 device->user_data = phy; in rt_hw_phy_register()
398 struct rt_phy_device *phy; in rt_phydev_create_by_mask() local
418 phy = create_phy_by_mask(bus, phy_mask, devad[i]); in rt_phydev_create_by_mask()
419 if(phy) in rt_phydev_create_by_mask()
420 return phy; in rt_phydev_create_by_mask()
428 struct rt_phy_device *phy; in rt_phy_find_by_mask() local
455 phy = rt_phydev_create_by_mask(bus, phy_mask); in rt_phy_find_by_mask()
457 return phy; in rt_phy_find_by_mask()
472 struct rt_phy_device *phy = RT_NULL; in rt_phy_get_device() local
477 phy = rt_ofw_create_phy(bus,np,addr); in rt_phy_get_device()
479 if(!phy) in rt_phy_get_device()
480 phy = rt_phy_find_by_mask(bus,phy_mask); in rt_phy_get_device()
482 if(phy) in rt_phy_get_device()
484 rt_phy_reset(phy); in rt_phy_get_device()
485 phy->interface = interface; in rt_phy_get_device()
486 return phy; in rt_phy_get_device()