On 2/18/2019 10:22 AM, Michal Kubecek wrote: > Add table of ethernet link mode names and make it available as a string set > to userspace GET_STRSET requests. > > Signed-off-by: Michal Kubecek <mkube...@suse.cz> > --- [snip] > > +const char *const link_mode_names[] = { Maybe you can define a macro (totally untested) to build the table an avoid some of the repetition, something like: #define ETHTOOL_LINK_NAME(speed, duplex) \ [ETHTOOL_LINK_MODE_##speed_##duplex_BIT] = stringify(speed ## "/" ## duplex) -- Florian
- [RFC PATCH net-next v3 19/21] ethtool: provide device fea... Michal Kubecek
- [RFC PATCH net-next v3 18/21] ethtool: provide link state... Michal Kubecek
- [RFC PATCH net-next v3 17/21] ethtool: provide message le... Michal Kubecek
- [RFC PATCH net-next v3 16/21] ethtool: provide WoL inform... Michal Kubecek
- [RFC PATCH net-next v3 11/21] ethtool: provide driver/dev... Michal Kubecek
- [RFC PATCH net-next v3 13/21] ethtool: provide timestampi... Michal Kubecek
- Re: [RFC PATCH net-next v3 13/21] ethtool: provide t... Jakub Kicinski
- Re: [RFC PATCH net-next v3 13/21] ethtool: provi... Michal Kubecek
- Re: [RFC PATCH net-next v3 13/21] ethtool: p... Jakub Kicinski
- [RFC PATCH net-next v3 14/21] ethtool: provide link mode ... Michal Kubecek
- Re: [RFC PATCH net-next v3 14/21] ethtool: provide l... Florian Fainelli
- Re: [RFC PATCH net-next v3 14/21] ethtool: provi... Michal Kubecek
- [RFC PATCH net-next v3 07/21] ethtool: implement EVENT no... Michal Kubecek
- Re: [RFC PATCH net-next v3 07/21] ethtool: implement... Andrew Lunn
- Re: [RFC PATCH net-next v3 07/21] ethtool: imple... Michal Kubecek
- [RFC PATCH net-next v3 06/21] ethtool: support for netlin... Michal Kubecek
- [RFC PATCH net-next v3 01/21] netlink: introduce nla_put_... Michal Kubecek
- [RFC PATCH net-next v3 02/21] ethtool: move to its own di... Michal Kubecek
- Re: [RFC PATCH net-next v3 02/21] ethtool: move to i... Jakub Kicinski
- Re: [RFC PATCH net-next v3 00/21] ethtool netlink interfa... Jiri Pirko
- Re: [RFC PATCH net-next v3 00/21] ethtool netlink in... Michal Kubecek