summaryrefslogtreecommitdiff
path: root/firmware/target/mips/ingenic_jz47xx/system-target.h
diff options
context:
space:
mode:
Diffstat (limited to 'firmware/target/mips/ingenic_jz47xx/system-target.h')
-rw-r--r--firmware/target/mips/ingenic_jz47xx/system-target.h7
1 files changed, 5 insertions, 2 deletions
diff --git a/firmware/target/mips/ingenic_jz47xx/system-target.h b/firmware/target/mips/ingenic_jz47xx/system-target.h
index d8c395cef2..30c1668bf7 100644
--- a/firmware/target/mips/ingenic_jz47xx/system-target.h
+++ b/firmware/target/mips/ingenic_jz47xx/system-target.h
@@ -123,7 +123,10 @@ static inline void core_sleep(void)
#if CONFIG_CPU == JZ4732 || CONFIG_CPU == JZ4760B
__cpm_idle_mode();
#endif
- asm volatile(".set mips32r2 \n"
+ asm volatile(
+ ".set push \n"
+ ".set mips32r2 \n"
+ ".set noreorder \n"
"mfc0 $8, $12 \n" /* mfc t0, $12 */
"move $9, $8 \n" /* move t1, t0 */
"la $10, 0x8000000 \n" /* la t2, 0x8000000 */
@@ -131,7 +134,7 @@ static inline void core_sleep(void)
"mtc0 $8, $12 \n" /* mtc t0, $12 */
"wait \n"
"mtc0 $9, $12 \n" /* mtc t1, $12 */
- ".set mips0 \n"
+ ".set pop \n"
::: "t0", "t1", "t2"
);
enable_irq();