]> www.infradead.org Git - users/jedix/linux-maple.git/commit
tools: ynl: let classic netlink requests specify extra nlflags
authorJakub Kicinski <kuba@kernel.org>
Tue, 29 Apr 2025 15:46:56 +0000 (08:46 -0700)
committerPaolo Abeni <pabeni@redhat.com>
Fri, 2 May 2025 10:41:02 +0000 (12:41 +0200)
commitfe7d57e040f7d189e3bd030f311bb2011a0cc35a
tree27b55363409030a8df3aee9c77088ed8ebe60109
parentd12a7be02524a6f4d8d5d57920001ea63a93f28d
tools: ynl: let classic netlink requests specify extra nlflags

Classic netlink makes extensive use of flags. Support specifying
them the same way as attributes are specified (using a helper),
for example:

     rt_link_newlink_req_set_nlflags(req, NLM_F_CREATE | NLM_F_ECHO);

Wrap the code up in a RenderInfo predicate. I think that some
genetlink families may want this, too. It should be easy to
add a spec property later.

Reviewed-by: Donald Hunter <donald.hunter@gmail.com>
Reviewed-by: Jacob Keller <jacob.e.keller@intel.com>
Signed-off-by: Jakub Kicinski <kuba@kernel.org>
Link: https://patch.msgid.link/20250429154704.2613851-5-kuba@kernel.org
Signed-off-by: Paolo Abeni <pabeni@redhat.com>
tools/net/ynl/lib/ynl-priv.h
tools/net/ynl/lib/ynl.c
tools/net/ynl/pyynl/ynl_gen_c.py