diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2010-11-27 19:57:24 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2010-11-27 19:57:24 +0000 |
commit | 0ed7bf7b63c6099fc1205fa39502c78fba9d94c0 (patch) | |
tree | 305a037847e752d58307b5307bc7e15b5ef94c58 /sys/arch/hppa | |
parent | 5e5b8791118667f1de14d12971ebf359c1488cec (diff) |
Remove ddb single-step load and store counters. Most platforms do not
implement them, and they are of questionable usefulness.
Diffstat (limited to 'sys/arch/hppa')
-rw-r--r-- | sys/arch/hppa/hppa/trap.c | 12 | ||||
-rw-r--r-- | sys/arch/hppa/include/db_machdep.h | 14 |
2 files changed, 11 insertions, 15 deletions
diff --git a/sys/arch/hppa/hppa/trap.c b/sys/arch/hppa/hppa/trap.c index 1b202152465..afacb556abd 100644 --- a/sys/arch/hppa/hppa/trap.c +++ b/sys/arch/hppa/hppa/trap.c @@ -1,4 +1,4 @@ -/* $OpenBSD: trap.c,v 1.110 2010/07/01 05:33:32 jsing Exp $ */ +/* $OpenBSD: trap.c,v 1.111 2010/11/27 19:57:23 miod Exp $ */ /* * Copyright (c) 1998-2004 Michael Shalayeff @@ -45,13 +45,21 @@ #include <machine/autoconf.h> -#include <machine/db_machdep.h> /* XXX always needed for inst_store() */ #ifdef DDB #ifdef TRAPDEBUG #include <ddb/db_output.h> +#else +#include <machine/db_machdep.h> #endif #endif +static __inline int inst_store(u_int ins) { + return (ins & 0xf0000000) == 0x60000000 || /* st */ + (ins & 0xf4000200) == 0x24000200 || /* fst/cst */ + (ins & 0xfc000200) == 0x0c000200 || /* stby */ + (ins & 0xfc0003c0) == 0x0c0001c0; /* ldcw */ +} + int pcxs_unaligned(u_int opcode, vaddr_t va); #ifdef PTRACE void ss_clear_breakpoints(struct proc *p); diff --git a/sys/arch/hppa/include/db_machdep.h b/sys/arch/hppa/include/db_machdep.h index 90ccff8dd3b..141501fc0f6 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.15 2005/04/19 15:23:07 miod Exp $ */ +/* $OpenBSD: db_machdep.h,v 1.16 2010/11/27 19:57:23 miod Exp $ */ /* * Copyright (c) 1998-2004 Michael Shalayeff @@ -72,18 +72,6 @@ static __inline int inst_branch(u_int ins) { (ins & 0xf0000000) == 0xa0000000 || (ins & 0xf0000000) == 0x80000000; } -static __inline int inst_load(u_int ins) { - return (ins & 0xf0000000) == 0x40000000 || - (ins & 0xf4000200) == 0x24000000 || - (ins & 0xfc000200) == 0x0c000000 || - (ins & 0xfc001fc0) != 0x0c0011c0; -} -static __inline int inst_store(u_int ins) { - return (ins & 0xf0000000) == 0x60000000 || /* st */ - (ins & 0xf4000200) == 0x24000200 || /* fst/cst */ - (ins & 0xfc000200) == 0x0c000200 || /* stby */ - (ins & 0xfc0003c0) == 0x0c0001c0; /* ldcw */ -} static __inline int inst_return(u_int ins) { return (ins & 0xfc00e000) == 0xe800c000 || (ins & 0xfc000000) == 0xe0000000; |