mirror of
https://github.com/openharmony/third_party_libnl.git
synced 2026-07-21 16:05:23 -04:00
lib/route: Allow override of IFLA_AF_SPEC nesting
This patch adds the ability to override nesting into an AF specific
attribute. An example of this is the bridge module.
Regular Nesting:
[IFLA_AF_SPEC]
[AF_INET]
[AF_INET_ATTRS]
Bridge Nesting:
[IFLA_AF_SPEC]
[AF_BRIDGE_ATTRS]
This patch adds ao_fill_af_no_nest to struct rtnl_link_af_ops.
When set to non-zero, this will override the nested AF attribute
and allow nesting of attributes directly into IFLA_AF_SPEC.
Signed-off-by: Jef Oliver <jef.oliver@intel.com>
Signed-off-by: Thomas Haller <thaller@redhat.com>
This commit is contained in:
committed by
Thomas Haller
parent
9be1849eab
commit
ab17f9803d
@@ -167,6 +167,14 @@ struct rtnl_link_af_ops
|
||||
* here. (eg. NLA_F_NESTED)
|
||||
*/
|
||||
const int ao_fill_pi_flags;
|
||||
|
||||
/** IFLA_AF_SPEC nesting override
|
||||
*
|
||||
* Called if a link message is sent to the kernel. If this is set,
|
||||
* the AF specific nest is not created. Instead, AF specific attributes
|
||||
* are nested directly in the IFLA_AF_SPEC attribute.
|
||||
*/
|
||||
const int ao_fill_af_no_nest;
|
||||
};
|
||||
|
||||
extern struct rtnl_link_af_ops *rtnl_link_af_ops_lookup(unsigned int);
|
||||
|
||||
Reference in New Issue
Block a user