diff options
author | Ralf Baechle <ralf@linux-mips.org> | 2006-06-03 17:40:15 -0400 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 2006-06-29 16:10:49 -0400 |
commit | 4277ff5ee55694f67d9c6586bb4c06991e221a68 (patch) | |
tree | c75ff9101d0dc14688c86f709370d3e122e7402a /arch | |
parent | b4ab24e1c8c1442b2928bab1325b56bdbbcf898e (diff) |
[MIPS] Fix use of ehb instruction for non-R2 configurations.
Signed-off-by: Ralf Baechle <ralf@linux-mips.org>
Diffstat (limited to 'arch')
-rw-r--r-- | arch/mips/kernel/entry.S | 6 | ||||
-rw-r--r-- | arch/mips/kernel/gdb-low.S | 4 | ||||
-rw-r--r-- | arch/mips/kernel/genex.S | 2 | ||||
-rw-r--r-- | arch/mips/kernel/head.S | 2 | ||||
-rw-r--r-- | arch/mips/kernel/r4k_switch.S | 6 | ||||
-rw-r--r-- | arch/mips/kernel/smtc-asm.S | 10 |
6 files changed, 15 insertions, 15 deletions
diff --git a/arch/mips/kernel/entry.S b/arch/mips/kernel/entry.S index a9c6de1b9542..457565162dd5 100644 --- a/arch/mips/kernel/entry.S +++ b/arch/mips/kernel/entry.S | |||
@@ -87,7 +87,7 @@ FEXPORT(restore_all) # restore full frame | |||
87 | ori v1, v0, TCSTATUS_IXMT | 87 | ori v1, v0, TCSTATUS_IXMT |
88 | mtc0 v1, CP0_TCSTATUS | 88 | mtc0 v1, CP0_TCSTATUS |
89 | andi v0, TCSTATUS_IXMT | 89 | andi v0, TCSTATUS_IXMT |
90 | ehb | 90 | _ehb |
91 | mfc0 t0, CP0_TCCONTEXT | 91 | mfc0 t0, CP0_TCCONTEXT |
92 | DMT 9 # dmt t1 | 92 | DMT 9 # dmt t1 |
93 | jal mips_ihb | 93 | jal mips_ihb |
@@ -95,7 +95,7 @@ FEXPORT(restore_all) # restore full frame | |||
95 | andi t3, t0, 0xff00 | 95 | andi t3, t0, 0xff00 |
96 | or t2, t2, t3 | 96 | or t2, t2, t3 |
97 | mtc0 t2, CP0_STATUS | 97 | mtc0 t2, CP0_STATUS |
98 | ehb | 98 | _ehb |
99 | andi t1, t1, VPECONTROL_TE | 99 | andi t1, t1, VPECONTROL_TE |
100 | beqz t1, 1f | 100 | beqz t1, 1f |
101 | EMT | 101 | EMT |
@@ -105,7 +105,7 @@ FEXPORT(restore_all) # restore full frame | |||
105 | xori v1, v1, TCSTATUS_IXMT | 105 | xori v1, v1, TCSTATUS_IXMT |
106 | or v1, v0, v1 | 106 | or v1, v0, v1 |
107 | mtc0 v1, CP0_TCSTATUS | 107 | mtc0 v1, CP0_TCSTATUS |
108 | ehb | 108 | _ehb |
109 | xor t0, t0, t3 | 109 | xor t0, t0, t3 |
110 | mtc0 t0, CP0_TCCONTEXT | 110 | mtc0 t0, CP0_TCCONTEXT |
111 | #endif /* CONFIG_MIPS_MT_SMTC */ | 111 | #endif /* CONFIG_MIPS_MT_SMTC */ |
diff --git a/arch/mips/kernel/gdb-low.S b/arch/mips/kernel/gdb-low.S index 5fd7a8af0c62..8760131f89d9 100644 --- a/arch/mips/kernel/gdb-low.S +++ b/arch/mips/kernel/gdb-low.S | |||
@@ -291,7 +291,7 @@ | |||
291 | ori t1, t2, TCSTATUS_IXMT | 291 | ori t1, t2, TCSTATUS_IXMT |
292 | mtc0 t1, CP0_TCSTATUS | 292 | mtc0 t1, CP0_TCSTATUS |
293 | andi t2, t2, TCSTATUS_IXMT | 293 | andi t2, t2, TCSTATUS_IXMT |
294 | ehb | 294 | _ehb |
295 | DMT 9 # dmt t1 | 295 | DMT 9 # dmt t1 |
296 | jal mips_ihb | 296 | jal mips_ihb |
297 | nop | 297 | nop |
@@ -310,7 +310,7 @@ | |||
310 | xori t1, t1, TCSTATUS_IXMT | 310 | xori t1, t1, TCSTATUS_IXMT |
311 | or t1, t1, t2 | 311 | or t1, t1, t2 |
312 | mtc0 t1, CP0_TCSTATUS | 312 | mtc0 t1, CP0_TCSTATUS |
313 | ehb | 313 | _ehb |
314 | #endif /* CONFIG_MIPS_MT_SMTC */ | 314 | #endif /* CONFIG_MIPS_MT_SMTC */ |
315 | LONG_L v0, GDB_FR_STATUS(sp) | 315 | LONG_L v0, GDB_FR_STATUS(sp) |
316 | LONG_L v1, GDB_FR_EPC(sp) | 316 | LONG_L v1, GDB_FR_EPC(sp) |
diff --git a/arch/mips/kernel/genex.S b/arch/mips/kernel/genex.S index ff7af369f286..6888cde560af 100644 --- a/arch/mips/kernel/genex.S +++ b/arch/mips/kernel/genex.S | |||
@@ -214,7 +214,7 @@ NESTED(except_vec_vi_handler, 0, sp) | |||
214 | mtc0 t0, CP0_TCCONTEXT | 214 | mtc0 t0, CP0_TCCONTEXT |
215 | xor t1, t1, t0 | 215 | xor t1, t1, t0 |
216 | mtc0 t1, CP0_STATUS | 216 | mtc0 t1, CP0_STATUS |
217 | ehb | 217 | _ehb |
218 | #endif /* CONFIG_MIPS_MT_SMTC */ | 218 | #endif /* CONFIG_MIPS_MT_SMTC */ |
219 | CLI | 219 | CLI |
220 | move a0, sp | 220 | move a0, sp |
diff --git a/arch/mips/kernel/head.S b/arch/mips/kernel/head.S index bdf6f6eff721..c018098c9a56 100644 --- a/arch/mips/kernel/head.S +++ b/arch/mips/kernel/head.S | |||
@@ -96,7 +96,7 @@ | |||
96 | /* Clear TKSU, leave IXMT */ | 96 | /* Clear TKSU, leave IXMT */ |
97 | xori t0, 0x00001800 | 97 | xori t0, 0x00001800 |
98 | mtc0 t0, CP0_TCSTATUS | 98 | mtc0 t0, CP0_TCSTATUS |
99 | ehb | 99 | _ehb |
100 | /* We need to leave the global IE bit set, but clear EXL...*/ | 100 | /* We need to leave the global IE bit set, but clear EXL...*/ |
101 | mfc0 t0, CP0_STATUS | 101 | mfc0 t0, CP0_STATUS |
102 | or t0, ST0_CU0 | ST0_EXL | ST0_ERL | \set | \clr | 102 | or t0, ST0_CU0 | ST0_EXL | ST0_ERL | \set | \clr |
diff --git a/arch/mips/kernel/r4k_switch.S b/arch/mips/kernel/r4k_switch.S index db94e556fc97..e1b85e6c486a 100644 --- a/arch/mips/kernel/r4k_switch.S +++ b/arch/mips/kernel/r4k_switch.S | |||
@@ -94,7 +94,7 @@ | |||
94 | ori t1, t2, TCSTATUS_IXMT | 94 | ori t1, t2, TCSTATUS_IXMT |
95 | mtc0 t1, CP0_TCSTATUS | 95 | mtc0 t1, CP0_TCSTATUS |
96 | andi t2, t2, TCSTATUS_IXMT | 96 | andi t2, t2, TCSTATUS_IXMT |
97 | ehb | 97 | _ehb |
98 | DMT 8 # dmt t0 | 98 | DMT 8 # dmt t0 |
99 | move t1,ra | 99 | move t1,ra |
100 | jal mips_ihb | 100 | jal mips_ihb |
@@ -109,7 +109,7 @@ | |||
109 | or a2, t1 | 109 | or a2, t1 |
110 | mtc0 a2, CP0_STATUS | 110 | mtc0 a2, CP0_STATUS |
111 | #ifdef CONFIG_MIPS_MT_SMTC | 111 | #ifdef CONFIG_MIPS_MT_SMTC |
112 | ehb | 112 | _ehb |
113 | andi t0, t0, VPECONTROL_TE | 113 | andi t0, t0, VPECONTROL_TE |
114 | beqz t0, 1f | 114 | beqz t0, 1f |
115 | emt | 115 | emt |
@@ -118,7 +118,7 @@ | |||
118 | xori t1, t1, TCSTATUS_IXMT | 118 | xori t1, t1, TCSTATUS_IXMT |
119 | or t1, t1, t2 | 119 | or t1, t1, t2 |
120 | mtc0 t1, CP0_TCSTATUS | 120 | mtc0 t1, CP0_TCSTATUS |
121 | ehb | 121 | _ehb |
122 | #endif /* CONFIG_MIPS_MT_SMTC */ | 122 | #endif /* CONFIG_MIPS_MT_SMTC */ |
123 | move v0, a0 | 123 | move v0, a0 |
124 | jr ra | 124 | jr ra |
diff --git a/arch/mips/kernel/smtc-asm.S b/arch/mips/kernel/smtc-asm.S index c9d65196d917..72c6d98f8854 100644 --- a/arch/mips/kernel/smtc-asm.S +++ b/arch/mips/kernel/smtc-asm.S | |||
@@ -52,12 +52,12 @@ FEXPORT(__smtc_ipi_vector) | |||
52 | .set noat | 52 | .set noat |
53 | /* Disable thread scheduling to make Status update atomic */ | 53 | /* Disable thread scheduling to make Status update atomic */ |
54 | DMT 27 # dmt k1 | 54 | DMT 27 # dmt k1 |
55 | ehb | 55 | _ehb |
56 | /* Set EXL */ | 56 | /* Set EXL */ |
57 | mfc0 k0,CP0_STATUS | 57 | mfc0 k0,CP0_STATUS |
58 | ori k0,k0,ST0_EXL | 58 | ori k0,k0,ST0_EXL |
59 | mtc0 k0,CP0_STATUS | 59 | mtc0 k0,CP0_STATUS |
60 | ehb | 60 | _ehb |
61 | /* Thread scheduling now inhibited by EXL. Restore TE state. */ | 61 | /* Thread scheduling now inhibited by EXL. Restore TE state. */ |
62 | andi k1,k1,VPECONTROL_TE | 62 | andi k1,k1,VPECONTROL_TE |
63 | beqz k1,1f | 63 | beqz k1,1f |
@@ -82,7 +82,7 @@ FEXPORT(__smtc_ipi_vector) | |||
82 | li k1,ST0_CU0 | 82 | li k1,ST0_CU0 |
83 | or k1,k1,k0 | 83 | or k1,k1,k0 |
84 | mtc0 k1,CP0_STATUS | 84 | mtc0 k1,CP0_STATUS |
85 | ehb | 85 | _ehb |
86 | get_saved_sp | 86 | get_saved_sp |
87 | /* Interrupting TC will have pre-set values in slots in the new frame */ | 87 | /* Interrupting TC will have pre-set values in slots in the new frame */ |
88 | 2: subu k1,k1,PT_SIZE | 88 | 2: subu k1,k1,PT_SIZE |
@@ -90,7 +90,7 @@ FEXPORT(__smtc_ipi_vector) | |||
90 | lw k0,PT_TCSTATUS(k1) | 90 | lw k0,PT_TCSTATUS(k1) |
91 | /* Write it to TCStatus to restore CU/KSU/IXMT state */ | 91 | /* Write it to TCStatus to restore CU/KSU/IXMT state */ |
92 | mtc0 k0,$2,1 | 92 | mtc0 k0,$2,1 |
93 | ehb | 93 | _ehb |
94 | lw k0,PT_EPC(k1) | 94 | lw k0,PT_EPC(k1) |
95 | mtc0 k0,CP0_EPC | 95 | mtc0 k0,CP0_EPC |
96 | /* Save all will redundantly recompute the SP, but use it for now */ | 96 | /* Save all will redundantly recompute the SP, but use it for now */ |
@@ -116,7 +116,7 @@ LEAF(self_ipi) | |||
116 | mfc0 t0,CP0_TCSTATUS | 116 | mfc0 t0,CP0_TCSTATUS |
117 | ori t1,t0,TCSTATUS_IXMT | 117 | ori t1,t0,TCSTATUS_IXMT |
118 | mtc0 t1,CP0_TCSTATUS | 118 | mtc0 t1,CP0_TCSTATUS |
119 | ehb | 119 | _ehb |
120 | /* We know we're in kernel mode, so prepare stack frame */ | 120 | /* We know we're in kernel mode, so prepare stack frame */ |
121 | subu t1,sp,PT_SIZE | 121 | subu t1,sp,PT_SIZE |
122 | sw ra,PT_EPC(t1) | 122 | sw ra,PT_EPC(t1) |