Lines Matching refs:mii
205 phy_id &= dev->mii.phy_id_mask; in __smsc95xx_mdio_read()
206 idx &= dev->mii.reg_num_mask; in __smsc95xx_mdio_read()
257 phy_id &= dev->mii.phy_id_mask; in __smsc95xx_mdio_write()
258 idx &= dev->mii.reg_num_mask; in __smsc95xx_mdio_write()
566 struct mii_if_info *mii = &dev->mii; in smsc95xx_link_reset() local
573 ret = smsc95xx_mdio_read(dev->net, mii->phy_id, PHY_INT_SRC); in smsc95xx_link_reset()
581 mii_check_media(mii, 1, 1); in smsc95xx_link_reset()
582 mii_ethtool_gset(&dev->mii, &ecmd); in smsc95xx_link_reset()
583 lcladv = smsc95xx_mdio_read(dev->net, mii->phy_id, MII_ADVERTISE); in smsc95xx_link_reset()
584 rmtadv = smsc95xx_mdio_read(dev->net, mii->phy_id, MII_LPA); in smsc95xx_link_reset()
658 ret = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, MII_BMSR); in check_carrier()
795 buf = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, SPECIAL_CTRL_STS); in get_mdix_status()
821 buf = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, in set_mdix_status()
824 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, in set_mdix_status()
829 buf = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, in set_mdix_status()
834 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, in set_mdix_status()
837 buf = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, in set_mdix_status()
843 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, in set_mdix_status()
846 buf = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, in set_mdix_status()
852 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, in set_mdix_status()
913 return generic_mii_ioctl(&dev->mii, if_mii(rq), cmd, NULL); in smsc95xx_ioctl()
994 dev->mii.dev = dev->net; in smsc95xx_phy_initialize()
995 dev->mii.mdio_read = smsc95xx_mdio_read; in smsc95xx_phy_initialize()
996 dev->mii.mdio_write = smsc95xx_mdio_write; in smsc95xx_phy_initialize()
997 dev->mii.phy_id_mask = 0x1f; in smsc95xx_phy_initialize()
998 dev->mii.reg_num_mask = 0x1f; in smsc95xx_phy_initialize()
999 dev->mii.phy_id = SMSC95XX_INTERNAL_PHY_ID; in smsc95xx_phy_initialize()
1002 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, MII_BMCR, BMCR_RESET); in smsc95xx_phy_initialize()
1006 bmcr = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, MII_BMCR); in smsc95xx_phy_initialize()
1015 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, MII_ADVERTISE, in smsc95xx_phy_initialize()
1020 ret = smsc95xx_mdio_read(dev->net, dev->mii.phy_id, PHY_INT_SRC); in smsc95xx_phy_initialize()
1026 smsc95xx_mdio_write(dev->net, dev->mii.phy_id, PHY_INT_MASK, in smsc95xx_phy_initialize()
1028 mii_nway_restart(&dev->mii); in smsc95xx_phy_initialize()
1354 struct mii_if_info *mii = &dev->mii; in smsc95xx_enable_phy_wakeup_interrupts() local
1360 ret = smsc95xx_mdio_read_nopm(dev->net, mii->phy_id, PHY_INT_SRC); in smsc95xx_enable_phy_wakeup_interrupts()
1365 ret = smsc95xx_mdio_read_nopm(dev->net, mii->phy_id, PHY_INT_MASK); in smsc95xx_enable_phy_wakeup_interrupts()
1371 smsc95xx_mdio_write_nopm(dev->net, mii->phy_id, PHY_INT_MASK, ret); in smsc95xx_enable_phy_wakeup_interrupts()
1378 struct mii_if_info *mii = &dev->mii; in smsc95xx_link_ok_nopm() local
1382 ret = smsc95xx_mdio_read_nopm(dev->net, mii->phy_id, MII_BMSR); in smsc95xx_link_ok_nopm()
1386 ret = smsc95xx_mdio_read_nopm(dev->net, mii->phy_id, MII_BMSR); in smsc95xx_link_ok_nopm()
1435 struct mii_if_info *mii = &dev->mii; in smsc95xx_enter_suspend1() local
1443 smsc95xx_mdio_write_nopm(dev->net, mii->phy_id, PHY_EDPD_CONFIG, in smsc95xx_enter_suspend1()
1447 ret = smsc95xx_mdio_read_nopm(dev->net, mii->phy_id, PHY_MODE_CTRL_STS); in smsc95xx_enter_suspend1()
1453 smsc95xx_mdio_write_nopm(dev->net, mii->phy_id, PHY_MODE_CTRL_STS, ret); in smsc95xx_enter_suspend1()