decrease the irq stack usage a bit

This commit is contained in:
Sven Peter 2009-04-15 01:43:52 +02:00 committed by bushing
parent fc9963f1db
commit 456b26c1b7
2 changed files with 9 additions and 5 deletions

8
irq.c
View File

@ -79,17 +79,17 @@ void irq_handler(void)
nand_irq(); nand_irq();
} }
if(flags & IRQF_GPIO1B) { if(flags & IRQF_GPIO1B) {
gecko_printf("IRQ: GPIO1B\n"); // gecko_printf("IRQ: GPIO1B\n");
write32(HW_GPIO1BINTFLAG, 0xFFFFFF); // shut it up write32(HW_GPIO1BINTFLAG, 0xFFFFFF); // shut it up
write32(HW_ARMIRQFLAG, IRQF_GPIO1B); write32(HW_ARMIRQFLAG, IRQF_GPIO1B);
} }
if(flags & IRQF_GPIO1) { if(flags & IRQF_GPIO1) {
gecko_printf("IRQ: GPIO1\n"); // gecko_printf("IRQ: GPIO1\n");
write32(HW_GPIO1INTFLAG, 0xFFFFFF); // shut it up write32(HW_GPIO1INTFLAG, 0xFFFFFF); // shut it up
write32(HW_ARMIRQFLAG, IRQF_GPIO1); write32(HW_ARMIRQFLAG, IRQF_GPIO1);
} }
if(flags & IRQF_RESET) { if(flags & IRQF_RESET) {
gecko_printf("IRQ: RESET\n"); // gecko_printf("IRQ: RESET\n");
write32(HW_ARMIRQFLAG, IRQF_RESET); write32(HW_ARMIRQFLAG, IRQF_RESET);
} }
if(flags & IRQF_IPC) { if(flags & IRQF_IPC) {
@ -98,7 +98,7 @@ void irq_handler(void)
write32(HW_ARMIRQFLAG, IRQF_IPC); write32(HW_ARMIRQFLAG, IRQF_IPC);
} }
if(flags & IRQF_AES) { if(flags & IRQF_AES) {
gecko_printf("IRQ: AES\n"); // gecko_printf("IRQ: AES\n");
write32(HW_ARMIRQFLAG, IRQF_AES); write32(HW_ARMIRQFLAG, IRQF_AES);
} }
if (flags & IRQF_SDHC) { if (flags & IRQF_SDHC) {

6
sdhc.c
View File

@ -1057,7 +1057,11 @@ sdhc_intr(void *arg)
* Wake up the sdmmc event thread to scan for cards. * Wake up the sdmmc event thread to scan for cards.
*/ */
if (ISSET(status, SDHC_CARD_REMOVAL|SDHC_CARD_INSERTION)) { if (ISSET(status, SDHC_CARD_REMOVAL|SDHC_CARD_INSERTION)) {
ipc_request req; // this pushed a request to the slow queue so that we
// don't block other IRQs.
// this is also static because we are in IRQ context
// here and want to save stack space
static ipc_request req;
memset(&req, 0, sizeof(req)); memset(&req, 0, sizeof(req));
req.device = IPC_DEV_SDHC; req.device = IPC_DEV_SDHC;
req.req = IPC_SDHC_DISCOVER; req.req = IPC_SDHC_DISCOVER;