Source-Changes-HG archive

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

[src/trunk]: src/sys/kern in the !MP world, ci->ci_curlwp may not exist. jus...



details:   https://anonhg.NetBSD.org/src/rev/dcadc87affb7
branches:  trunk
changeset: 445363:dcadc87affb7
user:      mrg <mrg%NetBSD.org@localhost>
date:      Thu Oct 25 09:30:45 2018 +0000

description:
in the !MP world, ci->ci_curlwp may not exist.  just use curlwp.

XXX: can we just do this for MP builds, too?  i think so.

diffstat:

 sys/kern/subr_lockdebug.c |  8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diffs (30 lines):

diff -r fd0e7a410c8f -r dcadc87affb7 sys/kern/subr_lockdebug.c
--- a/sys/kern/subr_lockdebug.c Thu Oct 25 07:13:55 2018 +0000
+++ b/sys/kern/subr_lockdebug.c Thu Oct 25 09:30:45 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: subr_lockdebug.c,v 1.67 2018/09/13 01:55:16 mrg Exp $  */
+/*     $NetBSD: subr_lockdebug.c,v 1.68 2018/10/25 09:30:45 mrg Exp $  */
 
 /*-
  * Copyright (c) 2006, 2007, 2008 The NetBSD Foundation, Inc.
@@ -34,7 +34,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: subr_lockdebug.c,v 1.67 2018/09/13 01:55:16 mrg Exp $");
+__KERNEL_RCSID(0, "$NetBSD: subr_lockdebug.c,v 1.68 2018/10/25 09:30:45 mrg Exp $");
 
 #ifdef _KERNEL_OPT
 #include "opt_ddb.h"
@@ -898,7 +898,11 @@
                        lockdebug_dump(ld, pr);
                        if (show_trace) {
                                db_stack_trace_print(
+#ifdef MULTIPROCESSOR
                                    (db_expr_t)(intptr_t)ci->ci_curlwp,
+#else
+                                   (db_expr_t)(intptr_t)curlwp,
+#endif
                                    true,
                                    32 /* Limit just in case */,
                                    "a", pr);



Home | Main Index | Thread Index | Old Index