mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-10 01:37:31 +00:00
zebra: Remove uneeded is_valid NHE functons
Remove some unused is_valid checks for the nhg_hash_entry's. Signed-off-by: Stephen Worley <sworley@cumulusnetworks.com>
This commit is contained in:
parent
055a3fa698
commit
9ddc33505a
@ -869,26 +869,6 @@ void zebra_nhg_increment_ref(struct nhg_hash_entry *nhe)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
static bool zebra_nhg_is_valid(struct nhg_hash_entry *nhe)
|
|
||||||
{
|
|
||||||
if (nhe->flags & NEXTHOP_GROUP_VALID)
|
|
||||||
return true;
|
|
||||||
|
|
||||||
return false;
|
|
||||||
}
|
|
||||||
|
|
||||||
bool zebra_nhg_id_is_valid(uint32_t id)
|
|
||||||
{
|
|
||||||
struct nhg_hash_entry *nhe = NULL;
|
|
||||||
bool is_valid = false;
|
|
||||||
|
|
||||||
nhe = zebra_nhg_lookup_id(id);
|
|
||||||
|
|
||||||
if (nhe)
|
|
||||||
is_valid = zebra_nhg_is_valid(nhe);
|
|
||||||
|
|
||||||
return is_valid;
|
|
||||||
}
|
|
||||||
void zebra_nhg_set_invalid(struct nhg_hash_entry *nhe)
|
void zebra_nhg_set_invalid(struct nhg_hash_entry *nhe)
|
||||||
{
|
{
|
||||||
if (!zebra_nhg_depends_is_empty(nhe)
|
if (!zebra_nhg_depends_is_empty(nhe)
|
||||||
|
@ -223,7 +223,6 @@ void zebra_nhg_free(void *arg);
|
|||||||
void zebra_nhg_decrement_ref(struct nhg_hash_entry *nhe);
|
void zebra_nhg_decrement_ref(struct nhg_hash_entry *nhe);
|
||||||
void zebra_nhg_increment_ref(struct nhg_hash_entry *nhe);
|
void zebra_nhg_increment_ref(struct nhg_hash_entry *nhe);
|
||||||
|
|
||||||
extern bool zebra_nhg_id_is_valid(uint32_t id);
|
|
||||||
void zebra_nhg_set_invalid(struct nhg_hash_entry *nhe);
|
void zebra_nhg_set_invalid(struct nhg_hash_entry *nhe);
|
||||||
void zebra_nhg_set_if(struct nhg_hash_entry *nhe, struct interface *ifp);
|
void zebra_nhg_set_if(struct nhg_hash_entry *nhe, struct interface *ifp);
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user