mirror of
https://github.com/openvswitch/ovs
synced 2025-10-25 15:07:05 +00:00
ovs-thread: Quiesce in xpthread_barrier_wait().
Otherwise the udpif revalidator threads can postpone RCU callbacks essentially forever, especially if there are many revalidator threads and little network traffic. Reported-by: Alex Wang <alexw@nicira.com> Signed-off-by: Ben Pfaff <blp@nicira.com> Acked-by: Alex Wang <alexw@nicira.com>
This commit is contained in:
@@ -240,7 +240,10 @@ xpthread_barrier_wait(pthread_barrier_t *barrier)
|
||||
{
|
||||
int error;
|
||||
|
||||
ovsrcu_quiesce_start();
|
||||
error = pthread_barrier_wait(barrier);
|
||||
ovsrcu_quiesce_end();
|
||||
|
||||
if (error && OVS_UNLIKELY(error != PTHREAD_BARRIER_SERIAL_THREAD)) {
|
||||
ovs_abort(error, "pthread_barrier_wait failed");
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user