diff options
author | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-12 11:14:46 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@woody.osdl.org> | 2006-12-12 11:14:46 -0500 |
commit | d224a93d91610fc641fbc5b234b32fcb84045a30 (patch) | |
tree | f908bcf0c0c1c73dabfd00a134895cfb33aa9a5d /arch/sh/kernel/process.c | |
parent | b57bd06655a028aba7b92e1c19c2093e7fcfb341 (diff) | |
parent | e9cfc147df99790a7d260e9d20b865fa31ec56da (diff) |
Merge master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6
* master.kernel.org:/pub/scm/linux/kernel/git/lethal/sh-2.6: (29 commits)
sh: Fixup SH-2 BUG() trap handling.
sh: Use early_param() for earlyprintk parsing.
sh: Fix .empty_zero_page alignment for PAGE_SIZE > 4096.
sh: Fixup .data.page_aligned.
sh: Hook up SH7722 scif ipr interrupts.
sh: Fixup sh_bios() trap handling.
sh: SH-MobileR SH7722 CPU support.
sh: Fixup dma_cache_sync() callers.
sh: Convert remaining remap_area_pages() users to ioremap_page_range().
sh: Fixup kernel_execve() for syscall cleanups.
sh: Fix get_wchan().
sh: BUG() handling through trapa vector.
rtc: rtc-sh: alarm support.
rtc: rtc-sh: fix rtc for out-by-one for the month.
sh: Kill off unused SE7619 I/O ops.
serial: sh-sci: Shut up various sci_rxd_in() gcc4 warnings.
sh: Split out atomic ops logically.
sh: Fix Solution Engine 7619 build.
sh: Trivial build fixes for SH-2 support.
sh: IPR IRQ updates for SH7619/SH7206.
...
Diffstat (limited to 'arch/sh/kernel/process.c')
-rw-r--r-- | arch/sh/kernel/process.c | 15 |
1 files changed, 13 insertions, 2 deletions
diff --git a/arch/sh/kernel/process.c b/arch/sh/kernel/process.c index f3e2631be144..486c06e18033 100644 --- a/arch/sh/kernel/process.c +++ b/arch/sh/kernel/process.c | |||
@@ -470,9 +470,10 @@ unsigned long get_wchan(struct task_struct *p) | |||
470 | */ | 470 | */ |
471 | pc = thread_saved_pc(p); | 471 | pc = thread_saved_pc(p); |
472 | if (in_sched_functions(pc)) { | 472 | if (in_sched_functions(pc)) { |
473 | schedule_frame = ((unsigned long *)(long)p->thread.sp)[1]; | 473 | schedule_frame = (unsigned long)p->thread.sp; |
474 | return (unsigned long)((unsigned long *)schedule_frame)[1]; | 474 | return ((unsigned long *)schedule_frame)[21]; |
475 | } | 475 | } |
476 | |||
476 | return pc; | 477 | return pc; |
477 | } | 478 | } |
478 | 479 | ||
@@ -498,6 +499,16 @@ asmlinkage void break_point_trap_software(unsigned long r4, unsigned long r5, | |||
498 | { | 499 | { |
499 | struct pt_regs *regs = RELOC_HIDE(&__regs, 0); | 500 | struct pt_regs *regs = RELOC_HIDE(&__regs, 0); |
500 | 501 | ||
502 | /* Rewind */ | ||
501 | regs->pc -= 2; | 503 | regs->pc -= 2; |
504 | |||
505 | #ifdef CONFIG_BUG | ||
506 | if (__kernel_text_address(instruction_pointer(regs))) { | ||
507 | u16 insn = *(u16 *)instruction_pointer(regs); | ||
508 | if (insn == TRAPA_BUG_OPCODE) | ||
509 | handle_BUG(regs); | ||
510 | } | ||
511 | #endif | ||
512 | |||
502 | force_sig(SIGTRAP, current); | 513 | force_sig(SIGTRAP, current); |
503 | } | 514 | } |