summaryrefslogtreecommitdiff
path: root/include/uapi
diff options
context:
space:
mode:
authorPetr Machata <petrm@nvidia.com>2024-03-06 15:49:16 +0300
committerDavid S. Miller <davem@davemloft.net>2024-03-08 13:35:46 +0300
commita207eab1039b501daddc8e729c9cc5d99fe93d18 (patch)
treef752c6c25c5301067ee241a3efa874be32ca3185 /include/uapi
parent2118f9390d83cf942de8b34faf3d35b54f9f4eee (diff)
downloadlinux-a207eab1039b501daddc8e729c9cc5d99fe93d18.tar.xz
net: nexthop: Add NHA_OP_FLAGS
In order to add per-nexthop statistics, but still not increase netlink message size for consumers that do not care about them, there needs to be a toggle through which the user indicates their desire to get the statistics. To that end, add a new attribute, NHA_OP_FLAGS. The idea is to be able to use the attribute for carrying of arbitrary operation-specific flags, i.e. not make it specific for get / dump. Add the new attribute to get and dump policies, but do not actually allow any flags yet -- those will come later as the flags themselves are defined. Add the necessary parsing code. Signed-off-by: Petr Machata <petrm@nvidia.com> Reviewed-by: David Ahern <dsahern@kernel.org> Reviewed-by: Ido Schimmel <idosch@nvidia.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/uapi')
-rw-r--r--include/uapi/linux/nexthop.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/uapi/linux/nexthop.h b/include/uapi/linux/nexthop.h
index d8ffa8c9ca78..086444e2946c 100644
--- a/include/uapi/linux/nexthop.h
+++ b/include/uapi/linux/nexthop.h
@@ -60,6 +60,9 @@ enum {
/* nested; nexthop bucket attributes */
NHA_RES_BUCKET,
+ /* u32; operation-specific flags */
+ NHA_OP_FLAGS,
+
__NHA_MAX,
};