Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/net/npf npf_worker_sys{init,fini}: initialize/destroy th...
details: https://anonhg.NetBSD.org/src/rev/2be44f9c14d8
branches: trunk
changeset: 933786:2be44f9c14d8
user: rmind <rmind%NetBSD.org@localhost>
date: Sat May 30 20:54:54 2020 +0000
description:
npf_worker_sys{init,fini}: initialize/destroy the exit_cv condvar.
diffstat:
sys/net/npf/npf_worker.c | 6 ++++--
1 files changed, 4 insertions(+), 2 deletions(-)
diffs (30 lines):
diff -r 6556d100d321 -r 2be44f9c14d8 sys/net/npf/npf_worker.c
--- a/sys/net/npf/npf_worker.c Sat May 30 20:54:46 2020 +0000
+++ b/sys/net/npf/npf_worker.c Sat May 30 20:54:54 2020 +0000
@@ -29,7 +29,7 @@
#ifdef _KERNEL
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: npf_worker.c,v 1.8 2020/05/30 14:16:56 rmind Exp $");
+__KERNEL_RCSID(0, "$NetBSD: npf_worker.c,v 1.9 2020/05/30 20:54:54 rmind Exp $");
#include <sys/param.h>
#include <sys/types.h>
@@ -81,7 +81,8 @@
winfo = kmem_zalloc(len, KM_SLEEP);
winfo->worker_count = nworkers;
mutex_init(&winfo->lock, MUTEX_DEFAULT, IPL_SOFTNET);
- cv_init(&winfo->cv, "npfgccv");
+ cv_init(&winfo->exit_cv, "npfgcx");
+ cv_init(&winfo->cv, "npfgcw");
LIST_INIT(&winfo->instances);
worker_info = winfo;
@@ -121,6 +122,7 @@
}
}
cv_destroy(&winfo->cv);
+ cv_destroy(&winfo->exit_cv);
mutex_destroy(&winfo->lock);
kmem_free(winfo, offsetof(npf_workerinfo_t, worker[nworkers]));
worker_info = NULL;
Home |
Main Index |
Thread Index |
Old Index