diff options
Diffstat (limited to 'arch/mips/kernel/entry.S')
-rw-r--r-- | arch/mips/kernel/entry.S | 32 |
1 files changed, 17 insertions, 15 deletions
diff --git a/arch/mips/kernel/entry.S b/arch/mips/kernel/entry.S index 534cba7cf..a740bac27 100644 --- a/arch/mips/kernel/entry.S +++ b/arch/mips/kernel/entry.S @@ -7,7 +7,7 @@ * * Copyright (C) 1994, 1995 by Ralf Baechle * - * $Id: entry.S,v 1.13 1998/10/14 23:40:43 ralf Exp $ + * $Id: entry.S,v 1.14 1999/04/12 19:13:21 harald Exp $ */ /* @@ -31,23 +31,21 @@ #include <asm/regdef.h> #include <asm/fpregdef.h> #include <asm/unistd.h> +#include <asm/isadep.h> /* * Heia ... The %lo, %hi and %HI stuff is too strong for the ELF assembler * and the ABI to cope with ... */ .text - .set noreorder - .set mips3 .align 4 + .set push + .set reorder EXPORT(handle_bottom_half) jal do_bottom_half - nop b 9f - nop reschedule: jal schedule - nop EXPORT(ret_from_sys_call) EXPORT(ret_from_irq) @@ -55,22 +53,20 @@ EXPORT(ret_from_irq) lw t1,bh_active # unused delay slot and t0,t1 bnez t0,handle_bottom_half -9: lw t0,PT_STATUS(sp) # returning to kernel mode? - andi t1, t0, 0x10 +9: lw t0,PT_STATUS(sp) # returning to kernel mode? + lw t2, TASK_NEED_RESCHED($28) + andi t1, t0, KU_USER beqz t1, return # -> yes - lw t1, TASK_NEED_RESCHED($28) - bnez t1, reschedule + bnez t2, reschedule lw v0, TASK_SIGPENDING($28) move a0, zero beqz v0, return - nop - jal do_signal move a1, sp + jal do_signal EXPORT(return) .set noat - RESTORE_ALL - eret + RESTORE_ALL_AND_RET .set at /* @@ -84,7 +80,9 @@ LEAF(spurious_interrupt) * couldn't find a cause for it. */ lui t1,%hi(spurious_count) + .set reorder lw t0,%lo(spurious_count)(t1) + .set noreorder addiu t0,1 j ret_from_irq sw t0,%lo(spurious_count)(t1) @@ -107,7 +105,9 @@ LEAF(spurious_interrupt) ctc1 a2,fcr31; \ STI #define __BUILD_clear_ade(exception) \ + .set reorder; \ MFC0 t0,CP0_BADVADDR; \ + .set noreorder; \ REG_S t0,PT_BVADDR(sp); \ KMODE #define __BUILD_silent(exception) @@ -122,9 +122,9 @@ LEAF(spurious_interrupt) #define __BUILD_count(exception) \ .set reorder; \ lw t0,exception_count_##exception; \ + .set noreorder; \ addiu t0, 1; \ sw t0,exception_count_##exception; \ - .set noreorder; \ .data; \ EXPORT(exception_count_##exception); \ .word 0; \ @@ -156,6 +156,8 @@ EXPORT(exception_count_##exception); \ BUILD_HANDLER(watch,watch,sti,verbose) /* #23 */ BUILD_HANDLER(reserved,reserved,sti,verbose) /* others */ + .set pop + /* * Table of syscalls */ |