Lines Matching +full:1000 +full:- +full:10000

1 // SPDX-License-Identifier: GPL-2.0+
10 * phy_speed_to_str - Return a string representing the PHY link speed
57 return "Unsupported (update phy-core.c)"; in phy_speed_to_str()
63 * phy_duplex_to_str - Return string describing the duplex
75 return "Unsupported (update phy-core.c)"; in phy_duplex_to_str()
80 * phy_rate_matching_to_str - Return a string describing the rate matching
94 return "open-loop"; in phy_rate_matching_to_str()
96 return "Unsupported (update phy-core.c)"; in phy_rate_matching_to_str()
101 * phy_interface_num_ports - Return the number of links that can be carried by
102 * a given MAC-PHY physical link. Returns 0 if this is
157 * - iow, descending speed.
235 PHY_SETTING( 10000, FULL, 10000baseCR_Full ),
236 PHY_SETTING( 10000, FULL, 10000baseER_Full ),
237 PHY_SETTING( 10000, FULL, 10000baseKR_Full ),
238 PHY_SETTING( 10000, FULL, 10000baseKX4_Full ),
239 PHY_SETTING( 10000, FULL, 10000baseLR_Full ),
240 PHY_SETTING( 10000, FULL, 10000baseLRM_Full ),
241 PHY_SETTING( 10000, FULL, 10000baseR_FEC ),
242 PHY_SETTING( 10000, FULL, 10000baseSR_Full ),
243 PHY_SETTING( 10000, FULL, 10000baseT_Full ),
250 PHY_SETTING( 1000, FULL, 1000baseT_Full ),
251 PHY_SETTING( 1000, HALF, 1000baseT_Half ),
252 PHY_SETTING( 1000, FULL, 1000baseT1_Full ),
253 PHY_SETTING( 1000, FULL, 1000baseX_Full ),
254 PHY_SETTING( 1000, FULL, 1000baseKX_Full ),
272 * phy_lookup_setting - lookup a PHY setting
295 if (p->bit < __ETHTOOL_LINK_MODE_MASK_NBITS && in phy_lookup_setting()
296 test_bit(p->bit, mask)) { in phy_lookup_setting()
298 if (p->speed == speed && p->duplex == duplex) { in phy_lookup_setting()
303 if (!match && p->speed <= speed) in phy_lookup_setting()
307 if (p->speed < speed) in phy_lookup_setting()
329 (count == 0 || speeds[count - 1] != settings[i].speed)) in phy_speeds()
341 if (p->speed > max_speed) in __set_linkmode_max_speed()
342 linkmode_clear_bit(p->bit, addr); in __set_linkmode_max_speed()
350 __set_linkmode_max_speed(max_speed, phydev->supported); in __set_phy_supported()
354 * phy_set_max_speed - Set the maximum speed the PHY should support
373 struct device_node *node = phydev->mdio.dev.of_node; in of_set_phy_supported()
382 if (!of_property_read_u32(node, "max-speed", &max_speed)) in of_set_phy_supported()
388 struct device_node *node = phydev->mdio.dev.of_node; in of_set_phy_eee_broken()
397 if (of_property_read_bool(node, "eee-broken-100tx")) in of_set_phy_eee_broken()
399 if (of_property_read_bool(node, "eee-broken-1000t")) in of_set_phy_eee_broken()
401 if (of_property_read_bool(node, "eee-broken-10gt")) in of_set_phy_eee_broken()
403 if (of_property_read_bool(node, "eee-broken-1000kx")) in of_set_phy_eee_broken()
405 if (of_property_read_bool(node, "eee-broken-10gkx4")) in of_set_phy_eee_broken()
407 if (of_property_read_bool(node, "eee-broken-10gkr")) in of_set_phy_eee_broken()
410 phydev->eee_broken_modes = broken; in of_set_phy_eee_broken()
414 * phy_resolve_aneg_pause - Determine pause autoneg results
425 if (phydev->duplex == DUPLEX_FULL) { in phy_resolve_aneg_pause()
426 phydev->pause = linkmode_test_bit(ETHTOOL_LINK_MODE_Pause_BIT, in phy_resolve_aneg_pause()
427 phydev->lp_advertising); in phy_resolve_aneg_pause()
428 phydev->asym_pause = linkmode_test_bit( in phy_resolve_aneg_pause()
430 phydev->lp_advertising); in phy_resolve_aneg_pause()
436 * phy_resolve_aneg_linkmode - resolve the advertisements into PHY settings
448 linkmode_and(common, phydev->lp_advertising, phydev->advertising); in phy_resolve_aneg_linkmode()
452 phydev->speed = settings[i].speed; in phy_resolve_aneg_linkmode()
453 phydev->duplex = settings[i].duplex; in phy_resolve_aneg_linkmode()
462 * phy_check_downshift - check whether downshift occurred
468 * read_status callback and sets phydev->speed to the actual link speed.
475 phydev->downshifted_rate = 0; in phy_check_downshift()
477 if (phydev->autoneg == AUTONEG_DISABLE || in phy_check_downshift()
478 phydev->speed == SPEED_UNKNOWN) in phy_check_downshift()
481 linkmode_and(common, phydev->lp_advertising, phydev->advertising); in phy_check_downshift()
489 if (speed == SPEED_UNKNOWN || phydev->speed >= speed) in phy_check_downshift()
493 phy_speed_to_str(speed), phy_speed_to_str(phydev->speed)); in phy_check_downshift()
495 phydev->downshifted_rate = 1; in phy_check_downshift()
504 linkmode_and(common, phydev->lp_advertising, phydev->advertising); in phy_resolve_min_speed()
506 while (--i >= 0) { in phy_resolve_min_speed()
522 return -EINVAL; in phy_speed_down_core()
524 __set_linkmode_max_speed(min_common_speed, phydev->advertising); in phy_speed_down_core()
544 * __phy_read_mmd - Convenience function for reading a register
557 return -EINVAL; in __phy_read_mmd()
559 if (phydev->drv && phydev->drv->read_mmd) { in __phy_read_mmd()
560 val = phydev->drv->read_mmd(phydev, devad, regnum); in __phy_read_mmd()
561 } else if (phydev->is_c45) { in __phy_read_mmd()
562 val = __mdiobus_c45_read(phydev->mdio.bus, phydev->mdio.addr, in __phy_read_mmd()
565 struct mii_bus *bus = phydev->mdio.bus; in __phy_read_mmd()
566 int phy_addr = phydev->mdio.addr; in __phy_read_mmd()
578 * phy_read_mmd - Convenience function for reading a register
599 * __phy_write_mmd - Convenience function for writing a register
613 return -EINVAL; in __phy_write_mmd()
615 if (phydev->drv && phydev->drv->write_mmd) { in __phy_write_mmd()
616 ret = phydev->drv->write_mmd(phydev, devad, regnum, val); in __phy_write_mmd()
617 } else if (phydev->is_c45) { in __phy_write_mmd()
618 ret = __mdiobus_c45_write(phydev->mdio.bus, phydev->mdio.addr, in __phy_write_mmd()
621 struct mii_bus *bus = phydev->mdio.bus; in __phy_write_mmd()
622 int phy_addr = phydev->mdio.addr; in __phy_write_mmd()
636 * phy_write_mmd - Convenience function for writing a register
658 * phy_modify_changed - Function for modifying a PHY register
683 * __phy_modify - Convenience function for modifying a PHY register
704 * phy_modify - Convenience function for modifying a given PHY register
727 * __phy_modify_mmd_changed - Function for modifying a register on MMD
759 * phy_modify_mmd_changed - Function for modifying a register on MMD
786 * __phy_modify_mmd - Convenience function for modifying a register on MMD
809 * phy_modify_mmd - Convenience function for modifying a register on MMD
835 …if (WARN_ONCE(!phydev->drv->read_page, "read_page callback not available, PHY driver not loaded?\n… in __phy_read_page()
836 return -EOPNOTSUPP; in __phy_read_page()
838 return phydev->drv->read_page(phydev); in __phy_read_page()
843 …if (WARN_ONCE(!phydev->drv->write_page, "write_page callback not available, PHY driver not loaded?… in __phy_write_page()
844 return -EOPNOTSUPP; in __phy_write_page()
846 return phydev->drv->write_page(phydev, page); in __phy_write_page()
850 * phy_save_page() - take the bus lock and save the current page
865 * phy_select_page() - take the bus lock, save the current page, and set a page
894 * phy_restore_page() - restore the page register and release the bus lock
933 * phy_read_paged() - Convenience function for reading a paged register
953 * phy_write_paged() - Convenience function for writing a paged register
974 * phy_modify_paged_changed() - Function for modifying a paged register
997 * phy_modify_paged() - Convenience function for modifying a paged register