Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch Remove double declaration; 'ddb_regs' is already de...
details: https://anonhg.NetBSD.org/src/rev/63531350a4d3
branches: trunk
changeset: 359498:63531350a4d3
user: maxv <maxv%NetBSD.org@localhost>
date: Tue Feb 13 06:44:13 2018 +0000
description:
Remove double declaration; 'ddb_regs' is already declared as a macro
in db_machdep.h if MULTIPROCESSOR is on, and the macro has higher
priority.
Don't declare 'ddb_regs' locally in this case, because it is misleading.
Part of PR/52964.
diffstat:
sys/arch/amd64/amd64/db_interface.c | 8 +++++---
sys/arch/i386/i386/db_interface.c | 8 +++++---
2 files changed, 10 insertions(+), 6 deletions(-)
diffs (62 lines):
diff -r 394d70e8fa19 -r 63531350a4d3 sys/arch/amd64/amd64/db_interface.c
--- a/sys/arch/amd64/amd64/db_interface.c Tue Feb 13 04:36:00 2018 +0000
+++ b/sys/arch/amd64/amd64/db_interface.c Tue Feb 13 06:44:13 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_interface.c,v 1.31 2018/02/13 04:11:28 ozaki-r Exp $ */
+/* $NetBSD: db_interface.c,v 1.32 2018/02/13 06:44:13 maxv Exp $ */
/*
* Mach Operating System
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.31 2018/02/13 04:11:28 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.32 2018/02/13 06:44:13 maxv Exp $");
#include "opt_ddb.h"
#include "opt_multiprocessor.h"
@@ -67,9 +67,11 @@
extern int trap_types;
int db_active = 0;
-db_regs_t ddb_regs; /* register state */
#ifdef MULTIPROCESSOR
+/* ddb_regs defined as a macro */
db_regs_t *ddb_regp = NULL;
+#else
+db_regs_t ddb_regs;
#endif
void db_mach_cpu (db_expr_t, bool, db_expr_t, const char *);
diff -r 394d70e8fa19 -r 63531350a4d3 sys/arch/i386/i386/db_interface.c
--- a/sys/arch/i386/i386/db_interface.c Tue Feb 13 04:36:00 2018 +0000
+++ b/sys/arch/i386/i386/db_interface.c Tue Feb 13 06:44:13 2018 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: db_interface.c,v 1.80 2018/02/13 04:11:28 ozaki-r Exp $ */
+/* $NetBSD: db_interface.c,v 1.81 2018/02/13 06:44:13 maxv Exp $ */
/*
* Mach Operating System
@@ -33,7 +33,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.80 2018/02/13 04:11:28 ozaki-r Exp $");
+__KERNEL_RCSID(0, "$NetBSD: db_interface.c,v 1.81 2018/02/13 06:44:13 maxv Exp $");
#include "opt_ddb.h"
#include "opt_multiprocessor.h"
@@ -72,9 +72,11 @@
extern int trap_types;
int db_active = 0;
-db_regs_t ddb_regs; /* register state */
#ifdef MULTIPROCESSOR
+/* ddb_regs defined as a macro */
db_regs_t *ddb_regp = NULL;
+#else
+db_regs_t ddb_regs;
#endif
void db_mach_cpu (db_expr_t, bool, db_expr_t, const char *);
Home |
Main Index |
Thread Index |
Old Index