diff options
author | Amaury Pouly <amaury.pouly@gmail.com> | 2012-04-02 15:11:21 +0200 |
---|---|---|
committer | Amaury Pouly <amaury.pouly@gmail.com> | 2012-04-06 13:46:32 +0200 |
commit | f33330c0ff90adad8855250877a4a3d0a407bba4 (patch) | |
tree | 6b5ad86aeb2e6b0a57f78965e59c618b4a26f30f /firmware/target/arm/tms320dm320/crt0.S | |
parent | bb0e4cc543e4c7bed6dff3a41d092b6867632535 (diff) | |
download | rockbox-f33330c0ff90adad8855250877a4a3d0a407bba4.tar.gz rockbox-f33330c0ff90adad8855250877a4a3d0a407bba4.zip |
arm: factor all exception handlers out of the crt0.S files
Remove the implementations of all exceptions handlers from the
various crt0.S files and have a single implementation in system-arm.h
The new implementation is weak so that it can be overwritten by some
specific code (like the unwinder)
Change-Id: Ib3e041ed6037376bbe0e79286057e1051640dd90
Reviewed-on: http://gerrit.rockbox.org/205
Reviewed-by: Marcin Bukat <marcin.bukat@gmail.com>
Diffstat (limited to 'firmware/target/arm/tms320dm320/crt0.S')
-rw-r--r-- | firmware/target/arm/tms320dm320/crt0.S | 45 |
1 files changed, 0 insertions, 45 deletions
diff --git a/firmware/target/arm/tms320dm320/crt0.S b/firmware/target/arm/tms320dm320/crt0.S index d53cff2b63..f1b2eb397c 100644 --- a/firmware/target/arm/tms320dm320/crt0.S +++ b/firmware/target/arm/tms320dm320/crt0.S | |||
@@ -292,51 +292,6 @@ _delay_cycles: | |||
292 | .size _delay_cycles, .-_delay_cycles | 292 | .size _delay_cycles, .-_delay_cycles |
293 | 293 | ||
294 | /****************************************************************************** | 294 | /****************************************************************************** |
295 | * Unused exception vectors. These call the UIE function. * | ||
296 | * Arguements are: * | ||
297 | * r0: PC of exception * | ||
298 | * r1: Exception number. * | ||
299 | * Exception numbers are as defined: * | ||
300 | * 0: Undefined Instruction * | ||
301 | * 1: Prefetch Abort * | ||
302 | * 2: Data Abort * | ||
303 | * 3: DIV0 * | ||
304 | * 4: SWI * | ||
305 | * The exceptions return operations are documented in section A2.6 of the * | ||
306 | * ARM Architecture Reference Manual. * | ||
307 | ******************************************************************************/ | ||
308 | |||
309 | /* A2.6.3: Undefined Instruction Exception - LR=PC of next instruction */ | ||
310 | _undefined_instruction: | ||
311 | sub r0, lr, #4 | ||
312 | mov r1, #0 | ||
313 | bl UIE | ||
314 | |||
315 | /* A2.6.4: Software Interrupt exception - These should not happen in Rockbox, | ||
316 | * make it illegal | ||
317 | */ | ||
318 | _software_interrupt: | ||
319 | sub r0, lr, #4 | ||
320 | mov r1, #4 | ||
321 | bl UIE | ||
322 | |||
323 | /* A2.6.5 Prefetch Abort - This is also the BKPT instruction since this is a | ||
324 | * v5 target. Pass it on to UIE since it is not currently used. | ||
325 | */ | ||
326 | _prefetch_abort: | ||
327 | sub r0, lr, #4 | ||
328 | mov r1, #1 | ||
329 | bl UIE | ||
330 | |||
331 | /* A2.6.6 Data Abort - There was a memory abort, can return after fixing cause | ||
332 | * with the LR address. | ||
333 | */ | ||
334 | _data_abort: | ||
335 | sub r0, lr, #8 | ||
336 | mov r1, #2 | ||
337 | bl UIE | ||
338 | |||
339 | /****************************************************************************** | ||
340 | * _dead_loop: Something really unexpected happened (like a reserved * | 295 | * _dead_loop: Something really unexpected happened (like a reserved * |
341 | * exception). Just hang. * | 296 | * exception). Just hang. * |
342 | ******************************************************************************/ | 297 | ******************************************************************************/ |