Subject: Re: [PATCH v9 02/25] net/ethtool: add new stringset ETH_SS_ULP_DDP_{CAPS,STATS}

From: Jakub Kicinski <[email-masked]>
Date: Mon, 23 Jan 2023 14:32:56 -0800

On Mon, 23 Jan 2023 20:31:10 +0200 Aurelien Aptel wrote:
> Jakub Kicinski <[email-masked]> writes:
> > This should be in uAPI and used as attribute IDs.  
> 
> Following the discussion from [1] ("you can add the dynamic string set
> if you like.") we deliberately did not expose the enum to userspace so
> that ethtool doesn't have to be updated or recompiled to list newer
> kernel ULP DDP statistics.
> 
> Should we change this approach?
> 
> 1: https://lore.kernel.org/netdev/[email-masked]/

Not at all, but the names are really mostly for human consumption.
If any programmer wants to use the stats (and assuming they use C/C++)
it will be more convenient for them to use attribute ids from the enum.
Without having to resolve them using stat names.

This is how other stats are implemented in ethtool-netlink.