diff options
Diffstat (limited to 'arch/blackfin/mach-common/interrupt.S')
-rw-r--r-- | arch/blackfin/mach-common/interrupt.S | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/arch/blackfin/mach-common/interrupt.S b/arch/blackfin/mach-common/interrupt.S index 8085ff1cce0..cee62cf4acd 100644 --- a/arch/blackfin/mach-common/interrupt.S +++ b/arch/blackfin/mach-common/interrupt.S | |||
@@ -88,6 +88,13 @@ __common_int_entry: | |||
88 | #else | 88 | #else |
89 | cli r1; | 89 | cli r1; |
90 | #endif | 90 | #endif |
91 | #ifdef CONFIG_TRACE_IRQFLAGS | ||
92 | [--sp] = r0; | ||
93 | sp += -12; | ||
94 | call _trace_hardirqs_off; | ||
95 | sp += 12; | ||
96 | r0 = [sp++]; | ||
97 | #endif | ||
91 | [--sp] = RETI; /* orig_pc */ | 98 | [--sp] = RETI; /* orig_pc */ |
92 | /* Clear all L registers. */ | 99 | /* Clear all L registers. */ |
93 | r1 = 0 (x); | 100 | r1 = 0 (x); |
@@ -109,10 +116,10 @@ __common_int_entry: | |||
109 | cc = r0 == 0; | 116 | cc = r0 == 0; |
110 | if cc jump .Lcommon_restore_context; | 117 | if cc jump .Lcommon_restore_context; |
111 | #else /* CONFIG_IPIPE */ | 118 | #else /* CONFIG_IPIPE */ |
112 | call _do_irq; | 119 | pseudo_long_call _do_irq, p2; |
113 | SP += 12; | 120 | SP += 12; |
114 | #endif /* CONFIG_IPIPE */ | 121 | #endif /* CONFIG_IPIPE */ |
115 | call _return_from_int; | 122 | pseudo_long_call _return_from_int, p2; |
116 | .Lcommon_restore_context: | 123 | .Lcommon_restore_context: |
117 | RESTORE_CONTEXT | 124 | RESTORE_CONTEXT |
118 | rti; | 125 | rti; |
@@ -168,7 +175,7 @@ ENTRY(_evt_ivhw) | |||
168 | 175 | ||
169 | r0 = sp; /* stack frame pt_regs pointer argument ==> r0 */ | 176 | r0 = sp; /* stack frame pt_regs pointer argument ==> r0 */ |
170 | SP += -12; | 177 | SP += -12; |
171 | call _trap_c; | 178 | pseudo_long_call _trap_c, p5; |
172 | SP += 12; | 179 | SP += 12; |
173 | 180 | ||
174 | #ifdef EBIU_ERRMST | 181 | #ifdef EBIU_ERRMST |
@@ -179,7 +186,7 @@ ENTRY(_evt_ivhw) | |||
179 | w[p0] = r0.l; | 186 | w[p0] = r0.l; |
180 | #endif | 187 | #endif |
181 | 188 | ||
182 | call _ret_from_exception; | 189 | pseudo_long_call _ret_from_exception, p2; |
183 | 190 | ||
184 | .Lcommon_restore_all_sys: | 191 | .Lcommon_restore_all_sys: |
185 | RESTORE_ALL_SYS | 192 | RESTORE_ALL_SYS |
@@ -187,12 +194,28 @@ ENTRY(_evt_ivhw) | |||
187 | ENDPROC(_evt_ivhw) | 194 | ENDPROC(_evt_ivhw) |
188 | 195 | ||
189 | /* Interrupt routine for evt2 (NMI). | 196 | /* Interrupt routine for evt2 (NMI). |
190 | * We don't actually use this, so just return. | ||
191 | * For inner circle type details, please see: | 197 | * For inner circle type details, please see: |
192 | * http://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:nmi | 198 | * http://docs.blackfin.uclinux.org/doku.php?id=linux-kernel:nmi |
193 | */ | 199 | */ |
194 | ENTRY(_evt_nmi) | 200 | ENTRY(_evt_nmi) |
201 | #ifndef CONFIG_NMI_WATCHDOG | ||
195 | .weak _evt_nmi | 202 | .weak _evt_nmi |
203 | #else | ||
204 | /* Not take account of CPLBs, this handler will not return */ | ||
205 | SAVE_ALL_SYS | ||
206 | r0 = sp; | ||
207 | r1 = retn; | ||
208 | [sp + PT_PC] = r1; | ||
209 | trace_buffer_save(p4,r5); | ||
210 | |||
211 | ANOMALY_283_315_WORKAROUND(p4, r5) | ||
212 | |||
213 | SP += -12; | ||
214 | call _do_nmi; | ||
215 | SP += 12; | ||
216 | 1: | ||
217 | jump 1b; | ||
218 | #endif | ||
196 | rtn; | 219 | rtn; |
197 | ENDPROC(_evt_nmi) | 220 | ENDPROC(_evt_nmi) |
198 | 221 | ||
@@ -223,7 +246,7 @@ ENTRY(_evt_system_call) | |||
223 | #ifdef CONFIG_FRAME_POINTER | 246 | #ifdef CONFIG_FRAME_POINTER |
224 | fp = 0; | 247 | fp = 0; |
225 | #endif | 248 | #endif |
226 | call _system_call; | 249 | pseudo_long_call _system_call, p2; |
227 | jump .Lcommon_restore_context; | 250 | jump .Lcommon_restore_context; |
228 | ENDPROC(_evt_system_call) | 251 | ENDPROC(_evt_system_call) |
229 | 252 | ||