mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-12 20:29:58 +00:00
Merge pull request #7878 from opensourcerouting/ldpd-metric-issue
ldpd: fix sporadic failures in the ldp-topo1 topotest
This commit is contained in:
commit
e43bb30294
@ -129,9 +129,7 @@ struct fec_node {
|
|||||||
uint32_t pw_remote_status;
|
uint32_t pw_remote_status;
|
||||||
|
|
||||||
void *data; /* fec specific data */
|
void *data; /* fec specific data */
|
||||||
uint8_t flags;
|
|
||||||
};
|
};
|
||||||
#define F_FEC_NHS_CHANGED 0x01
|
|
||||||
|
|
||||||
#define CHUNK_SIZE 64
|
#define CHUNK_SIZE 64
|
||||||
struct label_chunk {
|
struct label_chunk {
|
||||||
|
@ -340,8 +340,6 @@ lde_kernel_insert(struct fec *fec, int af, union ldpd_addr *nexthop,
|
|||||||
|
|
||||||
fnh = fec_nh_find(fn, af, nexthop, ifindex, route_type, route_instance);
|
fnh = fec_nh_find(fn, af, nexthop, ifindex, route_type, route_instance);
|
||||||
if (fnh == NULL) {
|
if (fnh == NULL) {
|
||||||
fn->flags |= F_FEC_NHS_CHANGED;
|
|
||||||
|
|
||||||
fnh = fec_nh_add(fn, af, nexthop, ifindex, route_type,
|
fnh = fec_nh_add(fn, af, nexthop, ifindex, route_type,
|
||||||
route_instance);
|
route_instance);
|
||||||
/*
|
/*
|
||||||
@ -418,17 +416,11 @@ lde_kernel_update(struct fec *fec)
|
|||||||
} else
|
} else
|
||||||
fnh->flags |= F_FEC_NH_NO_LDP;
|
fnh->flags |= F_FEC_NH_NO_LDP;
|
||||||
} else {
|
} else {
|
||||||
fn->flags |= F_FEC_NHS_CHANGED;
|
|
||||||
lde_send_delete_klabel(fn, fnh);
|
lde_send_delete_klabel(fn, fnh);
|
||||||
fec_nh_del(fnh);
|
fec_nh_del(fnh);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!(fn->flags & F_FEC_NHS_CHANGED))
|
|
||||||
/* return earlier if nothing has changed */
|
|
||||||
return;
|
|
||||||
fn->flags &= ~F_FEC_NHS_CHANGED;
|
|
||||||
|
|
||||||
if (LIST_EMPTY(&fn->nexthops)) {
|
if (LIST_EMPTY(&fn->nexthops)) {
|
||||||
RB_FOREACH(ln, nbr_tree, &lde_nbrs)
|
RB_FOREACH(ln, nbr_tree, &lde_nbrs)
|
||||||
lde_send_labelwithdraw(ln, fn, NULL, NULL);
|
lde_send_labelwithdraw(ln, fn, NULL, NULL);
|
||||||
|
Loading…
Reference in New Issue
Block a user