From b3a6cf0bb426d01329653bcb9d6674cc9697aa04 Mon Sep 17 00:00:00 2001 From: jethead71 Date: Mon, 3 May 2010 07:48:00 +0000 Subject: [PATCH] Gigabeat S: Those odd calls to irq_handler can still happen rarely after executing WFI. With no explanation forthcoming after trying many things, hide head in sand and ignore them and the IRQ will get vectored to the correct handler anyway. Have vector tables execute an immediate return and remove irq_handler from compilation altogether. git-svn-id: svn://svn.rockbox.org/rockbox/trunk@25792 a1c6a512-1295-4272-9138-f99709370657 --- firmware/target/arm/imx31/avic-imx31.c | 2 ++ firmware/target/arm/imx31/crt0.S | 6 +++--- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/firmware/target/arm/imx31/avic-imx31.c b/firmware/target/arm/imx31/avic-imx31.c index c8bf419bc..51ba14d0b 100644 --- a/firmware/target/arm/imx31/avic-imx31.c +++ b/firmware/target/arm/imx31/avic-imx31.c @@ -66,6 +66,7 @@ void UIE_VECTOR(void) offset >= 0 ? avic_int_names[offset] : ""); } +#if 0 /* We use the AVIC */ void __attribute__((interrupt("IRQ"))) irq_handler(void) { @@ -85,6 +86,7 @@ void __attribute__((interrupt("IRQ"))) irq_handler(void) panicf("Unhandled IRQ %d in irq_handler: %s", offset, offset >= 0 ? avic_int_names[offset] : ""); } +#endif /* 0 */ /* Accoring to section 9.3.5 of the UM, the AVIC doesn't accelerate * fast interrupts and they must be dispatched */ diff --git a/firmware/target/arm/imx31/crt0.S b/firmware/target/arm/imx31/crt0.S index 0841cb927..3a0a0041d 100644 --- a/firmware/target/arm/imx31/crt0.S +++ b/firmware/target/arm/imx31/crt0.S @@ -32,7 +32,7 @@ start: b prefetch_abort_handler b data_abort_handler b reserved_handler - b irq_handler + subs pc, lr, #4 @ b irq_handler b fiq_handler .balign 0x40, 0x6B @@ -322,7 +322,7 @@ remap_end: ldr pc, [pc, #24] ldr pc, [pc, #24] ldr pc, [pc, #24] - ldr pc, [pc, #24] + subs pc, lr, #4 @ ldr pc, [pc, #24] ldr pc, [pc, #24] .word newstart .word undef_instr_handler @@ -330,7 +330,7 @@ remap_end: .word prefetch_abort_handler .word data_abort_handler .word reserved_handler - .word irq_handler + .word 0 @ irq_handler .word fiq_handler #endif /* BOOTLOADER */ -- 2.11.4.GIT