From: Srinivasa Ds Date: Mon, 7 Jul 2008 14:22:27 +0000 (+1000) Subject: powerpc: Implement task_pt_regs() accessor X-Git-Tag: v2.6.27-rc1~1058^2~43 X-Git-Url: https://err.no/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=e5093ff05d36c64e8f36a9ddb26358256dc133ea;p=linux-2.6 powerpc: Implement task_pt_regs() accessor The task_pt_regs() macro allows access to the pt_regs of a given task. This macro is not currently defined for the powerpc architecture, but we need it for some upcoming utrace additions. Signed-off-by: Srinivasa DS Signed-off-by: Benjamin Herrenschmidt --- diff --git a/include/asm-powerpc/processor.h b/include/asm-powerpc/processor.h index 061cd17ba8..101ed87f7d 100644 --- a/include/asm-powerpc/processor.h +++ b/include/asm-powerpc/processor.h @@ -234,6 +234,8 @@ struct thread_struct { #define thread_saved_pc(tsk) \ ((tsk)->thread.regs? (tsk)->thread.regs->nip: 0) +#define task_pt_regs(tsk) ((struct pt_regs *)(tsk)->thread.regs) + unsigned long get_wchan(struct task_struct *p); #define KSTK_EIP(tsk) ((tsk)->thread.regs? (tsk)->thread.regs->nip: 0)