diff options
| author | Rafael Zalamena <rzalamena@opensourcerouting.org> | 2024-01-11 17:23:28 -0300 |
|---|---|---|
| committer | Rafael Zalamena <rzalamena@opensourcerouting.org> | 2025-01-23 14:37:09 -0300 |
| commit | 28a9ca3405a6f7923b5a51b0e2db6844928676db (patch) | |
| tree | 5eac66f25964ae92201875ae803ba4d1b839eb13 /lib/zclient.h | |
| parent | dfdc12e1647341bd2402986c5753102ee2bbe4ab (diff) | |
lib,zebra: VRF table-direct support
Implement the necessary data structures and code changes to support sending
table-direct routes to protocols running in different VRFs.
Signed-off-by: Rafael Zalamena <rzalamena@opensourcerouting.org>
Diffstat (limited to 'lib/zclient.h')
| -rw-r--r-- | lib/zclient.h | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/lib/zclient.h b/lib/zclient.h index 2385a8a219..35e23ddf63 100644 --- a/lib/zclient.h +++ b/lib/zclient.h @@ -268,6 +268,15 @@ struct redist_proto { struct list *instances; }; +/** + * Redistribute table direct instance data structure: keeps the VRF + * that subscribed to the table ID. + */ +struct redist_table_direct { + vrf_id_t vrf_id; + int table_id; +}; + struct zclient_capabilities { uint32_t ecmp; bool mpls_enabled; @@ -924,6 +933,15 @@ extern void redist_add_instance(struct redist_proto *, unsigned short); extern void redist_del_instance(struct redist_proto *, unsigned short); extern void redist_del_all_instances(struct redist_proto *red); +extern struct redist_table_direct * +redist_lookup_table_direct(const struct redist_proto *red, const struct redist_table_direct *table); +extern bool redist_table_direct_has_id(const struct redist_proto *red, int table_id); +extern void redist_add_table_direct(struct redist_proto *red, + const struct redist_table_direct *table); +extern void redist_del_table_direct(struct redist_proto *red, + const struct redist_table_direct *table); + + /* * Send to zebra that the specified vrf is using label to resolve * itself for L3VPN's. Repeated calls of this function with |
