diff options
Diffstat (limited to 'arch/s390/kernel/dumpstack.c')
-rw-r--r-- | arch/s390/kernel/dumpstack.c | 12 |
1 files changed, 8 insertions, 4 deletions
diff --git a/arch/s390/kernel/dumpstack.c b/arch/s390/kernel/dumpstack.c index 298297477257..87acc38f73c6 100644 --- a/arch/s390/kernel/dumpstack.c +++ b/arch/s390/kernel/dumpstack.c | |||
@@ -74,6 +74,8 @@ __show_trace(unsigned long sp, unsigned long low, unsigned long high) | |||
74 | 74 | ||
75 | static void show_trace(struct task_struct *task, unsigned long *stack) | 75 | static void show_trace(struct task_struct *task, unsigned long *stack) |
76 | { | 76 | { |
77 | const unsigned long frame_size = | ||
78 | STACK_FRAME_OVERHEAD + sizeof(struct pt_regs); | ||
77 | register unsigned long __r15 asm ("15"); | 79 | register unsigned long __r15 asm ("15"); |
78 | unsigned long sp; | 80 | unsigned long sp; |
79 | 81 | ||
@@ -82,11 +84,13 @@ static void show_trace(struct task_struct *task, unsigned long *stack) | |||
82 | sp = task ? task->thread.ksp : __r15; | 84 | sp = task ? task->thread.ksp : __r15; |
83 | printk("Call Trace:\n"); | 85 | printk("Call Trace:\n"); |
84 | #ifdef CONFIG_CHECK_STACK | 86 | #ifdef CONFIG_CHECK_STACK |
85 | sp = __show_trace(sp, S390_lowcore.panic_stack - 4096, | 87 | sp = __show_trace(sp, |
86 | S390_lowcore.panic_stack); | 88 | S390_lowcore.panic_stack + frame_size - 4096, |
89 | S390_lowcore.panic_stack + frame_size); | ||
87 | #endif | 90 | #endif |
88 | sp = __show_trace(sp, S390_lowcore.async_stack - ASYNC_SIZE, | 91 | sp = __show_trace(sp, |
89 | S390_lowcore.async_stack); | 92 | S390_lowcore.async_stack + frame_size - ASYNC_SIZE, |
93 | S390_lowcore.async_stack + frame_size); | ||
90 | if (task) | 94 | if (task) |
91 | __show_trace(sp, (unsigned long) task_stack_page(task), | 95 | __show_trace(sp, (unsigned long) task_stack_page(task), |
92 | (unsigned long) task_stack_page(task) + THREAD_SIZE); | 96 | (unsigned long) task_stack_page(task) + THREAD_SIZE); |