Module Name:    src
Committed By:   martin
Date:           Tue Apr 28 11:58:50 UTC 2015

Modified Files:
        src/sys/dev/sysmon: sysmon_taskq.c

Log Message:
sysmon_task_queue_sched needs to RUN_ONCE(tq_preinit) as well, it can
be called from sysmon_envsys_register() early.


To generate a diff of this commit:
cvs rdiff -u -r1.18 -r1.19 src/sys/dev/sysmon/sysmon_taskq.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/dev/sysmon/sysmon_taskq.c
diff -u src/sys/dev/sysmon/sysmon_taskq.c:1.18 src/sys/dev/sysmon/sysmon_taskq.c:1.19
--- src/sys/dev/sysmon/sysmon_taskq.c:1.18	Mon Apr 27 07:51:28 2015
+++ src/sys/dev/sysmon/sysmon_taskq.c	Tue Apr 28 11:58:49 2015
@@ -1,4 +1,4 @@
-/*	$NetBSD: sysmon_taskq.c,v 1.18 2015/04/27 07:51:28 pgoyette Exp $	*/
+/*	$NetBSD: sysmon_taskq.c,v 1.19 2015/04/28 11:58:49 martin Exp $	*/
 
 /*
  * Copyright (c) 2001, 2003 Wasabi Systems, Inc.
@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: sysmon_taskq.c,v 1.18 2015/04/27 07:51:28 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: sysmon_taskq.c,v 1.19 2015/04/28 11:58:49 martin Exp $");
 
 #include <sys/param.h>
 #include <sys/malloc.h>
@@ -212,6 +212,8 @@ sysmon_task_queue_sched(u_int pri, void 
 {
 	struct sysmon_task *st, *lst;
 
+	(void)RUN_ONCE(&once_tq, tq_preinit);
+
 	if (sysmon_task_queue_lwp == NULL)
 		aprint_debug("WARNING: Callback scheduled before sysmon "
 		    "task queue thread present\n");

Reply via email to