Source-Changes-HG archive

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

[src/trunk]: src/sys/sys expose the KSTACK_LOWEST_ADDR and KSTACK_SIZE to _KM...



details:   https://anonhg.NetBSD.org/src/rev/27ff4752d73c
branches:  trunk
changeset: 764176:27ff4752d73c
user:      mrg <mrg%NetBSD.org@localhost>
date:      Wed Apr 13 08:45:00 2011 +0000

description:
expose the KSTACK_LOWEST_ADDR and KSTACK_SIZE to _KMEMUSER as well,
like the x86 versions do.  for crash(8).

diffstat:

 sys/sys/proc.h |  27 ++++++++++++++++-----------
 1 files changed, 16 insertions(+), 11 deletions(-)

diffs (47 lines):

diff -r f09c30042207 -r 27ff4752d73c sys/sys/proc.h
--- a/sys/sys/proc.h    Wed Apr 13 07:12:52 2011 +0000
+++ b/sys/sys/proc.h    Wed Apr 13 08:45:00 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: proc.h,v 1.302 2011/03/08 12:39:29 pooka Exp $ */
+/*     $NetBSD: proc.h,v 1.303 2011/04/13 08:45:00 mrg Exp $   */
 
 /*-
  * Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -534,6 +534,20 @@
 #define        tsleep(chan, pri, wmesg, timo)                                  \
        ltsleep(chan, pri, wmesg, timo, NULL)
 
+#ifdef KSTACK_CHECK_MAGIC
+void   kstack_setup_magic(const struct lwp *);
+void   kstack_check_magic(const struct lwp *);
+#else
+#define        kstack_setup_magic(x)
+#define        kstack_check_magic(x)
+#endif
+
+extern struct emul emul_netbsd;
+
+#endif /* _KERNEL */
+
+#if defined(_KMEMUSER) || defined(_KERNEL)
+
 /*
  * Kernel stack parameters.
  *
@@ -551,15 +565,6 @@
 #define        KSTACK_SIZE             (USPACE - ALIGN(sizeof(struct pcb)))
 #endif
 
-#ifdef KSTACK_CHECK_MAGIC
-void   kstack_setup_magic(const struct lwp *);
-void   kstack_check_magic(const struct lwp *);
-#else
-#define        kstack_setup_magic(x)
-#define        kstack_check_magic(x)
-#endif
+#endif /* _KMEMUSER || _KERNEL */
 
-extern struct emul emul_netbsd;
-
-#endif /* _KERNEL */
 #endif /* !_SYS_PROC_H_ */



Home | Main Index | Thread Index | Old Index