Skip to contentSkip to conversation

ia64: add kernel_trap_sp()

RFC PATCH Superseded Masami Hiramatsu 1 participant 1 message Mar 19, 2009 ptrace support

v1 of 4 Superseded Latest is v4 →

lore
Share & tools
lore
#0 lore raw

RFC PATCH 3/9 ia64: add kernel_trap_sp()

Add kernel_trap_sp() on ia64, based on systemtap's runtime/regs.h.

---
 arch/ia64/include/asm/ptrace.h |    6 ++++++
 1 files changed, 6 insertions(+), 0 deletions(-)
arch/ia64/include/asm/ptrace.h +6 -0
index 14055c6..3a7dfcb 100644
@@ -246,6 +246,12 @@ static inline unsigned long user_stack_pointer(struct pt_regs *regs)
 	return regs->ar_bspstore;
 }
 
+static inline unsigned long kernel_trap_sp(struct pt_regs *regs)
+{
+	/* interrupted task's memory stack pointer is r12 */
+	return regs->r12;
+}
+
 #define regs_return_value(regs) ((regs)->r8)
 
 /* Conserve space in histogram by encoding slot bits in address
Signature · 7 lines
Masami Hiramatsu

Software Engineer
Hitachi Computer Products (America) Inc.
Software Solutions Division

e-mail: [email protected]