Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

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 <srinivasa@in.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>

authored by

Srinivasa Ds and committed by
Benjamin Herrenschmidt
e5093ff0 058c78f4

+2
+2
include/asm-powerpc/processor.h
··· 234 234 #define thread_saved_pc(tsk) \ 235 235 ((tsk)->thread.regs? (tsk)->thread.regs->nip: 0) 236 236 237 + #define task_pt_regs(tsk) ((struct pt_regs *)(tsk)->thread.regs) 238 + 237 239 unsigned long get_wchan(struct task_struct *p); 238 240 239 241 #define KSTK_EIP(tsk) ((tsk)->thread.regs? (tsk)->thread.regs->nip: 0)