diff options
author | Donald Sharp <sharpd@cumulusnetworks.com> | 2019-07-16 14:27:31 +0200 |
---|---|---|
committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2019-07-16 14:27:31 +0200 |
commit | 9fafbd158241f4c063af4ddbdc31cec5f4cc657f (patch) | |
tree | 201da6af66748e60c58fb3061e02c88b83872b07 /staticd/static_nht.h | |
parent | static: Start state tracking to know what we think the route is doing (diff) | |
download | frr-9fafbd158241f4c063af4ddbdc31cec5f4cc657f.tar.xz frr-9fafbd158241f4c063af4ddbdc31cec5f4cc657f.zip |
staticd: Track state of where we are and limit installs/updates to min
Track the state of the route and how we have installed it or not.
This commit limits the number of installs/updates/deletes to a
minimum number instead of repeated sends to zebra.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'staticd/static_nht.h')
-rw-r--r-- | staticd/static_nht.h | 13 |
1 files changed, 13 insertions, 0 deletions
diff --git a/staticd/static_nht.h b/staticd/static_nht.h index 7b9461685..18bb9e39c 100644 --- a/staticd/static_nht.h +++ b/staticd/static_nht.h @@ -34,4 +34,17 @@ */ extern void static_nht_update(struct prefix *sp, struct prefix *nhp, uint32_t nh_num, afi_t afi, vrf_id_t vrf_id); + +/* + * For the given tracked nexthop, nhp, mark all routes that use + * this route as in starting state again. + */ +extern void static_nht_reset_start(struct prefix *nhp, afi_t afi, + vrf_id_t nh_vrf_id); + +/* + * For the given prefix, sp, mark it as in a particular state + */ +extern void static_nht_mark_state(struct prefix *sp, vrf_id_t vrf_id, + enum static_install_states state); #endif |