netlink: specs: ethtool: define header-flags as an enum
Recent changes added header flags to the spec. Use an enum instead of defines for more seamless codegen. [Jakub: drop the already applied parts and rewrite message] Signed-off-by: Rahul Rameshbabu <rrameshbabu@nvidia.com> Reviewed-by: Dragos Tatulea <dtatulea@nvidia.com> Link: https://lore.kernel.org/r/20240403212931.128541-6-rrameshbabu@nvidia.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
This commit is contained in:
parent
3579032c08
commit
ff8877b04e
@ -18,7 +18,6 @@ definitions:
|
|||||||
entries: []
|
entries: []
|
||||||
-
|
-
|
||||||
name: header-flags
|
name: header-flags
|
||||||
enum-name:
|
|
||||||
type: flags
|
type: flags
|
||||||
entries: [ compact-bitsets, omit-reply, stats ]
|
entries: [ compact-bitsets, omit-reply, stats ]
|
||||||
|
|
||||||
|
@ -117,12 +117,11 @@ enum {
|
|||||||
|
|
||||||
/* request header */
|
/* request header */
|
||||||
|
|
||||||
/* use compact bitsets in reply */
|
enum ethtool_header_flags {
|
||||||
#define ETHTOOL_FLAG_COMPACT_BITSETS (1 << 0)
|
ETHTOOL_FLAG_COMPACT_BITSETS = 1 << 0, /* use compact bitsets in reply */
|
||||||
/* provide optional reply for SET or ACT requests */
|
ETHTOOL_FLAG_OMIT_REPLY = 1 << 1, /* provide optional reply for SET or ACT requests */
|
||||||
#define ETHTOOL_FLAG_OMIT_REPLY (1 << 1)
|
ETHTOOL_FLAG_STATS = 1 << 2, /* request statistics, if supported by the driver */
|
||||||
/* request statistics, if supported by the driver */
|
};
|
||||||
#define ETHTOOL_FLAG_STATS (1 << 2)
|
|
||||||
|
|
||||||
#define ETHTOOL_FLAG_ALL (ETHTOOL_FLAG_COMPACT_BITSETS | \
|
#define ETHTOOL_FLAG_ALL (ETHTOOL_FLAG_COMPACT_BITSETS | \
|
||||||
ETHTOOL_FLAG_OMIT_REPLY | \
|
ETHTOOL_FLAG_OMIT_REPLY | \
|
||||||
|
Loading…
Reference in New Issue
Block a user