summaryrefslogtreecommitdiff
path: root/arch/x86/include/asm/stacktrace.h
diff options
context:
space:
mode:
Diffstat (limited to 'arch/x86/include/asm/stacktrace.h')
-rw-r--r--arch/x86/include/asm/stacktrace.h5
1 files changed, 1 insertions, 4 deletions
diff --git a/arch/x86/include/asm/stacktrace.h b/arch/x86/include/asm/stacktrace.h
index 20ce3db20f24..2e41c50ddf47 100644
--- a/arch/x86/include/asm/stacktrace.h
+++ b/arch/x86/include/asm/stacktrace.h
@@ -52,16 +52,13 @@ static inline bool on_stack(struct stack_info *info, void *addr, size_t len)
static inline unsigned long *
get_frame_pointer(struct task_struct *task, struct pt_regs *regs)
{
- struct inactive_task_frame *frame;
-
if (regs)
return (unsigned long *)regs->bp;
if (task == current)
return __builtin_frame_address(0);
- frame = (struct inactive_task_frame *)task->thread.sp;
- return (unsigned long *)READ_ONCE_NOCHECK(frame->bp);
+ return &((struct inactive_task_frame *)task->thread.sp)->bp;
}
#else
static inline unsigned long *