Source-Changes-HG archive

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

[src/trunk]: src/sys/ddb On MP, print cpu number prior to prompt



details:   https://anonhg.NetBSD.org/src/rev/e670fb5b7c59
branches:  trunk
changeset: 482757:e670fb5b7c59
user:      sommerfeld <sommerfeld%NetBSD.org@localhost>
date:      Mon Feb 21 05:48:56 2000 +0000

description:
On MP, print cpu number prior to prompt

diffstat:

 sys/ddb/db_command.c |  12 +++++++++++-
 1 files changed, 11 insertions(+), 1 deletions(-)

diffs (33 lines):

diff -r 8a762fb408c4 -r e670fb5b7c59 sys/ddb/db_command.c
--- a/sys/ddb/db_command.c      Mon Feb 21 05:36:11 2000 +0000
+++ b/sys/ddb/db_command.c      Mon Feb 21 05:48:56 2000 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: db_command.c,v 1.33 1999/11/02 23:53:31 jdolecek Exp $ */
+/*     $NetBSD: db_command.c,v 1.34 2000/02/21 05:48:56 sommerfeld Exp $       */
 
 /* 
  * Mach Operating System
@@ -39,6 +39,13 @@
 
 #include <machine/db_machdep.h>                /* type definitions */
 
+#if defined(_KERNEL) && !defined(_LKM)
+#include "opt_multiprocessor.h"
+#endif
+#ifdef MULTIPROCESSOR
+#include <machine/cpu.h>
+#endif
+
 #include <ddb/db_lex.h>
 #include <ddb/db_output.h>
 #include <ddb/db_command.h>
@@ -480,6 +487,9 @@
                        db_printf("\n");
                db_output_line = 0;
 
+#ifdef MULTIPROCESSOR
+               db_printf("(cpu %d)", cpu_number());
+#endif
                db_printf("db> ");
                (void) db_read_line();
 



Home | Main Index | Thread Index | Old Index