mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-12-22 09:41:54 +00:00
Table: too fast export validity check replaced with just a retry
This commit is contained in:
parent
661193cf98
commit
d7cf378003
@ -2196,23 +2196,18 @@ rt_net_feed_validate_first(
|
|||||||
if (!first)
|
if (!first)
|
||||||
return first_in_net;
|
return first_in_net;
|
||||||
|
|
||||||
for (uint i = 1; i < 4096; i++)
|
/* Export item validity check: we must find it between first_in_net and last_in_net */
|
||||||
{
|
const struct rt_pending_export *rpe = first_in_net;
|
||||||
/* Export item validity check: we must find it between first_in_net and last_in_net */
|
while (rpe)
|
||||||
const struct rt_pending_export *rpe = first_in_net;
|
if (rpe == first)
|
||||||
while (rpe)
|
return first;
|
||||||
if (rpe == first)
|
else if (rpe == last_in_net)
|
||||||
return first;
|
/* Got to the end without finding the beginning */
|
||||||
else if (rpe == last_in_net)
|
break;
|
||||||
/* Got to the end without finding the beginning */
|
else
|
||||||
break;
|
rpe = atomic_load_explicit(&rpe->next, memory_order_acquire);
|
||||||
else
|
|
||||||
rpe = atomic_load_explicit(&rpe->next, memory_order_acquire);
|
|
||||||
|
|
||||||
birdloop_yield();
|
/* Not found, inconsistent export, retry */
|
||||||
}
|
|
||||||
|
|
||||||
log(L_WARN "Waiting too long for table announcement to finish");
|
|
||||||
RT_READ_RETRY(tr);
|
RT_READ_RETRY(tr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user