History

Merge tag 'metag-fixes-v4.0-1' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag

Pull arch/metag fix from James Hogan: "This is just a single patch to fix the KSTK_EIP() and KSTK_ESP() macros for metag which have always been erronously returning the PC and stack pointer of the task's kernel context rather than from its user context saved at entry from userland into the kernel, which affects the contents of /proc/<pid>/maps and /proc/<pid>/stat" * tag 'metag-fixes-v4.0-1' of git://git.kernel.org/pub/scm/linux/kernel/git/jhogan/metag: metag: Fix KSTK_EIP() and KSTK_ESP() macros

Linus Torvalds committed 11 years ago

Commit 49db1f02 parents a38ecbb c2996cb1 file · +2 −2Browse files

Unified · Split

arch/metag/include/asm/processor.h+2−2
@@ -149,8 +149,8 @@ extern void exit_thread(void); · 148 unmodified lines
149149
150150 unsigned long get_wchan(struct task_struct *p);
151151
152−#define KSTK_EIP(tsk) ((tsk)->thread.kernel_context->CurrPC)
153−#define KSTK_ESP(tsk) ((tsk)->thread.kernel_context->AX[0].U0)
152+#define KSTK_EIP(tsk) (task_pt_regs(tsk)->ctx.CurrPC)
153+#define KSTK_ESP(tsk) (task_pt_regs(tsk)->ctx.AX[0].U0)
154154
155155 #define user_stack_pointer(regs) ((regs)->ctx.AX[0].U0)
156156