Lines Matching +full:1000 +full:base +full:- +full:kx
1 // SPDX-License-Identifier: GPL-2.0-only
13 [NETIF_F_SG_BIT] = "tx-scatter-gather",
14 [NETIF_F_IP_CSUM_BIT] = "tx-checksum-ipv4",
15 [NETIF_F_HW_CSUM_BIT] = "tx-checksum-ip-generic",
16 [NETIF_F_IPV6_CSUM_BIT] = "tx-checksum-ipv6",
18 [NETIF_F_FRAGLIST_BIT] = "tx-scatter-gather-fraglist",
19 [NETIF_F_HW_VLAN_CTAG_TX_BIT] = "tx-vlan-hw-insert",
21 [NETIF_F_HW_VLAN_CTAG_RX_BIT] = "rx-vlan-hw-parse",
22 [NETIF_F_HW_VLAN_CTAG_FILTER_BIT] = "rx-vlan-filter",
23 [NETIF_F_HW_VLAN_STAG_TX_BIT] = "tx-vlan-stag-hw-insert",
24 [NETIF_F_HW_VLAN_STAG_RX_BIT] = "rx-vlan-stag-hw-parse",
25 [NETIF_F_HW_VLAN_STAG_FILTER_BIT] = "rx-vlan-stag-filter",
26 [NETIF_F_VLAN_CHALLENGED_BIT] = "vlan-challenged",
27 [NETIF_F_GSO_BIT] = "tx-generic-segmentation",
28 [NETIF_F_GRO_BIT] = "rx-gro",
29 [NETIF_F_GRO_HW_BIT] = "rx-gro-hw",
30 [NETIF_F_LRO_BIT] = "rx-lro",
32 [NETIF_F_TSO_BIT] = "tx-tcp-segmentation",
33 [NETIF_F_GSO_ROBUST_BIT] = "tx-gso-robust",
34 [NETIF_F_TSO_ECN_BIT] = "tx-tcp-ecn-segmentation",
35 [NETIF_F_TSO_MANGLEID_BIT] = "tx-tcp-mangleid-segmentation",
36 [NETIF_F_TSO6_BIT] = "tx-tcp6-segmentation",
37 [NETIF_F_FSO_BIT] = "tx-fcoe-segmentation",
38 [NETIF_F_GSO_GRE_BIT] = "tx-gre-segmentation",
39 [NETIF_F_GSO_GRE_CSUM_BIT] = "tx-gre-csum-segmentation",
40 [NETIF_F_GSO_IPXIP4_BIT] = "tx-ipxip4-segmentation",
41 [NETIF_F_GSO_IPXIP6_BIT] = "tx-ipxip6-segmentation",
42 [NETIF_F_GSO_UDP_TUNNEL_BIT] = "tx-udp_tnl-segmentation",
43 [NETIF_F_GSO_UDP_TUNNEL_CSUM_BIT] = "tx-udp_tnl-csum-segmentation",
44 [NETIF_F_GSO_PARTIAL_BIT] = "tx-gso-partial",
45 [NETIF_F_GSO_TUNNEL_REMCSUM_BIT] = "tx-tunnel-remcsum-segmentation",
46 [NETIF_F_GSO_SCTP_BIT] = "tx-sctp-segmentation",
47 [NETIF_F_GSO_ESP_BIT] = "tx-esp-segmentation",
48 [NETIF_F_GSO_UDP_L4_BIT] = "tx-udp-segmentation",
49 [NETIF_F_GSO_FRAGLIST_BIT] = "tx-gso-list",
51 [NETIF_F_FCOE_CRC_BIT] = "tx-checksum-fcoe-crc",
52 [NETIF_F_SCTP_CRC_BIT] = "tx-checksum-sctp",
53 [NETIF_F_NTUPLE_BIT] = "rx-ntuple-filter",
54 [NETIF_F_RXHASH_BIT] = "rx-hashing",
55 [NETIF_F_RXCSUM_BIT] = "rx-checksum",
56 [NETIF_F_NOCACHE_COPY_BIT] = "tx-nocache-copy",
58 [NETIF_F_RXFCS_BIT] = "rx-fcs",
59 [NETIF_F_RXALL_BIT] = "rx-all",
60 [NETIF_F_HW_L2FW_DOFFLOAD_BIT] = "l2-fwd-offload",
61 [NETIF_F_HW_TC_BIT] = "hw-tc-offload",
62 [NETIF_F_HW_ESP_BIT] = "esp-hw-offload",
63 [NETIF_F_HW_ESP_TX_CSUM_BIT] = "esp-tx-csum-hw-offload",
64 [NETIF_F_RX_UDP_TUNNEL_PORT_BIT] = "rx-udp_tunnel-port-offload",
65 [NETIF_F_HW_TLS_RECORD_BIT] = "tls-hw-record",
66 [NETIF_F_HW_TLS_TX_BIT] = "tls-hw-tx-offload",
67 [NETIF_F_HW_TLS_RX_BIT] = "tls-hw-rx-offload",
68 [NETIF_F_GRO_FRAGLIST_BIT] = "rx-gro-list",
69 [NETIF_F_HW_MACSEC_BIT] = "macsec-hw-offload",
70 [NETIF_F_GRO_UDP_FWD_BIT] = "rx-udp-gro-forwarding",
71 [NETIF_F_HW_HSR_TAG_INS_BIT] = "hsr-tag-ins-offload",
72 [NETIF_F_HW_HSR_TAG_RM_BIT] = "hsr-tag-rm-offload",
73 [NETIF_F_HW_HSR_FWD_BIT] = "hsr-fwd-offload",
74 [NETIF_F_HW_HSR_DUP_BIT] = "hsr-dup-offload",
87 [ETHTOOL_RX_COPYBREAK] = "rx-copybreak",
88 [ETHTOOL_TX_COPYBREAK] = "tx-copybreak",
89 [ETHTOOL_PFC_PREVENTION_TOUT] = "pfc-prevention-tout",
90 [ETHTOOL_TX_COPYBREAK_BUF_SIZE] = "tx-copybreak-buf-size",
96 [ETHTOOL_PHY_DOWNSHIFT] = "phy-downshift",
97 [ETHTOOL_PHY_FAST_LINK_DOWN] = "phy-fast-link-down",
98 [ETHTOOL_PHY_EDPD] = "phy-energy-detect-power-down",
102 #speed "base" #type "/" #duplex
114 __DEFINE_LINK_MODE_NAME(1000, T, Half),
115 __DEFINE_LINK_MODE_NAME(1000, T, Full),
127 __DEFINE_LINK_MODE_NAME(1000, KX, Full),
151 __DEFINE_LINK_MODE_NAME(1000, X, Full),
178 __DEFINE_LINK_MODE_NAME(1000, T1, Full),
275 __DEFINE_LINK_MODE_PARAMS(1000, T, Half),
276 __DEFINE_LINK_MODE_PARAMS(1000, T, Full),
288 __DEFINE_LINK_MODE_PARAMS(1000, KX, Full),
316 __DEFINE_LINK_MODE_PARAMS(1000, X, Full),
343 __DEFINE_LINK_MODE_PARAMS(1000, T1, Full),
413 [const_ilog2(SOF_TIMESTAMPING_TX_HARDWARE)] = "hardware-transmit",
414 [const_ilog2(SOF_TIMESTAMPING_TX_SOFTWARE)] = "software-transmit",
415 [const_ilog2(SOF_TIMESTAMPING_RX_HARDWARE)] = "hardware-receive",
416 [const_ilog2(SOF_TIMESTAMPING_RX_SOFTWARE)] = "software-receive",
417 [const_ilog2(SOF_TIMESTAMPING_SOFTWARE)] = "software-system-clock",
418 [const_ilog2(SOF_TIMESTAMPING_SYS_HARDWARE)] = "hardware-legacy-clock",
419 [const_ilog2(SOF_TIMESTAMPING_RAW_HARDWARE)] = "hardware-raw-clock",
420 [const_ilog2(SOF_TIMESTAMPING_OPT_ID)] = "option-id",
421 [const_ilog2(SOF_TIMESTAMPING_TX_SCHED)] = "sched-transmit",
422 [const_ilog2(SOF_TIMESTAMPING_TX_ACK)] = "ack-transmit",
423 [const_ilog2(SOF_TIMESTAMPING_OPT_CMSG)] = "option-cmsg",
424 [const_ilog2(SOF_TIMESTAMPING_OPT_TSONLY)] = "option-tsonly",
425 [const_ilog2(SOF_TIMESTAMPING_OPT_STATS)] = "option-stats",
426 [const_ilog2(SOF_TIMESTAMPING_OPT_PKTINFO)] = "option-pktinfo",
427 [const_ilog2(SOF_TIMESTAMPING_OPT_TX_SWHW)] = "option-tx-swhw",
428 [const_ilog2(SOF_TIMESTAMPING_BIND_PHC)] = "bind-phc",
429 [const_ilog2(SOF_TIMESTAMPING_OPT_ID_TCP)] = "option-id-tcp",
430 [const_ilog2(SOF_TIMESTAMPING_OPT_RX_FILTER)] = "option-rx-filter",
437 [HWTSTAMP_TX_ONESTEP_SYNC] = "onestep-sync",
438 [HWTSTAMP_TX_ONESTEP_P2P] = "onestep-p2p",
446 [HWTSTAMP_FILTER_PTP_V1_L4_EVENT] = "ptpv1-l4-event",
447 [HWTSTAMP_FILTER_PTP_V1_L4_SYNC] = "ptpv1-l4-sync",
448 [HWTSTAMP_FILTER_PTP_V1_L4_DELAY_REQ] = "ptpv1-l4-delay-req",
449 [HWTSTAMP_FILTER_PTP_V2_L4_EVENT] = "ptpv2-l4-event",
450 [HWTSTAMP_FILTER_PTP_V2_L4_SYNC] = "ptpv2-l4-sync",
451 [HWTSTAMP_FILTER_PTP_V2_L4_DELAY_REQ] = "ptpv2-l4-delay-req",
452 [HWTSTAMP_FILTER_PTP_V2_L2_EVENT] = "ptpv2-l2-event",
453 [HWTSTAMP_FILTER_PTP_V2_L2_SYNC] = "ptpv2-l2-sync",
454 [HWTSTAMP_FILTER_PTP_V2_L2_DELAY_REQ] = "ptpv2-l2-delay-req",
455 [HWTSTAMP_FILTER_PTP_V2_EVENT] = "ptpv2-event",
456 [HWTSTAMP_FILTER_PTP_V2_SYNC] = "ptpv2-sync",
457 [HWTSTAMP_FILTER_PTP_V2_DELAY_REQ] = "ptpv2-delay-req",
458 [HWTSTAMP_FILTER_NTP_ALL] = "ntp-all",
465 [ETHTOOL_UDP_TUNNEL_TYPE_VXLAN_GPE] = "vxlan-gpe",
470 /* return false if legacy contained non-0 deprecated fields
486 if (legacy_settings->maxtxpkt || in convert_legacy_settings_to_link_ksettings()
487 legacy_settings->maxrxpkt) in convert_legacy_settings_to_link_ksettings()
491 link_ksettings->link_modes.supported, in convert_legacy_settings_to_link_ksettings()
492 legacy_settings->supported); in convert_legacy_settings_to_link_ksettings()
494 link_ksettings->link_modes.advertising, in convert_legacy_settings_to_link_ksettings()
495 legacy_settings->advertising); in convert_legacy_settings_to_link_ksettings()
497 link_ksettings->link_modes.lp_advertising, in convert_legacy_settings_to_link_ksettings()
498 legacy_settings->lp_advertising); in convert_legacy_settings_to_link_ksettings()
499 link_ksettings->base.speed in convert_legacy_settings_to_link_ksettings()
501 link_ksettings->base.duplex in convert_legacy_settings_to_link_ksettings()
502 = legacy_settings->duplex; in convert_legacy_settings_to_link_ksettings()
503 link_ksettings->base.port in convert_legacy_settings_to_link_ksettings()
504 = legacy_settings->port; in convert_legacy_settings_to_link_ksettings()
505 link_ksettings->base.phy_address in convert_legacy_settings_to_link_ksettings()
506 = legacy_settings->phy_address; in convert_legacy_settings_to_link_ksettings()
507 link_ksettings->base.autoneg in convert_legacy_settings_to_link_ksettings()
508 = legacy_settings->autoneg; in convert_legacy_settings_to_link_ksettings()
509 link_ksettings->base.mdio_support in convert_legacy_settings_to_link_ksettings()
510 = legacy_settings->mdio_support; in convert_legacy_settings_to_link_ksettings()
511 link_ksettings->base.eth_tp_mdix in convert_legacy_settings_to_link_ksettings()
512 = legacy_settings->eth_tp_mdix; in convert_legacy_settings_to_link_ksettings()
513 link_ksettings->base.eth_tp_mdix_ctrl in convert_legacy_settings_to_link_ksettings()
514 = legacy_settings->eth_tp_mdix_ctrl; in convert_legacy_settings_to_link_ksettings()
520 if (!dev->ethtool_ops->get_link) in __ethtool_get_link()
521 return -EOPNOTSUPP; in __ethtool_get_link()
523 return netif_running(dev) && dev->ethtool_ops->get_link(dev); in __ethtool_get_link()
528 const struct ethtool_ops *ops = dev->ethtool_ops; in ethtool_get_rxnfc_rule_count()
534 err = ops->get_rxnfc(dev, &info, NULL); in ethtool_get_rxnfc_rule_count()
550 for (i = 0; i < ctx->indir_size; i++) in ethtool_get_rss_ctx_max_channel()
557 const struct ethtool_ops *ops = dev->ethtool_ops; in ethtool_get_max_rxnfc_channel()
562 if (!ops->get_rxnfc) in ethtool_get_max_rxnfc_channel()
563 return -EOPNOTSUPP; in ethtool_get_max_rxnfc_channel()
567 return -EINVAL; in ethtool_get_max_rxnfc_channel()
571 return -ENOMEM; in ethtool_get_max_rxnfc_channel()
573 info->cmd = ETHTOOL_GRXCLSRLALL; in ethtool_get_max_rxnfc_channel()
574 info->rule_cnt = rule_cnt; in ethtool_get_max_rxnfc_channel()
575 err = ops->get_rxnfc(dev, info, info->rule_locs); in ethtool_get_max_rxnfc_channel()
582 .fs.location = info->rule_locs[i], in ethtool_get_max_rxnfc_channel()
585 err = ops->get_rxnfc(dev, &rule_info, NULL); in ethtool_get_max_rxnfc_channel()
597 ctx = xa_load(&dev->ethtool->rss_ctx, in ethtool_get_max_rxnfc_channel()
621 mutex_lock(&dev->ethtool->rss_lock); in ethtool_get_max_rss_ctx_channel()
622 xa_for_each(&dev->ethtool->rss_ctx, context, ctx) in ethtool_get_max_rss_ctx_channel()
624 mutex_unlock(&dev->ethtool->rss_lock); in ethtool_get_max_rss_ctx_channel()
637 * Assume drivers won't auto-regenerate the additional tables, in ethtool_get_max_rxfh_channel()
645 if (!dev->ethtool_ops->get_rxfh_indir_size || in ethtool_get_max_rxfh_channel()
646 !dev->ethtool_ops->get_rxfh) in ethtool_get_max_rxfh_channel()
648 dev_size = dev->ethtool_ops->get_rxfh_indir_size(dev); in ethtool_get_max_rxfh_channel()
656 ret = dev->ethtool_ops->get_rxfh(dev, &rxfh); in ethtool_get_max_rxfh_channel()
662 while (dev_size--) in ethtool_get_max_rxfh_channel()
687 return -EINVAL; in ethtool_check_max_channel()
692 return -EINVAL; in ethtool_check_max_channel()
699 return -EINVAL; in ethtool_check_max_channel()
707 const struct ethtool_ops *ops = dev->ethtool_ops; in ethtool_check_rss_ctx_busy()
711 if (!ops->get_rxnfc) in ethtool_check_rss_ctx_busy()
719 return -EINVAL; in ethtool_check_rss_ctx_busy()
723 return -ENOMEM; in ethtool_check_rss_ctx_busy()
725 info->cmd = ETHTOOL_GRXCLSRLALL; in ethtool_check_rss_ctx_busy()
726 info->rule_cnt = rule_cnt; in ethtool_check_rss_ctx_busy()
727 rc = ops->get_rxnfc(dev, info, info->rule_locs); in ethtool_check_rss_ctx_busy()
734 .fs.location = info->rule_locs[i], in ethtool_check_rss_ctx_busy()
737 rc = ops->get_rxnfc(dev, &rule_info, NULL); in ethtool_check_rss_ctx_busy()
743 rc = -EBUSY; in ethtool_check_rss_ctx_busy()
755 if (WARN_ON(ops->set_coalesce && !ops->supported_coalesce_params)) in ethtool_check_ops()
756 return -EINVAL; in ethtool_check_ops()
757 if (WARN_ON(ops->rxfh_max_num_contexts == 1)) in ethtool_check_ops()
758 return -EINVAL; in ethtool_check_ops()
768 const struct ethtool_ops *ops = dev->ethtool_ops; in __ethtool_get_ts_info()
769 struct phy_device *phydev = dev->phydev; in __ethtool_get_ts_info()
773 info->cmd = ETHTOOL_GET_TS_INFO; in __ethtool_get_ts_info()
774 info->phc_index = -1; in __ethtool_get_ts_info()
778 else if (ops->get_ts_info) in __ethtool_get_ts_info()
779 err = ops->get_ts_info(dev, info); in __ethtool_get_ts_info()
781 info->so_timestamping |= SOF_TIMESTAMPING_RX_SOFTWARE | in __ethtool_get_ts_info()
824 link_ksettings->base.speed = link_info->speed; in ethtool_params_from_link_mode()
825 link_ksettings->lanes = link_info->lanes; in ethtool_params_from_link_mode()
826 link_ksettings->base.duplex = link_info->duplex; in ethtool_params_from_link_mode()
844 linkmode_set_bit_array(map->cap_arr, map->arr_size, map->caps); in ethtool_forced_speed_maps_init()
845 map->cap_arr = NULL; in ethtool_forced_speed_maps_init()
846 map->arr_size = 0; in ethtool_forced_speed_maps_init()
856 !lockdep_is_held_type(&dev->ethtool->rss_lock, -1), in ethtool_rxfh_context_lost()
860 ctx = xa_erase(&dev->ethtool->rss_ctx, context_id); in ethtool_rxfh_context_lost()