diff options
author | Christoph Hellwig <hch@lst.de> | 2007-05-08 03:23:29 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.linux-foundation.org> | 2007-05-08 14:14:58 -0400 |
commit | ab1b6f03a10ba1f5638188ab06bf46e33ac3a160 (patch) | |
tree | 2dc7ce01df5d51d81e250dd9cee1b7b04627466e /arch/s390 | |
parent | 7e4c3690b07f04b1942c39db358a5c8a72831daa (diff) |
simplify the stacktrace code
Simplify the stacktrace code:
- remove the unused task argument to save_stack_trace, it's always
current
- remove the all_contexts flag, it's alwasy 0
Signed-off-by: Christoph Hellwig <hch@lst.de>
Cc: Paul Mundt <lethal@linux-sh.org>
Cc: Ralf Baechle <ralf@linux-mips.org>
Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: "David S. Miller" <davem@davemloft.net>
Cc: Andi Kleen <ak@suse.de>
Cc: Akinobu Mita <akinobu.mita@gmail.com>
Acked-by: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'arch/s390')
-rw-r--r-- | arch/s390/kernel/stacktrace.c | 18 |
1 files changed, 7 insertions, 11 deletions
diff --git a/arch/s390/kernel/stacktrace.c b/arch/s390/kernel/stacktrace.c index 2e5c65a1863e..515ff9011dd7 100644 --- a/arch/s390/kernel/stacktrace.c +++ b/arch/s390/kernel/stacktrace.c | |||
@@ -59,7 +59,7 @@ static unsigned long save_context_stack(struct stack_trace *trace, | |||
59 | } | 59 | } |
60 | } | 60 | } |
61 | 61 | ||
62 | void save_stack_trace(struct stack_trace *trace, struct task_struct *task) | 62 | void save_stack_trace(struct stack_trace *trace) |
63 | { | 63 | { |
64 | register unsigned long sp asm ("15"); | 64 | register unsigned long sp asm ("15"); |
65 | unsigned long orig_sp, new_sp; | 65 | unsigned long orig_sp, new_sp; |
@@ -69,20 +69,16 @@ void save_stack_trace(struct stack_trace *trace, struct task_struct *task) | |||
69 | new_sp = save_context_stack(trace, &trace->skip, orig_sp, | 69 | new_sp = save_context_stack(trace, &trace->skip, orig_sp, |
70 | S390_lowcore.panic_stack - PAGE_SIZE, | 70 | S390_lowcore.panic_stack - PAGE_SIZE, |
71 | S390_lowcore.panic_stack); | 71 | S390_lowcore.panic_stack); |
72 | if ((new_sp != orig_sp) && !trace->all_contexts) | 72 | if (new_sp != orig_sp) |
73 | return; | 73 | return; |
74 | new_sp = save_context_stack(trace, &trace->skip, new_sp, | 74 | new_sp = save_context_stack(trace, &trace->skip, new_sp, |
75 | S390_lowcore.async_stack - ASYNC_SIZE, | 75 | S390_lowcore.async_stack - ASYNC_SIZE, |
76 | S390_lowcore.async_stack); | 76 | S390_lowcore.async_stack); |
77 | if ((new_sp != orig_sp) && !trace->all_contexts) | 77 | if (new_sp != orig_sp) |
78 | return; | 78 | return; |
79 | if (task) | 79 | |
80 | save_context_stack(trace, &trace->skip, new_sp, | 80 | save_context_stack(trace, &trace->skip, new_sp, |
81 | (unsigned long) task_stack_page(task), | 81 | S390_lowcore.thread_info, |
82 | (unsigned long) task_stack_page(task) + THREAD_SIZE); | 82 | S390_lowcore.thread_info + THREAD_SIZE); |
83 | else | ||
84 | save_context_stack(trace, &trace->skip, new_sp, | ||
85 | S390_lowcore.thread_info, | ||
86 | S390_lowcore.thread_info + THREAD_SIZE); | ||
87 | return; | 83 | return; |
88 | } | 84 | } |