summaryrefslogtreecommitdiffstats
path: root/arch/alpha/include/asm/ptrace.h
diff options
context:
space:
mode:
authorAl Viro <viro@zeniv.linux.org.uk>2012-11-18 18:50:10 +0100
committerAl Viro <viro@zeniv.linux.org.uk>2012-12-20 00:07:39 +0100
commit1ca97bb541a1f5a735e697a8bba763cde3aab452 (patch)
tree548d835c0f13de780678922ba3b3ea4c841e8cd7 /arch/alpha/include/asm/ptrace.h
parentmissing user_stack_pointer() instances (diff)
downloadlinux-1ca97bb541a1f5a735e697a8bba763cde3aab452.tar.xz
linux-1ca97bb541a1f5a735e697a8bba763cde3aab452.zip
new helper: current_user_stack_pointer()
Cross-architecture equivalent of rdusp(); default is user_stack_pointer(current_pt_regs()) - that works for almost all platforms that have usp saved in pt_regs. The only exception from that is ia64 - we want memory stack, not the backing store for register one. Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'arch/alpha/include/asm/ptrace.h')
-rw-r--r--arch/alpha/include/asm/ptrace.h1
1 files changed, 1 insertions, 0 deletions
diff --git a/arch/alpha/include/asm/ptrace.h b/arch/alpha/include/asm/ptrace.h
index b4c5b2fbb647..fd53c74ac943 100644
--- a/arch/alpha/include/asm/ptrace.h
+++ b/arch/alpha/include/asm/ptrace.h
@@ -72,6 +72,7 @@ struct switch_stack {
#define user_mode(regs) (((regs)->ps & 8) != 0)
#define instruction_pointer(regs) ((regs)->pc)
#define profile_pc(regs) instruction_pointer(regs)
+#define current_user_stack_pointer() rdusp()
#define task_pt_regs(task) \
((struct pt_regs *) (task_stack_page(task) + 2*PAGE_SIZE) - 1)