1 // SPDX-License-Identifier: GPL-2.0-or-later
4 * Copyright (C) 2018 Cumulus Networks, Inc.
7 #ifndef __STATIC_NHT_H__
8 #define __STATIC_NHT_H__
15 * When we get notification that nexthop tracking has an answer for
16 * us call this function to find the nexthop we are tracking so it
17 * can be installed or removed.
19 * sp -> The route we are looking at. If NULL then look at all
21 * nhp -> The nexthop that is being tracked.
22 * nh_num -> number of valid nexthops.
23 * afi -> The afi we are working in.
24 * vrf_id -> The vrf the nexthop is in.
26 extern void static_nht_update(struct prefix
*sp
, struct prefix
*nhp
,
27 uint32_t nh_num
, afi_t afi
, safi_t safi
,
31 * For the given tracked nexthop, nhp, mark all routes that use
32 * this route as in starting state again.
34 extern void static_nht_reset_start(struct prefix
*nhp
, afi_t afi
, safi_t safi
,
38 * For the given prefix, sp, mark it as in a particular state
40 extern void static_nht_mark_state(struct prefix
*sp
, safi_t safi
,
42 enum static_install_states state
);
45 * For the given nexthop, returns the string
47 extern void static_get_nh_str(struct static_nexthop
*nh
, char *nexthop
,