Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/kern Update initialization of sysmon and its components....



details:   https://anonhg.NetBSD.org/src/rev/3cad2d698db1
branches:  trunk
changeset: 807833:3cad2d698db1
user:      pgoyette <pgoyette%NetBSD.org@localhost>
date:      Thu Apr 23 23:23:08 2015 +0000

description:
Update initialization of sysmon and its components. These are now handled as part of module initialization, and do not require manual invocation. sysmon_taskq is special, since it is potentially used 
by several non-module users who may need the facility before modules are fully ready.

diffstat:

 sys/kern/init_main.c |  30 ++++++++----------------------
 1 files changed, 8 insertions(+), 22 deletions(-)

diffs (70 lines):

diff -r 8a2fa86409d0 -r 3cad2d698db1 sys/kern/init_main.c
--- a/sys/kern/init_main.c      Thu Apr 23 23:23:00 2015 +0000
+++ b/sys/kern/init_main.c      Thu Apr 23 23:23:08 2015 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: init_main.c,v 1.462 2015/03/06 09:28:15 mrg Exp $      */
+/*     $NetBSD: init_main.c,v 1.463 2015/04/23 23:23:08 pgoyette Exp $ */
 
 /*-
  * Copyright (c) 2008, 2009 The NetBSD Foundation, Inc.
@@ -97,7 +97,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.462 2015/03/06 09:28:15 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: init_main.c,v 1.463 2015/04/23 23:23:08 pgoyette Exp $");
 
 #include "opt_ddb.h"
 #include "opt_ipsec.h"
@@ -117,10 +117,7 @@
 #include "drvctl.h"
 #include "ksyms.h"
 
-#include "sysmon_envsys.h"
-#include "sysmon_power.h"
 #include "sysmon_taskq.h"
-#include "sysmon_wdog.h"
 #include "veriexec.h"
 
 #include <sys/param.h>
@@ -227,10 +224,6 @@
 
 #include <dev/cons.h>
 
-#if NSYSMON_ENVSYS > 0 || NSYSMON_POWER > 0 || NSYSMON_WDOG > 0
-#include <dev/sysmon/sysmonvar.h>
-#endif
-
 #include <net/bpf.h>
 #include <net/if.h>
 #include <net/raw_cb.h>
@@ -467,23 +460,16 @@
        /* Initialize kqueue. */
        kqueue_init();
 
-       /* Initialize the system monitor subsystems. */
+       /*
+        * Initialize sysmon's task queue.  It is used by at
+        * least one non-modularized component (dev/acpica)
+        * and needs to be available early, before the rest
+        * of the module(9) subsystem is ready.
+        */
 #if NSYSMON_TASKQ > 0
        sysmon_task_queue_preinit();
 #endif
 
-#if NSYSMON_ENVSYS > 0
-       sysmon_envsys_init();
-#endif
-
-#if NSYSMON_POWER > 0
-       sysmon_power_init();
-#endif
-
-#if NSYSMON_WDOG > 0
-       sysmon_wdog_init();
-#endif
-
        inittimecounter();
        ntp_init();
 



Home | Main Index | Thread Index | Old Index