Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/powerpc/include Add illegal asm and breakpoint
details: https://anonhg.NetBSD.org/src/rev/7203dd015a36
branches: trunk
changeset: 465573:7203dd015a36
user: martin <martin%NetBSD.org@localhost>
date: Fri Nov 29 12:04:32 2019 +0000
description:
Add illegal asm and breakpoint
diffstat:
sys/arch/powerpc/include/ptrace.h | 8 +++++++-
1 files changed, 7 insertions(+), 1 deletions(-)
diffs (20 lines):
diff -r 5264d5640759 -r 7203dd015a36 sys/arch/powerpc/include/ptrace.h
--- a/sys/arch/powerpc/include/ptrace.h Fri Nov 29 08:30:30 2019 +0000
+++ b/sys/arch/powerpc/include/ptrace.h Fri Nov 29 12:04:32 2019 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: ptrace.h,v 1.14 2019/06/18 21:18:12 kamil Exp $ */
+/* $NetBSD: ptrace.h,v 1.15 2019/11/29 12:04:32 martin Exp $ */
#ifndef _POWERPC_PTRACE_H
#define _POWERPC_PTRACE_H
@@ -71,4 +71,10 @@
#endif /* ALTIVEC || PPC_HAVE_SPE */
#endif /* _KERNEL */
+#define PTRACE_ILLEGAL_ASM __asm __volatile (".long 0" : : : "memory")
+
+#define PTRACE_BREAKPOINT ((const uint8_t[]) { 0x7f, 0xe0, 0x00, 0x08 })
+#define PTRACE_BREAKPOINT_ASM __asm __volatile("trap")
+#define PTRACE_BREAKPOINT_SIZE 4
+
#endif /* _POWERPC_PTRACE_H */
Home |
Main Index |
Thread Index |
Old Index