mirror of
https://github.com/apache/nuttx.git
synced 2026-06-05 15:58:59 +08:00
Tiva: Fix compile errors when GPIO interrupts are not enabled
This commit is contained in:
@@ -635,6 +635,7 @@ static inline void tiva_initoutput(uint32_t pinset)
|
|||||||
*
|
*
|
||||||
****************************************************************************/
|
****************************************************************************/
|
||||||
|
|
||||||
|
#ifdef CONFIG_TIVA_GPIO_IRQS
|
||||||
static inline void tiva_interrupt(uint32_t pinset)
|
static inline void tiva_interrupt(uint32_t pinset)
|
||||||
{
|
{
|
||||||
uint8_t port = (pinset & GPIO_PORT_MASK) >> GPIO_PORT_SHIFT;
|
uint8_t port = (pinset & GPIO_PORT_MASK) >> GPIO_PORT_SHIFT;
|
||||||
@@ -742,6 +743,7 @@ static inline void tiva_interrupt(uint32_t pinset)
|
|||||||
vdbg("IEV 0x%08x 0x%08x\n", ievset, regval);
|
vdbg("IEV 0x%08x 0x%08x\n", ievset, regval);
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
* Name: tiva_portcontrol
|
* Name: tiva_portcontrol
|
||||||
@@ -862,12 +864,14 @@ int tiva_configgpio(uint32_t pinset)
|
|||||||
tiva_initoutput(pinset);
|
tiva_initoutput(pinset);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#ifdef CONFIG_TIVA_GPIO_IRQS
|
||||||
/* Special setup for interrupt GPIO pins */
|
/* Special setup for interrupt GPIO pins */
|
||||||
|
|
||||||
else if (func == 7)
|
else if (func == 7)
|
||||||
{
|
{
|
||||||
tiva_interrupt(pinset);
|
tiva_interrupt(pinset);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
irqrestore(flags);
|
irqrestore(flags);
|
||||||
return OK;
|
return OK;
|
||||||
|
|||||||
Reference in New Issue
Block a user