Deleted Added
full compact
kern_module.c (40158) kern_module.c (40435)
1/*-
2 * Copyright (c) 1997 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
1/*-
2 * Copyright (c) 1997 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright

--- 9 unchanged lines hidden (view full) ---

18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $Id: kern_module.c,v 1.9 1998/10/03 11:05:45 dfr Exp $
26 * $Id: kern_module.c,v 1.10 1998/10/10 00:03:07 peter Exp $
27 */
28
29#include <sys/param.h>
30#include <sys/kernel.h>
31#include <sys/systm.h>
32#include <sys/malloc.h>
33#include <sys/sysproto.h>
34#include <sys/sysent.h>

--- 24 unchanged lines hidden (view full) ---

59
60static void
61module_init(void* arg)
62{
63 TAILQ_INIT(&modules);
64 at_shutdown(module_shutdown, 0, SHUTDOWN_POST_SYNC);
65}
66
27 */
28
29#include <sys/param.h>
30#include <sys/kernel.h>
31#include <sys/systm.h>
32#include <sys/malloc.h>
33#include <sys/sysproto.h>
34#include <sys/sysent.h>

--- 24 unchanged lines hidden (view full) ---

59
60static void
61module_init(void* arg)
62{
63 TAILQ_INIT(&modules);
64 at_shutdown(module_shutdown, 0, SHUTDOWN_POST_SYNC);
65}
66
67SYSINIT(module, SI_SUB_KLD, SI_ORDER_ANY, module_init, 0);
67SYSINIT(module, SI_SUB_KLD, SI_ORDER_FIRST, module_init, 0);
68
69static void
70module_shutdown(int arg1, void* arg2)
71{
72 module_t mod;
73
74 for (mod = TAILQ_FIRST(&modules); mod; mod = TAILQ_NEXT(mod, link))
75 MOD_EVENT(mod, MOD_SHUTDOWN);

--- 231 unchanged lines hidden ---
68
69static void
70module_shutdown(int arg1, void* arg2)
71{
72 module_t mod;
73
74 for (mod = TAILQ_FIRST(&modules); mod; mod = TAILQ_NEXT(mod, link))
75 MOD_EVENT(mod, MOD_SHUTDOWN);

--- 231 unchanged lines hidden ---