diff options
Diffstat (limited to 'utils/hwstub/stub/asm/mips/system.S')
-rw-r--r-- | utils/hwstub/stub/asm/mips/system.S | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/utils/hwstub/stub/asm/mips/system.S b/utils/hwstub/stub/asm/mips/system.S index 97b0207ec9..2d89bde096 100644 --- a/utils/hwstub/stub/asm/mips/system.S +++ b/utils/hwstub/stub/asm/mips/system.S | |||
@@ -49,6 +49,33 @@ set_data_abort_jmp: | |||
49 | sw ra, 40(v0) | 49 | sw ra, 40(v0) |
50 | jr ra | 50 | jr ra |
51 | move v0, zero | 51 | move v0, zero |
52 | |||
53 | /* restore context on read/write error, performs the interrupt return */ | ||
54 | .global restore_data_abort_jmp | ||
55 | restore_data_abort_jmp: | ||
56 | la k1, data_abort_jmp_ctx_ptr | ||
57 | lw s0, 0(k1) | ||
58 | lw s1, 4(k1) | ||
59 | lw s2, 8(k1) | ||
60 | lw s3, 12(k1) | ||
61 | lw s4, 16(k1) | ||
62 | lw s5, 20(k1) | ||
63 | lw s6, 24(k1) | ||
64 | lw s7, 28(k1) | ||
65 | lw sp, 32(k1) | ||
66 | lw s8, 36(k1) | ||
67 | lw k1, 40(k1) | ||
68 | mtc0 k1, C0_EPC | ||
69 | #ifdef CONFIG_JZ4760B | ||
70 | /* XBurst has a 3 interlock cycle delay, but we don't know if the interlock | ||
71 | * works with eret */ | ||
72 | nop | ||
73 | #else | ||
74 | ehb | ||
75 | #endif | ||
76 | li v0, 1 | ||
77 | eret | ||
78 | nop | ||
52 | .set reorder | 79 | .set reorder |
53 | 80 | ||
54 | #ifdef CONFIG_FLUSH_CACHES | 81 | #ifdef CONFIG_FLUSH_CACHES |