summaryrefslogtreecommitdiffstats
path: root/sys
diff options
context:
space:
mode:
authormpi <mpi@openbsd.org>2016-02-27 13:08:06 +0000
committermpi <mpi@openbsd.org>2016-02-27 13:08:06 +0000
commita1a7d5d9adf20ab1206df269192c27c4af96434b (patch)
tree42794a77fcd70ace104067a09c098b1aee2f18bd /sys
parentUntangle a mess of nested ternary operators. (diff)
downloadwireguard-openbsd-a1a7d5d9adf20ab1206df269192c27c4af96434b.tar.xz
wireguard-openbsd-a1a7d5d9adf20ab1206df269192c27c4af96434b.zip
Rename kdb_trap() into db_ktrap().
The goal is to include it in the list of functions that must not be instrumented. All ddb(8) functions should be in this list and have their names start with 'db_'. ok visa@, deraadt@
Diffstat (limited to 'sys')
-rw-r--r--sys/arch/alpha/include/db_machdep.h4
-rw-r--r--sys/arch/amd64/amd64/db_interface.c12
-rw-r--r--sys/arch/amd64/amd64/trap.c6
-rw-r--r--sys/arch/amd64/include/db_machdep.h4
-rw-r--r--sys/arch/arm/arm/db_interface.c10
-rw-r--r--sys/arch/arm/arm/fault.c6
-rw-r--r--sys/arch/arm/include/db_machdep.h4
-rw-r--r--sys/arch/hppa/hppa/db_interface.c6
-rw-r--r--sys/arch/hppa/hppa/trap.c6
-rw-r--r--sys/arch/hppa/include/db_machdep.h4
-rw-r--r--sys/arch/hppa64/hppa64/db_interface.c6
-rw-r--r--sys/arch/hppa64/hppa64/trap.c6
-rw-r--r--sys/arch/hppa64/include/db_machdep.h4
-rw-r--r--sys/arch/i386/i386/db_interface.c6
-rw-r--r--sys/arch/i386/i386/trap.c6
-rw-r--r--sys/arch/i386/include/db_machdep.h4
-rw-r--r--sys/arch/mips64/mips64/db_machdep.c6
-rw-r--r--sys/arch/mips64/mips64/trap.c8
-rw-r--r--sys/arch/sgi/sgi/ip27_machdep.c6
-rw-r--r--sys/arch/sgi/sgi/ip30_machdep.c6
-rw-r--r--sys/arch/sh/include/db_machdep.h4
-rw-r--r--sys/arch/sh/sh/db_interface.c4
-rw-r--r--sys/arch/sh/sh/trap.c6
-rw-r--r--sys/arch/sparc/include/db_machdep.h4
-rw-r--r--sys/arch/sparc/sparc/db_interface.c8
-rw-r--r--sys/arch/sparc/sparc/trap.c4
-rw-r--r--sys/arch/sparc64/include/db_machdep.h4
-rw-r--r--sys/arch/sparc64/sparc64/db_interface.c8
-rw-r--r--sys/arch/sparc64/sparc64/trap.c6
-rw-r--r--sys/arch/vax/include/db_machdep.h4
-rw-r--r--sys/arch/vax/vax/db_machdep.c4
-rw-r--r--sys/arch/vax/vax/trap.c6
32 files changed, 91 insertions, 91 deletions
diff --git a/sys/arch/alpha/include/db_machdep.h b/sys/arch/alpha/include/db_machdep.h
index 09e506a041d..d4cb38f0e33 100644
--- a/sys/arch/alpha/include/db_machdep.h
+++ b/sys/arch/alpha/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.23 2014/03/16 20:31:45 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.24 2016/02/27 13:08:06 mpi Exp $ */
/*
* Copyright (c) 1997 Niklas Hallqvist. All rights reserved.
@@ -83,7 +83,7 @@ u_long db_register_value(db_regs_t *, int);
int db_valid_breakpoint(db_addr_t);
int ddb_trap(unsigned long, unsigned long, unsigned long,
unsigned long, struct trapframe *);
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
db_addr_t next_instr_address(db_addr_t, int);
#if 1
diff --git a/sys/arch/amd64/amd64/db_interface.c b/sys/arch/amd64/amd64/db_interface.c
index 2f182fa4aa0..873b89eaf19 100644
--- a/sys/arch/amd64/amd64/db_interface.c
+++ b/sys/arch/amd64/amd64/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.23 2015/05/18 19:59:27 guenther Exp $ */
+/* $OpenBSD: db_interface.c,v 1.24 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.1 2003/04/26 18:39:27 fvdl Exp $ */
/*
@@ -80,7 +80,7 @@ long db_switch_to_cpu;
int db_active;
db_regs_t ddb_regs;
-void kdbprinttrap(int, int);
+void db_printtrap(int, int);
#ifdef MULTIPROCESSOR
void db_cpuinfo_cmd(db_expr_t, int, db_expr_t, char *);
void db_startproc_cmd(db_expr_t, int, db_expr_t, char *);
@@ -92,7 +92,7 @@ void db_ddbproc_cmd(db_expr_t, int, db_expr_t, char *);
* Print trap reason.
*/
void
-kdbprinttrap(int type, int code)
+db_printtrap(int type, int code)
{
db_printf("kernel: ");
if (type >= trap_types || type < 0)
@@ -103,10 +103,10 @@ kdbprinttrap(int type, int code)
}
/*
- * kdb_trap - field a TRACE or BPT trap
+ * db_ktrap - field a TRACE or BPT trap
*/
int
-kdb_trap(int type, int code, db_regs_t *regs)
+db_ktrap(int type, int code, db_regs_t *regs)
{
int s;
@@ -124,7 +124,7 @@ kdb_trap(int type, int code, db_regs_t *regs)
if (!db_panic)
return (0);
- kdbprinttrap(type, code);
+ db_printtrap(type, code);
if (db_recover != 0) {
db_error("Faulted in DDB; continuing...\n");
/*NOTREACHED*/
diff --git a/sys/arch/amd64/amd64/trap.c b/sys/arch/amd64/amd64/trap.c
index 210a51aee12..ae69d576cec 100644
--- a/sys/arch/amd64/amd64/trap.c
+++ b/sys/arch/amd64/amd64/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.48 2015/09/01 08:11:02 jsg Exp $ */
+/* $OpenBSD: trap.c,v 1.49 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: trap.c,v 1.2 2003/05/04 23:51:56 fvdl Exp $ */
/*-
@@ -195,7 +195,7 @@ trap(struct trapframe *frame)
}
#endif
#ifdef DDB
- if (kdb_trap(type, 0, frame))
+ if (db_ktrap(type, 0, frame))
return;
#endif
if (frame->tf_trapno < trap_types)
@@ -433,7 +433,7 @@ faultcommon:
return;
#endif
#ifdef DDB
- if (kdb_trap(type, 0, frame))
+ if (db_ktrap(type, 0, frame))
return;
#endif
#endif /* KGDB || DDB */
diff --git a/sys/arch/amd64/include/db_machdep.h b/sys/arch/amd64/include/db_machdep.h
index 67cd028cbbb..4f2a5179697 100644
--- a/sys/arch/amd64/include/db_machdep.h
+++ b/sys/arch/amd64/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.12 2014/03/16 20:31:45 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.13 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.2 2003/04/29 17:06:04 scw Exp $ */
/*
@@ -85,7 +85,7 @@ typedef long kgdb_reg_t;
/* macro for checking if a thread has used floating-point */
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
void db_machine_init(void);
int db_enter_ddb(void);
diff --git a/sys/arch/arm/arm/db_interface.c b/sys/arch/arm/arm/db_interface.c
index 82af3014759..846e8b77bb5 100644
--- a/sys/arch/arm/arm/db_interface.c
+++ b/sys/arch/arm/arm/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.9 2014/11/16 12:30:56 deraadt Exp $ */
+/* $OpenBSD: db_interface.c,v 1.10 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.34 2003/10/26 23:11:15 chris Exp $ */
/*
@@ -123,10 +123,10 @@ db_access_irq_sp(struct db_variable *vp, db_expr_t *valp, int rw)
#ifdef DDB
/*
- * kdb_trap - field a TRACE or BPT trap
+ * db_ktrap - field a TRACE or BPT trap
*/
int
-kdb_trap(int type, db_regs_t *regs)
+db_ktrap(int type, db_regs_t *regs)
{
int s;
@@ -359,10 +359,10 @@ db_trapper(u_int addr, u_int inst, trapframe_t *frame, int fault_code)
if (fault_code == 0) {
if ((inst & ~INSN_COND_MASK) == (BKPT_INST & ~INSN_COND_MASK)) {
- kdb_trap(T_BREAKPOINT, frame);
+ db_ktrap(T_BREAKPOINT, frame);
frame->tf_pc += INSN_SIZE;
} else
- kdb_trap(-1, frame);
+ db_ktrap(-1, frame);
} else
return (1);
return (0);
diff --git a/sys/arch/arm/arm/fault.c b/sys/arch/arm/arm/fault.c
index de7bf69966c..d90877b81c9 100644
--- a/sys/arch/arm/arm/fault.c
+++ b/sys/arch/arm/arm/fault.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: fault.c,v 1.19 2016/01/31 00:14:50 jsg Exp $ */
+/* $OpenBSD: fault.c,v 1.20 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: fault.c,v 1.46 2004/01/21 15:39:21 skrll Exp $ */
/*
@@ -100,7 +100,7 @@
#include <sys/kgdb.h>
#endif
#if !defined(DDB)
-#define kdb_trap kgdb_trap
+#define db_ktrap kgdb_trap
#endif
#endif
@@ -496,7 +496,7 @@ dab_fatal(trapframe_t *tf, u_int fsr, u_int far, struct proc *p,
printf(", pc =%08lx\n\n", tf->tf_pc);
#if defined(DDB) || defined(KGDB)
- kdb_trap(T_FAULT, tf);
+ db_ktrap(T_FAULT, tf);
#endif
panic("Fatal abort");
/*NOTREACHED*/
diff --git a/sys/arch/arm/include/db_machdep.h b/sys/arch/arm/include/db_machdep.h
index e0f419cf680..c4b9272eb44 100644
--- a/sys/arch/arm/include/db_machdep.h
+++ b/sys/arch/arm/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.9 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.10 2016/02/27 13:08:06 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.5 2001/11/22 18:00:00 thorpej Exp $ */
/*
@@ -95,7 +95,7 @@ extern db_regs_t ddb_regs; /* register state */
#define SOFTWARE_SSTEP
db_addr_t db_branch_taken(u_int inst, db_addr_t pc, db_regs_t *regs);
-int kdb_trap (int, db_regs_t *);
+int db_ktrap (int, db_regs_t *);
void db_machine_init (void);
#define branch_taken(ins, pc, fun, regs) \
diff --git a/sys/arch/hppa/hppa/db_interface.c b/sys/arch/hppa/hppa/db_interface.c
index 4276a9a1c3b..8270fe61c1b 100644
--- a/sys/arch/hppa/hppa/db_interface.c
+++ b/sys/arch/hppa/hppa/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.35 2014/07/13 12:11:01 jasper Exp $ */
+/* $OpenBSD: db_interface.c,v 1.36 2016/02/27 13:08:06 mpi Exp $ */
/*
* Copyright (c) 1999-2003 Michael Shalayeff
@@ -179,10 +179,10 @@ kdbprinttrap(type, code)
}
/*
- * kdb_trap - field a BPT trap
+ * db_ktrap - field a BPT trap
*/
int
-kdb_trap(type, code, regs)
+db_ktrap(type, code, regs)
int type, code;
db_regs_t *regs;
{
diff --git a/sys/arch/hppa/hppa/trap.c b/sys/arch/hppa/hppa/trap.c
index 900f6c69542..e86e636531d 100644
--- a/sys/arch/hppa/hppa/trap.c
+++ b/sys/arch/hppa/hppa/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.138 2014/11/16 12:30:57 deraadt Exp $ */
+/* $OpenBSD: trap.c,v 1.139 2016/02/27 13:08:06 mpi Exp $ */
/*
* Copyright (c) 1998-2004 Michael Shalayeff
@@ -245,7 +245,7 @@ trap(int type, struct trapframe *frame)
case T_DBREAK:
dead_end:
#ifdef DDB
- if (kdb_trap(type, va, frame)) {
+ if (db_ktrap(type, va, frame)) {
if (type == T_IBREAK) {
/* skip break instruction */
frame->tf_iioq_head = frame->tf_iioq_tail;
@@ -620,7 +620,7 @@ datalign_user:
/* FALLTHROUGH to unimplemented */
default:
#ifdef TRAPDEBUG
- if (kdb_trap(type, va, frame))
+ if (db_ktrap(type, va, frame))
return;
#endif
panic("trap: unimplemented \'%s\' (%d)", tts, trapnum);
diff --git a/sys/arch/hppa/include/db_machdep.h b/sys/arch/hppa/include/db_machdep.h
index d844b6c6a1c..d787c99829e 100644
--- a/sys/arch/hppa/include/db_machdep.h
+++ b/sys/arch/hppa/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.18 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.19 2016/02/27 13:08:06 mpi Exp $ */
/*
* Copyright (c) 1998-2005 Michael Shalayeff
@@ -89,6 +89,6 @@ branch_taken1(int ins, db_addr_t pc, db_regs_t *regs) {
#endif
int db_valid_breakpoint(db_addr_t);
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
#endif /* _MACHINE_DB_MACHDEP_H_ */
diff --git a/sys/arch/hppa64/hppa64/db_interface.c b/sys/arch/hppa64/hppa64/db_interface.c
index 4aa012b103d..e5be7659710 100644
--- a/sys/arch/hppa64/hppa64/db_interface.c
+++ b/sys/arch/hppa64/hppa64/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.4 2014/07/13 12:11:01 jasper Exp $ */
+/* $OpenBSD: db_interface.c,v 1.5 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -156,10 +156,10 @@ kdbprinttrap(int type, int code)
}
/*
- * kdb_trap - field a BPT trap
+ * db_ktrap - field a BPT trap
*/
int
-kdb_trap(int type, int code, db_regs_t *regs)
+db_ktrap(int type, int code, db_regs_t *regs)
{
extern label_t *db_recover;
int s;
diff --git a/sys/arch/hppa64/hppa64/trap.c b/sys/arch/hppa64/hppa64/trap.c
index 0d006a8ccd7..4fc9fcedca6 100644
--- a/sys/arch/hppa64/hppa64/trap.c
+++ b/sys/arch/hppa64/hppa64/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.41 2014/11/16 12:30:57 deraadt Exp $ */
+/* $OpenBSD: trap.c,v 1.42 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 2005 Michael Shalayeff
@@ -240,7 +240,7 @@ trap(int type, struct trapframe *frame)
case T_DBREAK:
dead_end:
#ifdef DDB
- if (kdb_trap (type, va, frame)) {
+ if (db_ktrap (type, va, frame)) {
if (type == T_IBREAK) {
/* skip break instruction */
frame->tf_iioq[0] = frame->tf_iioq[1];
@@ -505,7 +505,7 @@ trap(int type, struct trapframe *frame)
/* FALLTHROUGH to unimplemented */
default:
#ifdef TRAPDEBUG
- if (kdb_trap(type, va, frame))
+ if (db_ktrap(type, va, frame))
return;
#endif
panic("trap: unimplemented \'%s\' (%d)", tts, trapnum);
diff --git a/sys/arch/hppa64/include/db_machdep.h b/sys/arch/hppa64/include/db_machdep.h
index 9ef14b72ae7..ba4e7566b95 100644
--- a/sys/arch/hppa64/include/db_machdep.h
+++ b/sys/arch/hppa64/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.4 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.5 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 1998-2005 Michael Shalayeff
@@ -87,6 +87,6 @@ branch_taken1(int ins, db_addr_t pc, db_regs_t *regs) {
#endif
int db_valid_breakpoint(db_addr_t);
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
#endif /* _MACHINE_DB_MACHDEP_H_ */
diff --git a/sys/arch/i386/i386/db_interface.c b/sys/arch/i386/i386/db_interface.c
index 13cd5be101d..19694f7af76 100644
--- a/sys/arch/i386/i386/db_interface.c
+++ b/sys/arch/i386/i386/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.31 2014/09/14 14:17:23 jsg Exp $ */
+/* $OpenBSD: db_interface.c,v 1.32 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.22 1996/05/03 19:42:00 christos Exp $ */
/*
@@ -98,10 +98,10 @@ kdbprinttrap(int type, int code)
}
/*
- * kdb_trap - field a TRACE or BPT trap
+ * db_ktrap - field a TRACE or BPT trap
*/
int
-kdb_trap(int type, int code, db_regs_t *regs)
+db_ktrap(int type, int code, db_regs_t *regs)
{
int s;
diff --git a/sys/arch/i386/i386/trap.c b/sys/arch/i386/i386/trap.c
index 55f45f87a59..cae218755eb 100644
--- a/sys/arch/i386/i386/trap.c
+++ b/sys/arch/i386/i386/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.123 2015/06/28 01:11:27 guenther Exp $ */
+/* $OpenBSD: trap.c,v 1.124 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: trap.c,v 1.95 1996/05/05 06:50:02 mycroft Exp $ */
/*-
@@ -186,7 +186,7 @@ trap(struct trapframe *frame)
#endif
#ifdef DDB
- if (kdb_trap(type, 0, frame))
+ if (db_ktrap(type, 0, frame))
return;
#endif
if (frame->tf_trapno < trap_types)
@@ -498,7 +498,7 @@ trap(struct trapframe *frame)
return;
#endif
#ifdef DDB
- if (kdb_trap(type, 0, frame))
+ if (db_ktrap(type, 0, frame))
return;
#endif
#endif /* DDB || KGDB */
diff --git a/sys/arch/i386/include/db_machdep.h b/sys/arch/i386/include/db_machdep.h
index 537eea6baf8..77ca36b80c9 100644
--- a/sys/arch/i386/include/db_machdep.h
+++ b/sys/arch/i386/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.23 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.24 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.9 1996/05/03 19:23:59 christos Exp $ */
/*
@@ -84,7 +84,7 @@ typedef long kgdb_reg_t;
/* macro for checking if a thread has used floating-point */
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
void db_machine_init(void);
int db_enter_ddb(void);
diff --git a/sys/arch/mips64/mips64/db_machdep.c b/sys/arch/mips64/mips64/db_machdep.c
index 42132e64b90..4fe9e81d607 100644
--- a/sys/arch/mips64/mips64/db_machdep.c
+++ b/sys/arch/mips64/mips64/db_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.c,v 1.43 2015/02/08 00:30:20 uebayasi Exp $ */
+/* $OpenBSD: db_machdep.c,v 1.44 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 1998-2003 Opsycon AB (www.opsycon.se)
@@ -62,7 +62,7 @@ void kdbpoke(vaddr_t, uint32_t);
void kdbpoked(vaddr_t, uint64_t);
void kdbpokew(vaddr_t, uint16_t);
void kdbpokeb(vaddr_t, uint8_t);
-int kdb_trap(int, struct trap_frame *);
+int db_ktrap(int, struct trap_frame *);
void db_print_tlb(uint, uint64_t);
void db_trap_trace_cmd(db_expr_t, int, db_expr_t, char *);
@@ -130,7 +130,7 @@ struct db_variable *db_eregs = db_regs + nitems(db_regs);
extern label_t *db_recover;
int
-kdb_trap(int type, struct trap_frame *fp)
+db_ktrap(int type, struct trap_frame *fp)
{
switch(type) {
case T_BREAK: /* breakpoint */
diff --git a/sys/arch/mips64/mips64/trap.c b/sys/arch/mips64/mips64/trap.c
index 7e597200eb5..09ca845c412 100644
--- a/sys/arch/mips64/mips64/trap.c
+++ b/sys/arch/mips64/mips64/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.113 2016/02/01 16:15:18 visa Exp $ */
+/* $OpenBSD: trap.c,v 1.114 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 1988 University of Utah.
@@ -127,7 +127,7 @@ uint64_t kdbpeekd(vaddr_t);
#endif /* DDB || DEBUG */
#if defined(DDB)
-extern int kdb_trap(int, db_regs_t *);
+extern int db_ktrap(int, db_regs_t *);
#endif
void ast(void);
@@ -537,7 +537,7 @@ fault_common_no_miss:
case T_BREAK:
#ifdef DDB
- kdb_trap(type, trapframe);
+ db_ktrap(type, trapframe);
#endif
/* Reenable interrupts if necessary */
if (trapframe->sr & SR_INT_ENAB) {
@@ -788,7 +788,7 @@ fault_common_no_miss:
(void *)trapframe->badvaddr);
#ifdef DDB
stacktrace(!USERMODE(trapframe->sr) ? trapframe : p->p_md.md_regs);
- kdb_trap(type, trapframe);
+ db_ktrap(type, trapframe);
#endif
panic("trap");
}
diff --git a/sys/arch/sgi/sgi/ip27_machdep.c b/sys/arch/sgi/sgi/ip27_machdep.c
index 8d3020910d3..7d12e12970a 100644
--- a/sys/arch/sgi/sgi/ip27_machdep.c
+++ b/sys/arch/sgi/sgi/ip27_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip27_machdep.c,v 1.71 2016/01/02 05:49:36 visa Exp $ */
+/* $OpenBSD: ip27_machdep.c,v 1.72 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 2008, 2009 Miodrag Vallat.
@@ -1019,7 +1019,7 @@ ip27_nmi(void *arg)
vaddr_t regs_offs;
register_t *regs, epc;
struct trap_frame nmi_frame;
- extern int kdb_trap(int, struct trap_frame *);
+ extern int db_ktrap(int, struct trap_frame *);
/*
* Build a ddb frame from the registers saved in the NMI KREGS
@@ -1050,7 +1050,7 @@ ip27_nmi(void *arg)
(void *)nmi_frame.pc, (void *)nmi_frame.ra, nmi_frame.sr,
(void *)epc);
#ifdef DDB
- (void)kdb_trap(-1, &nmi_frame);
+ (void)db_ktrap(-1, &nmi_frame);
#endif
panic("NMI");
/* NOTREACHED */
diff --git a/sys/arch/sgi/sgi/ip30_machdep.c b/sys/arch/sgi/sgi/ip30_machdep.c
index 14facb69c41..cb77373213a 100644
--- a/sys/arch/sgi/sgi/ip30_machdep.c
+++ b/sys/arch/sgi/sgi/ip30_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: ip30_machdep.c,v 1.63 2014/12/06 23:20:17 krw Exp $ */
+/* $OpenBSD: ip30_machdep.c,v 1.64 2016/02/27 13:08:07 mpi Exp $ */
/*
* Copyright (c) 2008, 2009 Miodrag Vallat.
@@ -436,7 +436,7 @@ ip30_get_ncpusfound(void)
void
ip30_nmi_handler()
{
- extern int kdb_trap(int, struct trap_frame *);
+ extern int db_ktrap(int, struct trap_frame *);
extern void stacktrace(struct trap_frame *);
struct trap_frame *fr0;
int s;
@@ -474,7 +474,7 @@ ip30_nmi_handler()
stacktrace(fr1);
#endif
- kdb_trap(-1, fr0);
+ db_ktrap(-1, fr0);
splx(s);
panic("NMI");
diff --git a/sys/arch/sh/include/db_machdep.h b/sys/arch/sh/include/db_machdep.h
index 60f8d39e80a..f8aed1ace73 100644
--- a/sys/arch/sh/include/db_machdep.h
+++ b/sys/arch/sh/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.6 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.7 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.12 2006/05/10 06:24:03 skrll Exp $ */
/*
@@ -57,7 +57,7 @@ extern db_regs_t ddb_regs; /* register state */
#define IS_BREAKPOINT_TRAP(type, code) ((type) == EXPEVT_TRAPA)
#define IS_WATCHPOINT_TRAP(type, code) (0) /* XXX (msaitoh) */
-int kdb_trap(int, int, db_regs_t *);
+int db_ktrap(int, int, db_regs_t *);
void db_machine_init (void);
boolean_t inst_call(int);
boolean_t inst_return(int);
diff --git a/sys/arch/sh/sh/db_interface.c b/sys/arch/sh/sh/db_interface.c
index 116f31f6240..0a16ef3cb95 100644
--- a/sys/arch/sh/sh/db_interface.c
+++ b/sys/arch/sh/sh/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.5 2014/12/03 20:09:32 krw Exp $ */
+/* $OpenBSD: db_interface.c,v 1.6 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.37 2006/09/06 00:11:49 uwe Exp $ */
/*-
@@ -108,7 +108,7 @@ kdb_printtrap(u_int type, int code)
}
int
-kdb_trap(int type, int code, db_regs_t *regs)
+db_ktrap(int type, int code, db_regs_t *regs)
{
extern label_t *db_recover;
int s;
diff --git a/sys/arch/sh/sh/trap.c b/sys/arch/sh/sh/trap.c
index 649b1bbb0e8..5d468051b2f 100644
--- a/sys/arch/sh/sh/trap.c
+++ b/sys/arch/sh/sh/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.34 2015/09/10 17:32:19 miod Exp $ */
+/* $OpenBSD: trap.c,v 1.35 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: exception.c,v 1.32 2006/09/04 23:57:52 uwe Exp $ */
/* $NetBSD: syscall.c,v 1.6 2006/03/07 07:21:50 thorpej Exp $ */
@@ -178,7 +178,7 @@ general_exception(struct proc *p, struct trapframe *tf, uint32_t va)
switch (expevt) {
case EXPEVT_BREAK:
#ifdef DDB
- if (kdb_trap(EXPEVT_BREAK, 0, tf))
+ if (db_ktrap(EXPEVT_BREAK, 0, tf))
return;
else
#endif
@@ -189,7 +189,7 @@ general_exception(struct proc *p, struct trapframe *tf, uint32_t va)
/* Check for ddb request */
tra = _reg_read_4(SH_(TRA));
if (tra == (_SH_TRA_BREAK << 2) &&
- kdb_trap(expevt, tra, tf))
+ db_ktrap(expevt, tra, tf))
return;
else
#endif
diff --git a/sys/arch/sparc/include/db_machdep.h b/sys/arch/sparc/include/db_machdep.h
index 77dcf3978af..b8c504d54a8 100644
--- a/sys/arch/sparc/include/db_machdep.h
+++ b/sys/arch/sparc/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.16 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.17 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.10 1997/08/31 21:23:40 pk Exp $ */
/*
@@ -82,7 +82,7 @@ extern db_regs_t ddb_regs; /* register state */
#define DB_MACHINE_COMMANDS
void db_machine_init(void);
-int kdb_trap(int, struct trapframe *);
+int db_ktrap(int, struct trapframe *);
/*
* KGDB definitions
diff --git a/sys/arch/sparc/sparc/db_interface.c b/sys/arch/sparc/sparc/db_interface.c
index 30c40a8d8aa..a9063ee5a69 100644
--- a/sys/arch/sparc/sparc/db_interface.c
+++ b/sys/arch/sparc/sparc/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.15 2015/03/18 20:49:10 miod Exp $ */
+/* $OpenBSD: db_interface.c,v 1.16 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.18 1997/09/01 00:16:31 pk Exp $ */
/*
@@ -173,15 +173,15 @@ kdb_kbd_trap(tf)
{
if (db_active == 0 && (boothowto & RB_KDB)) {
printf("\n\nkernel: keyboard interrupt\n");
- kdb_trap(-1, tf);
+ db_ktrap(-1, tf);
}
}
/*
- * kdb_trap - field a TRACE or BPT trap
+ * db_ktrap - field a TRACE or BPT trap
*/
int
-kdb_trap(type, tf)
+db_ktrap(type, tf)
int type;
struct trapframe *tf;
{
diff --git a/sys/arch/sparc/sparc/trap.c b/sys/arch/sparc/sparc/trap.c
index 5109698c0b4..00324fa88dc 100644
--- a/sys/arch/sparc/sparc/trap.c
+++ b/sys/arch/sparc/sparc/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.72 2015/11/06 06:33:26 guenther Exp $ */
+/* $OpenBSD: trap.c,v 1.73 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: trap.c,v 1.58 1997/09/12 08:55:01 pk Exp $ */
/*
@@ -244,7 +244,7 @@ trap(type, psr, pc, tf)
#ifdef DDB
if (type == T_BREAKPOINT) {
write_all_windows();
- if (kdb_trap(type, tf)) {
+ if (db_ktrap(type, tf)) {
return;
}
}
diff --git a/sys/arch/sparc64/include/db_machdep.h b/sys/arch/sparc64/include/db_machdep.h
index 8985fd287f2..96398636d09 100644
--- a/sys/arch/sparc64/include/db_machdep.h
+++ b/sys/arch/sparc64/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.15 2015/08/28 23:28:39 kettenis Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.16 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.12 2001/07/07 15:16:13 eeh Exp $ */
/*
@@ -132,7 +132,7 @@ void db_machine_init(void);
#define DB_MACHINE_COMMANDS
void db_machine_init(void);
-int kdb_trap(int, struct trapframe64 *);
+int db_ktrap(int, struct trapframe64 *);
int db_enter_ddb(void);
void db_startcpu(struct cpu_info *);
diff --git a/sys/arch/sparc64/sparc64/db_interface.c b/sys/arch/sparc64/sparc64/db_interface.c
index 250c64a9ada..2ff4a2a9632 100644
--- a/sys/arch/sparc64/sparc64/db_interface.c
+++ b/sys/arch/sparc64/sparc64/db_interface.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_interface.c,v 1.39 2015/08/28 23:28:39 kettenis Exp $ */
+/* $OpenBSD: db_interface.c,v 1.40 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_interface.c,v 1.61 2001/07/31 06:55:47 eeh Exp $ */
/*
@@ -256,15 +256,15 @@ kdb_kbd_trap(tf)
{
if (db_active == 0 /* && (boothowto & RB_KDB) */) {
printf("\n\nkernel: keyboard interrupt tf=%p\n", tf);
- kdb_trap(-1, tf);
+ db_ktrap(-1, tf);
}
}
/*
- * kdb_trap - field a TRACE or BPT trap
+ * db_ktrap - field a TRACE or BPT trap
*/
int
-kdb_trap(type, tf)
+db_ktrap(type, tf)
int type;
register struct trapframe64 *tf;
{
diff --git a/sys/arch/sparc64/sparc64/trap.c b/sys/arch/sparc64/sparc64/trap.c
index adc0aa89617..ec524140c70 100644
--- a/sys/arch/sparc64/sparc64/trap.c
+++ b/sys/arch/sparc64/sparc64/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.87 2015/11/06 06:33:26 guenther Exp $ */
+/* $OpenBSD: trap.c,v 1.88 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: trap.c,v 1.73 2001/08/09 01:03:01 eeh Exp $ */
/*
@@ -371,13 +371,13 @@ trap(tf, type, pc, tstate)
#ifdef DDB
if (type == T_BREAKPOINT) {
write_all_windows();
- if (kdb_trap(type, tf)) {
+ if (db_ktrap(type, tf)) {
/* ADVANCE; */
return;
}
}
if (type == T_PA_WATCHPT || type == T_VA_WATCHPT) {
- if (kdb_trap(type, tf)) {
+ if (db_ktrap(type, tf)) {
/* DDB must turn off watchpoints or something */
return;
}
diff --git a/sys/arch/vax/include/db_machdep.h b/sys/arch/vax/include/db_machdep.h
index e74db7a7636..c0f28516f16 100644
--- a/sys/arch/vax/include/db_machdep.h
+++ b/sys/arch/vax/include/db_machdep.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.h,v 1.17 2014/03/16 20:31:46 guenther Exp $ */
+/* $OpenBSD: db_machdep.h,v 1.18 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.h,v 1.6 1998/08/10 14:33:33 ragge Exp $ */
/*
@@ -71,6 +71,6 @@ extern db_regs_t ddb_regs; /* register state */
#define inst_call(ins) (((ins)&0xff) == I_CALL)
/* Prototypes */
-void kdb_trap(struct trapframe *);
+void db_ktrap(struct trapframe *);
#endif /* _MACHINE_DB_MACHDEP_H_ */
diff --git a/sys/arch/vax/vax/db_machdep.c b/sys/arch/vax/vax/db_machdep.c
index cecb4323e1e..9b2cbdb6a2b 100644
--- a/sys/arch/vax/vax/db_machdep.c
+++ b/sys/arch/vax/vax/db_machdep.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: db_machdep.c,v 1.19 2014/07/13 12:11:01 jasper Exp $ */
+/* $OpenBSD: db_machdep.c,v 1.20 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: db_machdep.c,v 1.17 1999/06/20 00:58:23 ragge Exp $ */
/*
@@ -98,7 +98,7 @@ typedef struct __vax_frame {
* contain the registers when panic was called. (easy to debug).
*/
void
-kdb_trap(frame)
+db_ktrap(frame)
struct trapframe *frame;
{
int s;
diff --git a/sys/arch/vax/vax/trap.c b/sys/arch/vax/vax/trap.c
index eee24ded679..f24fb399cc0 100644
--- a/sys/arch/vax/vax/trap.c
+++ b/sys/arch/vax/vax/trap.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: trap.c,v 1.56 2015/09/13 12:30:52 miod Exp $ */
+/* $OpenBSD: trap.c,v 1.57 2016/02/27 13:08:07 mpi Exp $ */
/* $NetBSD: trap.c,v 1.47 1999/08/21 19:26:20 matt Exp $ */
/*
* Copyright (c) 1994 Ludd, University of Lule}, Sweden.
@@ -126,7 +126,7 @@ fram:
default:
#ifdef DDB
- kdb_trap(frame);
+ db_ktrap(frame);
#endif
printf("Trap: type %x, code %x, pc %x, psl %x\n",
(u_int)frame->trap, (u_int)frame->code,
@@ -262,7 +262,7 @@ if(faultdebug)printf("trap accflt type %lx, code %lx, pc %lx, psl %lx\n",
case T_KDBTRAP:
case T_KDBTRAP|T_USER:
case T_TRCTRAP:
- kdb_trap(frame);
+ db_ktrap(frame);
return;
#endif
}