import of upstream 2.4.34.4 from kernel.org
[linux-2.4.git] / arch / mips / dec / prom / locore.S
1 /*
2  * locore.S
3  */
4 #include <asm/asm.h>
5 #include <asm/regdef.h>
6 #include <asm/mipsregs.h>
7
8         .text
9
10 /*
11  * Simple general exception handling routine. This one is used for the
12  * Memory sizing routine for pmax machines. HK
13  */
14
15 NESTED(genexcept_early, 0, sp)
16         .set    noat
17         .set    noreorder
18
19         mfc0    k0, CP0_STATUS
20         la      k1, mem_err
21
22         sw      k0, 0(k1)
23
24         mfc0    k0, CP0_EPC
25         nop
26         addiu   k0, 4           # skip the causing instruction
27         jr      k0
28          rfe
29 END(genexcept_early)
30