summaryrefslogtreecommitdiffstats
path: root/arch/ppc64/kernel/ptrace.c
diff options
context:
space:
mode:
authorGreg KH <gregkh@suse.de>2005-09-12 12:10:59 -0700
committerGreg Kroah-Hartman <gregkh@suse.de>2005-09-12 12:10:59 -0700
commitad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489 (patch)
tree5571f6a5784f51efddf9c1ee0408894cd63a460f /arch/ppc64/kernel/ptrace.c
parent6b7839007098a6b5612d31690e11277d4242e6ae (diff)
parent2ade81473636b33aaac64495f89a7dc572c529f0 (diff)
downloadop-kernel-dev-ad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489.zip
op-kernel-dev-ad2c10f8f00d3fe2e37dd8a107e7cf4ac0459489.tar.gz
Merge ../torvalds-2.6/
Diffstat (limited to 'arch/ppc64/kernel/ptrace.c')
-rw-r--r--arch/ppc64/kernel/ptrace.c28
1 files changed, 28 insertions, 0 deletions
diff --git a/arch/ppc64/kernel/ptrace.c b/arch/ppc64/kernel/ptrace.c
index 2993f10..85ed318 100644
--- a/arch/ppc64/kernel/ptrace.c
+++ b/arch/ppc64/kernel/ptrace.c
@@ -17,6 +17,7 @@
* this archive for more details.
*/
+#include <linux/config.h>
#include <linux/kernel.h>
#include <linux/sched.h>
#include <linux/mm.h>
@@ -206,6 +207,19 @@ int sys_ptrace(long request, long pid, long addr, long data)
break;
}
+ case PTRACE_GET_DEBUGREG: {
+ ret = -EINVAL;
+ /* We only support one DABR and no IABRS at the moment */
+ if (addr > 0)
+ break;
+ ret = put_user(child->thread.dabr,
+ (unsigned long __user *)data);
+ break;
+ }
+
+ case PTRACE_SET_DEBUGREG:
+ ret = ptrace_set_debugreg(child, addr, data);
+
case PTRACE_DETACH:
ret = ptrace_detach(child, data);
break;
@@ -274,6 +288,20 @@ int sys_ptrace(long request, long pid, long addr, long data)
break;
}
+#ifdef CONFIG_ALTIVEC
+ case PTRACE_GETVRREGS:
+ /* Get the child altivec register state. */
+ flush_altivec_to_thread(child);
+ ret = get_vrregs((unsigned long __user *)data, child);
+ break;
+
+ case PTRACE_SETVRREGS:
+ /* Set the child altivec register state. */
+ flush_altivec_to_thread(child);
+ ret = set_vrregs(child, (unsigned long __user *)data);
+ break;
+#endif
+
default:
ret = ptrace_request(child, request, addr, data);
break;
OpenPOWER on IntegriCloud