mirror of
https://gitee.com/openharmony/third_party_libnl
synced 2024-11-27 20:20:30 +00:00
lib: route: rule: add rule_groups to cache ops
Signed-off-by: Roopa Prabhu <roopa@cumulusnetworks.com> Acked-by: David Ahern <dsa@cumulusnetworks.com>
This commit is contained in:
parent
87707b78fc
commit
988b0cc0ca
@ -783,6 +783,12 @@ static struct nl_object_ops rule_obj_ops = {
|
||||
.oo_id_attrs = ~0,
|
||||
};
|
||||
|
||||
static struct nl_af_group rule_groups[] = {
|
||||
{ AF_INET, RTNLGRP_IPV4_RULE },
|
||||
{ AF_INET6, RTNLGRP_IPV6_RULE },
|
||||
{ END_OF_GROUP_LIST },
|
||||
};
|
||||
|
||||
static struct nl_cache_ops rtnl_rule_ops = {
|
||||
.co_name = "route/rule",
|
||||
.co_hdrsize = sizeof(struct fib_rule_hdr),
|
||||
@ -796,6 +802,7 @@ static struct nl_cache_ops rtnl_rule_ops = {
|
||||
.co_request_update = rule_request_update,
|
||||
.co_msg_parser = rule_msg_parser,
|
||||
.co_obj_ops = &rule_obj_ops,
|
||||
.co_groups = rule_groups,
|
||||
};
|
||||
|
||||
static void __init rule_init(void)
|
||||
|
Loading…
Reference in New Issue
Block a user