Subject: Re: [PATCH net-next v17 03/15] net: phy: Introduce PHY ports representation

From: Jakub Kicinski <[email-masked]>
Date: Wed, 19 Nov 2025 19:54:00 -0800

On Wed, 19 Nov 2025 20:59:04 +0100 Maxime Chevallier wrote:
> diff --git a/net/ethtool/common.c b/net/ethtool/common.c
> index 2f4b70f104e8..8216e4ada58e 100644
> --- a/net/ethtool/common.c
> +++ b/net/ethtool/common.c
> @@ -460,6 +460,21 @@ const struct link_mode_info link_mode_params[] = {
>  static_assert(ARRAY_SIZE(link_mode_params) == __ETHTOOL_LINK_MODE_MASK_NBITS);
>  EXPORT_SYMBOL_GPL(link_mode_params);
>  
> +const char ethtool_link_medium_names[][ETH_GSTRING_LEN] = {
> +	[ETHTOOL_LINK_MEDIUM_BASET] = "BaseT",
> +	[ETHTOOL_LINK_MEDIUM_BASEK] = "BaseK",
> +	[ETHTOOL_LINK_MEDIUM_BASES] = "BaseS",
> +	[ETHTOOL_LINK_MEDIUM_BASEC] = "BaseC",
> +	[ETHTOOL_LINK_MEDIUM_BASEL] = "BaseL",
> +	[ETHTOOL_LINK_MEDIUM_BASED] = "BaseD",
> +	[ETHTOOL_LINK_MEDIUM_BASEE] = "BaseE",
> +	[ETHTOOL_LINK_MEDIUM_BASEF] = "BaseF",
> +	[ETHTOOL_LINK_MEDIUM_BASEV] = "BaseV",
> +	[ETHTOOL_LINK_MEDIUM_BASEMLD] = "BaseMLD",
> +	[ETHTOOL_LINK_MEDIUM_NONE] = "None",
> +};
> +static_assert(ARRAY_SIZE(ethtool_link_medium_names) == __ETHTOOL_LINK_MEDIUM_LAST);

Thanks for reshuffling things, this one needs a static tho:

net/ethtool/common.c:463:12: warning: symbol 'ethtool_link_medium_names' was not declared. Should it be static?
-- 
pw-bot: cr