Need to enable global GPIO interrupt after attaching
git-svn-id: svn://svn.code.sf.net/p/nuttx/code/trunk@2844 42af7a65-404d-4744-a932-0658087f49c3
This commit is contained in:
parent
98ba66080f
commit
219051de0f
@ -255,31 +255,45 @@ int gpio_irqinitialize(void)
|
|||||||
g_gpioirqvector[i] = irq_unexpected_isr;
|
g_gpioirqvector[i] = irq_unexpected_isr;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Then attach all GPIO interrupt handlers */
|
/* Then attach each GPIO interrupt handlers and enable corresponding GPIO
|
||||||
|
* interrupts
|
||||||
|
*/
|
||||||
|
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOA_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOA_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOA, lm3s_gpioahandler);
|
irq_attach(LM3S_IRQ_GPIOA, lm3s_gpioahandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOA);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOB_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOB_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOB, lm3s_gpiobhandler);
|
irq_attach(LM3S_IRQ_GPIOB, lm3s_gpiobhandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOB);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOC_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOC_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOC, lm3s_gpiochandler);
|
irq_attach(LM3S_IRQ_GPIOC, lm3s_gpiochandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOC);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOD_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOD_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOD, lm3s_gpiodhandler);
|
irq_attach(LM3S_IRQ_GPIOD, lm3s_gpiodhandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOD);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOE_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOE_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOE, lm3s_gpioehandler);
|
irq_attach(LM3S_IRQ_GPIOE, lm3s_gpioehandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOE);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOF_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOF_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOF, lm3s_gpiofhandler);
|
irq_attach(LM3S_IRQ_GPIOF, lm3s_gpiofhandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOF);
|
||||||
#endif
|
#endif
|
||||||
#ifndef CONFIG_LM3S_DISABLE_GPIOG_IRQS
|
#ifndef CONFIG_LM3S_DISABLE_GPIOG_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOG, lm3s_gpioghandler);
|
irq_attach(LM3S_IRQ_GPIOG, lm3s_gpioghandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOG);
|
||||||
#endif
|
#endif
|
||||||
#if !defined(CONFIG_LM3S_DISABLE_GPIOH_IRQS) && defined(LM3S_GPIOH_BASE)
|
#ifndef CONFIG_LM3S_DISABLE_GPIOH_IRQS
|
||||||
irq_attach(LM3S_IRQ_GPIOH, lm3s_gpiohhandler);
|
irq_attach(LM3S_IRQ_GPIOH, lm3s_gpiohhandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOH);
|
||||||
|
#endif
|
||||||
|
#ifndef CONFIG_LM3S_DISABLE_GPIOJ_IRQS
|
||||||
|
irq_attach(LM3S_IRQ_GPIOJ lm3s_gpiohhandler);
|
||||||
|
up_enable_irq(LM3S_IRQ_GPIOJ);
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
return OK;
|
return OK;
|
||||||
|
Loading…
Reference in New Issue
Block a user