Source-Changes-HG archive

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

[src/trunk]: src/sys sys/*: Get module_map consistently from sys/module.h.



details:   https://anonhg.NetBSD.org/src/rev/d48690e2da7d
branches:  trunk
changeset: 372058:d48690e2da7d
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Wed Oct 26 23:22:07 2022 +0000

description:
sys/*: Get module_map consistently from sys/module.h.

diffstat:

 sys/arch/amd64/amd64/machdep.c |  6 +++---
 sys/kern/kern_module.c         |  5 ++---
 sys/kern/subr_kobj.c           |  6 ++----
 sys/rump/librump/rumpkern/vm.c |  6 +++---
 4 files changed, 10 insertions(+), 13 deletions(-)

diffs (121 lines):

diff -r 2beb376bf4bf -r d48690e2da7d sys/arch/amd64/amd64/machdep.c
--- a/sys/arch/amd64/amd64/machdep.c    Wed Oct 26 23:21:19 2022 +0000
+++ b/sys/arch/amd64/amd64/machdep.c    Wed Oct 26 23:22:07 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: machdep.c,v 1.363 2022/08/20 23:48:50 riastradh Exp $  */
+/*     $NetBSD: machdep.c,v 1.364 2022/10/26 23:22:07 riastradh Exp $  */
 
 /*
  * Copyright (c) 1996, 1997, 1998, 2000, 2006, 2007, 2008, 2011
@@ -110,7 +110,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.363 2022/08/20 23:48:50 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: machdep.c,v 1.364 2022/10/26 23:22:07 riastradh Exp $");
 
 #include "opt_modular.h"
 #include "opt_user_ldt.h"
@@ -153,6 +153,7 @@
 #include <sys/asan.h>
 #include <sys/csan.h>
 #include <sys/msan.h>
+#include <sys/module.h>
 
 #ifdef KGDB
 #include <sys/kgdb.h>
@@ -268,7 +269,6 @@
 paddr_t ldt_paddr;
 
 static struct vm_map module_map_store;
-extern struct vm_map *module_map;
 extern struct bootspace bootspace;
 extern struct slotspace slotspace;
 
diff -r 2beb376bf4bf -r d48690e2da7d sys/kern/kern_module.c
--- a/sys/kern/kern_module.c    Wed Oct 26 23:21:19 2022 +0000
+++ b/sys/kern/kern_module.c    Wed Oct 26 23:22:07 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kern_module.c,v 1.159 2022/09/06 13:31:09 pgoyette Exp $       */
+/*     $NetBSD: kern_module.c,v 1.160 2022/10/26 23:22:07 riastradh Exp $      */
 
 /*-
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.159 2022/09/06 13:31:09 pgoyette Exp $");
+__KERNEL_RCSID(0, "$NetBSD: kern_module.c,v 1.160 2022/10/26 23:22:07 riastradh Exp $");
 
 #define _MODULE_INTERNAL
 
@@ -411,7 +411,6 @@
 module_init(void)
 {
        __link_set_decl(modules, modinfo_t);
-       extern struct vm_map *module_map;
        modinfo_t *const *mip;
        int rv;
 
diff -r 2beb376bf4bf -r d48690e2da7d sys/kern/subr_kobj.c
--- a/sys/kern/subr_kobj.c      Wed Oct 26 23:21:19 2022 +0000
+++ b/sys/kern/subr_kobj.c      Wed Oct 26 23:22:07 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: subr_kobj.c,v 1.73 2022/10/15 15:28:23 riastradh Exp $ */
+/*     $NetBSD: subr_kobj.c,v 1.74 2022/10/26 23:22:07 riastradh Exp $ */
 
 /*
  * Copyright (c) 2008 The NetBSD Foundation, Inc.
@@ -63,7 +63,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_kobj.c,v 1.73 2022/10/15 15:28:23 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_kobj.c,v 1.74 2022/10/26 23:22:07 riastradh Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_modular.h"
@@ -95,8 +95,6 @@
 static int     kobj_read_mem(kobj_t, void **, size_t, off_t, bool);
 static void    kobj_close_mem(kobj_t);
 
-extern struct vm_map *module_map;
-
 /*
  * kobj_load_mem:
  *
diff -r 2beb376bf4bf -r d48690e2da7d sys/rump/librump/rumpkern/vm.c
--- a/sys/rump/librump/rumpkern/vm.c    Wed Oct 26 23:21:19 2022 +0000
+++ b/sys/rump/librump/rumpkern/vm.c    Wed Oct 26 23:22:07 2022 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: vm.c,v 1.193 2022/08/21 10:18:20 riastradh Exp $       */
+/*     $NetBSD: vm.c,v 1.194 2022/10/26 23:22:07 riastradh Exp $       */
 
 /*
  * Copyright (c) 2007-2011 Antti Kantee.  All Rights Reserved.
@@ -41,7 +41,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.193 2022/08/21 10:18:20 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: vm.c,v 1.194 2022/10/26 23:22:07 riastradh Exp $");
 
 #include <sys/param.h>
 #include <sys/atomic.h>
@@ -53,6 +53,7 @@
 #include <sys/null.h>
 #include <sys/vnode.h>
 #include <sys/radixtree.h>
+#include <sys/module.h>
 
 #include <machine/pmap.h>
 
@@ -97,7 +98,6 @@
 struct vm_map *kernel_map = &kernel_map_store;
 
 static struct vm_map module_map_store;
-extern struct vm_map *module_map;
 
 static struct pmap pmap_kernel;
 struct pmap rump_pmap_local;



Home | Main Index | Thread Index | Old Index