diff options
Diffstat (limited to 'sys/net/flowtable.c')
-rw-r--r-- | sys/net/flowtable.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/sys/net/flowtable.c b/sys/net/flowtable.c index 1ba07f9..198c4c3 100644 --- a/sys/net/flowtable.c +++ b/sys/net/flowtable.c @@ -1549,9 +1549,11 @@ static void flowtable_cleaner(void) { VNET_ITERATOR_DECL(vnet_iter); + struct thread *td; if (bootverbose) log(LOG_INFO, "flowtable cleaner started\n"); + td = curthread; while (1) { VNET_LIST_RLOCK(); VNET_FOREACH(vnet_iter) { @@ -1566,6 +1568,9 @@ flowtable_cleaner(void) * is arbitrary */ mtx_lock(&flowclean_lock); + thread_lock(td); + sched_prio(td, PPAUSE); + thread_unlock(td); flowclean_cycles++; cv_broadcast(&flowclean_f_cv); cv_timedwait(&flowclean_c_cv, &flowclean_lock, flowclean_freq); |