diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-02-15 20:11:12 -0500 |
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2018-03-09 11:07:41 -0500 |
| commit | 1fbfe5a57249d907b44b31f9031b27eb59a606d4 (patch) | |
| tree | a51b4f898711ed61424e65593408fcbb5c0f1901 /zebra/zebra_pbr.c | |
| parent | fd71d73eb307096d9f14804fdac9123742d868b1 (diff) | |
zebra: Cleanup api
Allow the add/delete to go through a intermediary function in
zebra_pbr.c instead of directly to the underlying os call. This
will allow future refinements to track the data a bit better
so that on shutdown we can delete the rules.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'zebra/zebra_pbr.c')
| -rw-r--r-- | zebra/zebra_pbr.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/zebra/zebra_pbr.c b/zebra/zebra_pbr.c index 827005b3a1..8a7e693bbf 100644 --- a/zebra/zebra_pbr.c +++ b/zebra/zebra_pbr.c @@ -31,6 +31,16 @@ /* Private functions */ /* Public functions */ +void zebra_pbr_add_rule(struct zebra_pbr_rule *rule, struct interface *ifp) +{ + kernel_add_pbr_rule(rule, ifp); +} + +void zebra_pbr_del_rule(struct zebra_pbr_rule *rule, struct interface *ifp) +{ + kernel_del_pbr_rule(rule, ifp); +} + /* * Handle success or failure of rule (un)install in the kernel. */ |
