summaryrefslogtreecommitdiff
path: root/nuttx/arch
diff options
context:
space:
mode:
authorGregory Nutt <gnutt@nuttx.org>2014-12-18 15:19:16 -0600
committerGregory Nutt <gnutt@nuttx.org>2014-12-18 15:19:16 -0600
commit80c255f609d67004c15cad2ad1cca77b7fdf26a7 (patch)
tree297833a096c2f8d1593cb4e060b2bc45ded2ba28 /nuttx/arch
parent7bcedfcedce874b1863bbc1cdceaae33eca7ba35 (diff)
downloadnuttx-80c255f609d67004c15cad2ad1cca77b7fdf26a7.tar.gz
nuttx-80c255f609d67004c15cad2ad1cca77b7fdf26a7.tar.bz2
nuttx-80c255f609d67004c15cad2ad1cca77b7fdf26a7.zip
Tiva: Change negative logic CONFIG_TIVA_DISABLE_GPIOx_IRQS to positive logic CONFIG_TIVA_GPIOx_IRQS
Diffstat (limited to 'nuttx/arch')
-rw-r--r--nuttx/arch/arm/include/tiva/irq.h191
-rw-r--r--nuttx/arch/arm/src/tiva/Kconfig99
-rw-r--r--nuttx/arch/arm/src/tiva/tiva_gpioirq.c108
-rw-r--r--nuttx/arch/arm/src/tiva/tiva_irq.c2
4 files changed, 224 insertions, 176 deletions
diff --git a/nuttx/arch/arm/include/tiva/irq.h b/nuttx/arch/arm/include/tiva/irq.h
index a6add0e74..f3764eb3c 100644
--- a/nuttx/arch/arm/include/tiva/irq.h
+++ b/nuttx/arch/arm/include/tiva/irq.h
@@ -47,82 +47,93 @@
/************************************************************************************
* Pre-processor Definitions
************************************************************************************/
-/* The TM4C123x and TM4C129x support interrupts only on port P and Q */
-
-#if defined(CONFIG_ARCH_CHIP_TM4C)
-# undef CONFIG_TIVA_DISABLE_GPIOA_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOB_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOC_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOD_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOE_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOF_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOG_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOH_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOJ_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOK_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOL_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOM_IRQS
-# undef CONFIG_TIVA_DISABLE_GPION_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOR_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOS_IRQS
-# undef CONFIG_TIVA_DISABLE_GPIOT_IRQS
-
-# define CONFIG_TIVA_DISABLE_GPIOA_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOB_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOC_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOD_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOE_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOF_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOG_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOH_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOJ_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOK_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOL_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOM_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPION_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOR_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOS_IRQS 1
-# define CONFIG_TIVA_DISABLE_GPIOT_IRQS 1
+#if defined(CONFIG_ARCH_CHIP_LM3S) || defined(CONFIG_ARCH_CHIP_LM4F) || \
+ defined(CONFIG_ARCH_CHIP_CC3200)
+
+ /* I don't believe that any of these families support interrupts on port J. Many
+ * do not support interrupts on port H either.
+ */
+
+# undef CONFIG_TIVA_GPIOJ_IRQS
+
+#elif defined(CONFIG_ARCH_CHIP_TM4C)
+
+/* The TM4C123x and TM4C129x support interrupts only on ports P and Q. */
+
+# undef CONFIG_TIVA_GPIOA_IRQS
+# undef CONFIG_TIVA_GPIOB_IRQS
+# undef CONFIG_TIVA_GPIOC_IRQS
+# undef CONFIG_TIVA_GPIOD_IRQS
+# undef CONFIG_TIVA_GPIOE_IRQS
+# undef CONFIG_TIVA_GPIOF_IRQS
+# undef CONFIG_TIVA_GPIOG_IRQS
+# undef CONFIG_TIVA_GPIOH_IRQS
+# undef CONFIG_TIVA_GPIOJ_IRQS
+# undef CONFIG_TIVA_GPIOK_IRQS
+# undef CONFIG_TIVA_GPIOL_IRQS
+# undef CONFIG_TIVA_GPIOM_IRQS
+# undef CONFIG_TIVA_GPION_IRQS
+# undef CONFIG_TIVA_GPIOR_IRQS
+# undef CONFIG_TIVA_GPIOS_IRQS
+# undef CONFIG_TIVA_GPIOT_IRQS
+
#endif
/* Mark GPIO interrupts as disabled for non-existent GPIO ports. */
-#if TIVA_NPORTS < 1 && !defined(CONFIG_TIVA_DISABLE_GPIOA_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOA_IRQS
-#elif TIVA_NPORTS < 2 && !defined(CONFIG_TIVA_DISABLE_GPIOB_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOB_IRQS
-#elif TIVA_NPORTS < 3 && !defined(CONFIG_TIVA_DISABLE_GPIOC_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOC_IRQS
-#elif TIVA_NPORTS < 4 && !defined(CONFIG_TIVA_DISABLE_GPIOD_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOD_IRQS
-#elif TIVA_NPORTS < 5 && !defined(CONFIG_TIVA_DISABLE_GPIOE_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOE_IRQS
-#elif TIVA_NPORTS < 6 && !defined(CONFIG_TIVA_DISABLE_GPIOF_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOF_IRQS
-#elif TIVA_NPORTS < 7 && !defined(CONFIG_TIVA_DISABLE_GPIOG_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOG_IRQS
-#elif TIVA_NPORTS < 8 && !defined(CONFIG_TIVA_DISABLE_GPIOH_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOH_IRQS
-#elif TIVA_NPORTS < 9 && !defined(CONFIG_TIVA_DISABLE_GPIOJ_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOJ_IRQS
-#elif TIVA_NPORTS < 10 && !defined(CONFIG_TIVA_DISABLE_GPIOK_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOK_IRQS
-#elif TIVA_NPORTS < 11 && !defined(CONFIG_TIVA_DISABLE_GPIOL_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOL_IRQS
-#elif TIVA_NPORTS < 12 && !defined(CONFIG_TIVA_DISABLE_GPIOM_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOM_IRQS
-#elif TIVA_NPORTS < 13 && !defined(CONFIG_TIVA_DISABLE_GPION_IRQS)
-# define CONFIG_TIVA_DISABLE_GPION_IRQS
-#elif TIVA_NPORTS < 14 && !defined(CONFIG_TIVA_DISABLE_GPIOP_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOP_IRQS
-#elif TIVA_NPORTS < 15 && !defined(CONFIG_TIVA_DISABLE_GPIOQ_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOQ_IRQS
-#elif TIVA_NPORTS < 16 && !defined(CONFIG_TIVA_DISABLE_GPIOQ_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOQ_IRQS
-#elif TIVA_NPORTS < 17 && !defined(CONFIG_TIVA_DISABLE_GPIOQ_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOQ_IRQS
-#elif TIVA_NPORTS < 18 && !defined(CONFIG_TIVA_DISABLE_GPIOQ_IRQS)
-# define CONFIG_TIVA_DISABLE_GPIOQ_IRQS
+#if TIVA_NPORTS < 1
+# undef CONFIG_TIVA_GPIOA_IRQS
+#endif
+#if TIVA_NPORTS < 2
+# undef CONFIG_TIVA_GPIOB_IRQS
+#endif
+#if TIVA_NPORTS < 3
+# undef CONFIG_TIVA_GPIOC_IRQS
+#endif
+#if TIVA_NPORTS < 4
+# undef CONFIG_TIVA_GPIOD_IRQS
+#endif
+#if TIVA_NPORTS < 5
+# undef CONFIG_TIVA_GPIOE_IRQS
+#endif
+#if TIVA_NPORTS < 6
+# undef CONFIG_TIVA_GPIOF_IRQS
+#endif
+#if TIVA_NPORTS < 7
+# undef CONFIG_TIVA_GPIOG_IRQS
+#endif
+#if TIVA_NPORTS < 8
+# undef CONFIG_TIVA_GPIOH_IRQS
+#endif
+#if TIVA_NPORTS < 9
+# undef CONFIG_TIVA_GPIOJ_IRQS
+#endif
+#if TIVA_NPORTS < 10
+# undef CONFIG_TIVA_GPIOK_IRQS
+#endif
+#if TIVA_NPORTS < 11
+# undef CONFIG_TIVA_GPIOL_IRQS
+#endif
+#if TIVA_NPORTS < 12
+# undef CONFIG_TIVA_GPIOM_IRQS
+#endif
+#if TIVA_NPORTS < 13
+# undef CONFIG_TIVA_GPION_IRQS
+#endif
+#if TIVA_NPORTS < 14
+# undef CONFIG_TIVA_GPIOP_IRQS
+#endif
+#if TIVA_NPORTS < 15
+# undef CONFIG_TIVA_GPIOQ_IRQS
+#endif
+#if TIVA_NPORTS < 16
+# undef CONFIG_TIVA_GPIOQ_IRQS
+#endif
+#if TIVA_NPORTS < 17
+# undef CONFIG_TIVA_GPIOQ_IRQS
+#endif
+#if TIVA_NPORTS < 18
+# undef CONFIG_TIVA_GPIOQ_IRQS
#endif
/* Processor Exceptions (vectors 0-15) */
@@ -159,7 +170,7 @@
* be disabled in order to reduce the size of the implementation.
*/
-#if !defined(CONFIG_TIVA_DISABLE_GPIOA_IRQS)
+#if defined(CONFIG_TIVA_GPIOA_IRQS)
# define TIVA_IRQ_GPIOA_0 (NR_IRQS + 0)
# define TIVA_IRQ_GPIOA_1 (NR_IRQS + 1)
# define TIVA_IRQ_GPIOA_2 (NR_IRQS + 2)
@@ -173,7 +184,7 @@
# define _NGPIOAIRQS NR_IRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOB_IRQS)
+#if defined(CONFIG_TIVA_GPIOB_IRQS)
# define TIVA_IRQ_GPIOB_0 (_NGPIOAIRQS + 0)
# define TIVA_IRQ_GPIOB_1 (_NGPIOAIRQS + 1)
# define TIVA_IRQ_GPIOB_2 (_NGPIOAIRQS + 2)
@@ -187,7 +198,7 @@
# define _NGPIOBIRQS _NGPIOAIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOC_IRQS)
+#if defined(CONFIG_TIVA_GPIOC_IRQS)
# define TIVA_IRQ_GPIOC_0 (_NGPIOBIRQS + 0)
# define TIVA_IRQ_GPIOC_1 (_NGPIOBIRQS + 1)
# define TIVA_IRQ_GPIOC_2 (_NGPIOBIRQS + 2)
@@ -201,7 +212,7 @@
# define _NGPIOCIRQS _NGPIOBIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOD_IRQS)
+#if defined(CONFIG_TIVA_GPIOD_IRQS)
# define TIVA_IRQ_GPIOD_0 (_NGPIOCIRQS + 0)
# define TIVA_IRQ_GPIOD_1 (_NGPIOCIRQS + 1)
# define TIVA_IRQ_GPIOD_2 (_NGPIOCIRQS + 2)
@@ -215,7 +226,7 @@
# define _NGPIODIRQS _NGPIOCIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOE_IRQS)
+#if defined(CONFIG_TIVA_GPIOE_IRQS)
# define TIVA_IRQ_GPIOE_0 (_NGPIODIRQS + 0)
# define TIVA_IRQ_GPIOE_1 (_NGPIODIRQS + 1)
# define TIVA_IRQ_GPIOE_2 (_NGPIODIRQS + 2)
@@ -229,7 +240,7 @@
# define _NGPIOEIRQS _NGPIODIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOF_IRQS)
+#if defined(CONFIG_TIVA_GPIOF_IRQS)
# define TIVA_IRQ_GPIOF_0 (_NGPIOEIRQS + 0)
# define TIVA_IRQ_GPIOF_1 (_NGPIOEIRQS + 1)
# define TIVA_IRQ_GPIOF_2 (_NGPIOEIRQS + 2)
@@ -243,7 +254,7 @@
# define _NGPIOFIRQS _NGPIOEIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOG_IRQS)
+#if defined(CONFIG_TIVA_GPIOG_IRQS)
# define TIVA_IRQ_GPIOG_0 (_NGPIOFIRQS + 0)
# define TIVA_IRQ_GPIOG_1 (_NGPIOFIRQS + 1)
# define TIVA_IRQ_GPIOG_2 (_NGPIOFIRQS + 2)
@@ -257,7 +268,7 @@
# define _NGPIOGIRQS _NGPIOFIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOH_IRQS)
+#if defined(CONFIG_TIVA_GPIOH_IRQS)
# define TIVA_IRQ_GPIOH_0 (_NGPIOGIRQS + 0)
# define TIVA_IRQ_GPIOH_1 (_NGPIOGIRQS + 1)
# define TIVA_IRQ_GPIOH_2 (_NGPIOGIRQS + 2)
@@ -271,7 +282,7 @@
# define _NGPIOHIRQS _NGPIOGIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOJ_IRQS)
+#if defined(CONFIG_TIVA_GPIOJ_IRQS)
# define TIVA_IRQ_GPIOJ_0 (_NGPIOHIRQS + 0)
# define TIVA_IRQ_GPIOJ_1 (_NGPIOHIRQS + 1)
# define TIVA_IRQ_GPIOJ_2 (_NGPIOHIRQS + 2)
@@ -285,7 +296,7 @@
# define _NGPIOJIRQS _NGPIOHIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOK_IRQS)
+#if defined(CONFIG_TIVA_GPIOK_IRQS)
# define TIVA_IRQ_GPIOK_0 (_NGPIOJIRQS + 0)
# define TIVA_IRQ_GPIOK_1 (_NGPIOJIRQS + 1)
# define TIVA_IRQ_GPIOK_2 (_NGPIOJIRQS + 2)
@@ -299,7 +310,7 @@
# define _NGPIOKIRQS _NGPIOJIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOL_IRQS)
+#if defined(CONFIG_TIVA_GPIOL_IRQS)
# define TIVA_IRQ_GPIOL_0 (_NGPIOKIRQS + 0)
# define TIVA_IRQ_GPIOL_1 (_NGPIOKIRQS + 1)
# define TIVA_IRQ_GPIOL_2 (_NGPIOKIRQS + 2)
@@ -313,7 +324,7 @@
# define _NGPIOLIRQS _NGPIOKIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOM_IRQS)
+#if defined(CONFIG_TIVA_GPIOM_IRQS)
# define TIVA_IRQ_GPIOM_0 (_NGPIOLIRQS + 0)
# define TIVA_IRQ_GPIOM_1 (_NGPIOLIRQS + 1)
# define TIVA_IRQ_GPIOM_2 (_NGPIOLIRQS + 2)
@@ -327,7 +338,7 @@
# define _NGPIOMIRQS _NGPIOLIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPION_IRQS)
+#if defined(CONFIG_TIVA_GPION_IRQS)
# define TIVA_IRQ_GPION_0 (_NGPIOMIRQS + 0)
# define TIVA_IRQ_GPION_1 (_NGPIOMIRQS + 1)
# define TIVA_IRQ_GPION_2 (_NGPIOMIRQS + 2)
@@ -341,7 +352,7 @@
# define _NGPIONIRQS _NGPIOMIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOP_IRQS)
+#if defined(CONFIG_TIVA_GPIOP_IRQS)
# define TIVA_IRQ_GPIOP_0 (_NGPIONIRQS + 0)
# define TIVA_IRQ_GPIOP_1 (_NGPIONIRQS + 1)
# define TIVA_IRQ_GPIOP_2 (_NGPIONIRQS + 2)
@@ -355,7 +366,7 @@
# define _NGPIOPIRQS _NGPIONIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOQ_IRQS)
+#if defined(CONFIG_TIVA_GPIOQ_IRQS)
# define TIVA_IRQ_GPIOQ_0 (_NGPIOPIRQS + 0)
# define TIVA_IRQ_GPIOQ_1 (_NGPIOPIRQS + 1)
# define TIVA_IRQ_GPIOQ_2 (_NGPIOPIRQS + 2)
@@ -369,7 +380,7 @@
# define _NGPIOQIRQS _NGPIOPIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOR_IRQS)
+#if defined(CONFIG_TIVA_GPIOR_IRQS)
# define TIVA_IRQ_GPIOR_0 (_NGPIOQIRQS + 0)
# define TIVA_IRQ_GPIOR_1 (_NGPIOQIRQS + 1)
# define TIVA_IRQ_GPIOR_2 (_NGPIOQIRQS + 2)
@@ -383,7 +394,7 @@
# define _NGPIORIRQS _NGPIOQIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOS_IRQS)
+#if defined(CONFIG_TIVA_GPIOS_IRQS)
# define TIVA_IRQ_GPIOS_0 (_NGPIORIRQS + 0)
# define TIVA_IRQ_GPIOS_1 (_NGPIORIRQS + 1)
# define TIVA_IRQ_GPIOS_2 (_NGPIORIRQS + 2)
@@ -397,7 +408,7 @@
# define _NGPIOSIRQS _NGPIORIRQS
#endif
-#if !defined(CONFIG_TIVA_DISABLE_GPIOT_IRQS)
+#if defined(CONFIG_TIVA_GPIOT_IRQS)
# define TIVA_IRQ_GPIOT_0 (_NGPIOSIRQS + 0)
# define TIVA_IRQ_GPIOT_1 (_NGPIOSIRQS + 1)
# define TIVA_IRQ_GPIOT_2 (_NGPIOSIRQS + 2)
diff --git a/nuttx/arch/arm/src/tiva/Kconfig b/nuttx/arch/arm/src/tiva/Kconfig
index a2c5e1476..341df871a 100644
--- a/nuttx/arch/arm/src/tiva/Kconfig
+++ b/nuttx/arch/arm/src/tiva/Kconfig
@@ -262,73 +262,110 @@ config TIVA_FLASH
endmenu
-menu "Disable GPIO Interrupts"
+menu "Enable GPIO Interrupts"
-config TIVA_DISABLE_GPIOA_IRQS
- bool "Disable GPIOA IRQs"
+config TIVA_GPIO_IRQS
+ bool
+ default n
+
+config TIVA_GPIOA_IRQS
+ bool "Enable GPIOA IRQs"
+ default n
+ select TIVA_GPIO_IRQS
+
+config TIVA_GPIOB_IRQS
+ bool "Enable GPIOB IRQs"
+ default n
+ select TIVA_GPIO_IRQS
+
+config TIVA_GPIOC_IRQS
+ bool "Enable GPIOC IRQs"
+ default n
+ select TIVA_GPIO_IRQS
+
+config TIVA_GPIOD_IRQS
+ bool "Enable GPIOD IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOB_IRQS
- bool "Disable GPIOB IRQs"
+config TIVA_GPIOE_IRQS
+ bool "Enable GPIOE IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOC_IRQS
- bool "Disable GPIOC IRQs"
+config TIVA_GPIOF_IRQS
+ bool "Enable GPIOF IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOD_IRQS
- bool "Disable GPIOD IRQs"
+config TIVA_GPIOG_IRQS
+ bool "Enable GPIOG IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOE_IRQS
- bool "Disable GPIOE IRQs"
+config TIVA_GPIOH_IRQS
+ bool "Enable GPIOH IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOF_IRQS
- bool "Disable GPIOF IRQs"
+config TIVA_GPIOJ_IRQS
+ bool "Enable GPIOJ IRQs"
default n
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOG_IRQS
- bool "Disable GPIOG IRQs"
+config TIVA_GPIOK_IRQS
+ bool "Enable GPIOK IRQs"
default n
+ depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOH_IRQS
- bool "Disable GPIOH IRQs"
+config TIVA_GPIOL_IRQS
+ bool "Enable GPIOL IRQs"
default n
+ depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOJ_IRQS
- bool "Disable GPIOJ IRQs"
+config TIVA_GPIOM_IRQS
+ bool "Enable GPIOM IRQs"
default n
+ depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOK_IRQS
- bool "Disable GPIOK IRQs"
+config TIVA_GPION_IRQS
+ bool "Enable GPION IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOL_IRQS
- bool "Disable GPIOL IRQs"
+config TIVA_GPIOP_IRQS
+ bool "Enable GPIOP IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOM_IRQS
- bool "Disable GPIOM IRQs"
+config TIVA_GPIOQ_IRQS
+ bool "Enable GPIOQ IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPION_IRQS
- bool "Disable GPION IRQs"
+config TIVA_GPIOR_IRQS
+ bool "Enable GPIOR IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOP_IRQS
- bool "Disable GPIOP IRQs"
+config TIVA_GPIOS_IRQS
+ bool "Enable GPIOS IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
-config TIVA_DISABLE_GPIOQ_IRQS
- bool "Disable GPIOQ IRQs"
+config TIVA_GPIOT_IRQS
+ bool "Enable GPIOT IRQs"
default n
depends on ARCH_CHIP_TM4C
+ select TIVA_GPIO_IRQS
endmenu
diff --git a/nuttx/arch/arm/src/tiva/tiva_gpioirq.c b/nuttx/arch/arm/src/tiva/tiva_gpioirq.c
index bb50df4ab..4bc4d4974 100644
--- a/nuttx/arch/arm/src/tiva/tiva_gpioirq.c
+++ b/nuttx/arch/arm/src/tiva/tiva_gpioirq.c
@@ -71,92 +71,92 @@ static FAR xcpt_t g_gpioirqvector[NR_GPIO_IRQS];
#define COMMA
static const uintptr_t g_gpiobase[] =
{
-#ifndef CONFIG_TIVA_DISABLE_GPIOA_IRQS
+#ifdef CONFIG_TIVA_GPIOA_IRQS
COMMA TIVA_GPIOA_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOB_IRQS
+#ifdef CONFIG_TIVA_GPIOB_IRQS
COMMA TIVA_GPIOB_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOC_IRQS
+#ifdef CONFIG_TIVA_GPIOC_IRQS
COMMA TIVA_GPIOC_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOD_IRQS
+#ifdef CONFIG_TIVA_GPIOD_IRQS
COMMA TIVA_GPIOD_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOE_IRQS
+#ifdef CONFIG_TIVA_GPIOE_IRQS
COMMA TIVA_GPIOE_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOF_IRQS
+#ifdef CONFIG_TIVA_GPIOF_IRQS
COMMA TIVA_GPIOF_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOG_IRQS
+#ifdef CONFIG_TIVA_GPIOG_IRQS
COMMA TIVA_GPIOG_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOH_IRQS
+#ifdef CONFIG_TIVA_GPIOH_IRQS
COMMA TIVA_GPIOH_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOJ_IRQS
+#ifdef CONFIG_TIVA_GPIOJ_IRQS
COMMA TIVA_GPIOJ_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOK_IRQS
+#ifdef CONFIG_TIVA_GPIOK_IRQS
COMMA TIVA_GPIOK_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOL_IRQS
+#ifdef CONFIG_TIVA_GPIOL_IRQS
COMMA TIVA_GPIOL_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOM_IRQS
+#ifdef CONFIG_TIVA_GPIOM_IRQS
COMMA TIVA_GPIOM_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPION_IRQS
+#ifdef CONFIG_TIVA_GPION_IRQS
COMMA TIVA_GPION_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOP_IRQS
+#ifdef CONFIG_TIVA_GPIOP_IRQS
COMMA TIVA_GPIOP_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOQ_IRQS
+#ifdef CONFIG_TIVA_GPIOQ_IRQS
COMMA TIVA_GPIOQ_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOR_IRQS
+#ifdef CONFIG_TIVA_GPIOR_IRQS
COMMA TIVA_GPIOR_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOS_IRQS
+#ifdef CONFIG_TIVA_GPIOS_IRQS
COMMA TIVA_GPIOS_BASE
#undef COMMA
#define COMMA ,
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOT_IRQS
+#ifdef CONFIG_TIVA_GPIOT_IRQS
COMMA TIVA_GPIOT_BASE
#undef COMMA
#define COMMA ,
@@ -240,126 +240,126 @@ static int tiva_gpiohandler(uint32_t regbase, int irqbase, void *context)
return OK;
}
-#ifndef CONFIG_TIVA_DISABLE_GPIOA_IRQS
+#ifdef CONFIG_TIVA_GPIOA_IRQS
static int tiva_gpioahandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOA_BASE, TIVA_IRQ_GPIOA_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOB_IRQS
+#ifdef CONFIG_TIVA_GPIOB_IRQS
static int tiva_gpiobhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOB_BASE, TIVA_IRQ_GPIOB_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOC_IRQS
+#ifdef CONFIG_TIVA_GPIOC_IRQS
static int tiva_gpiochandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOC_BASE, TIVA_IRQ_GPIOC_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOD_IRQS
+#ifdef CONFIG_TIVA_GPIOD_IRQS
static int tiva_gpiodhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOD_BASE, TIVA_IRQ_GPIOD_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOE_IRQS
+#ifdef CONFIG_TIVA_GPIOE_IRQS
static int tiva_gpioehandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOE_BASE, TIVA_IRQ_GPIOE_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOF_IRQS
+#ifdef CONFIG_TIVA_GPIOF_IRQS
static int tiva_gpiofhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOF_BASE, TIVA_IRQ_GPIOF_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOG_IRQS
+#ifdef CONFIG_TIVA_GPIOG_IRQS
static int tiva_gpioghandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOG_BASE, TIVA_IRQ_GPIOG_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOH_IRQS
+#ifdef CONFIG_TIVA_GPIOH_IRQS
static int tiva_gpiohhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOH_BASE, TIVA_IRQ_GPIOH_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOJ_IRQS
+#ifdef CONFIG_TIVA_GPIOJ_IRQS
static int tiva_gpiojhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOJ_BASE, TIVA_IRQ_GPIOJ_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOK_IRQS
+#ifdef CONFIG_TIVA_GPIOK_IRQS
static int tiva_gpiokhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOK_BASE, TIVA_IRQ_GPIOK_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOL_IRQS
+#ifdef CONFIG_TIVA_GPIOL_IRQS
static int tiva_gpiolhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOL_BASE, TIVA_IRQ_GPIOL_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOM_IRQS
+#ifdef CONFIG_TIVA_GPIOM_IRQS
static int tiva_gpiomhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOM_BASE, TIVA_IRQ_GPIOM_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPION_IRQS
+#ifdef CONFIG_TIVA_GPION_IRQS
static int tiva_gpionhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPION_BASE, TIVA_IRQ_GPION_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOP_IRQS
+#ifdef CONFIG_TIVA_GPIOP_IRQS
static int tiva_gpiophandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOP_BASE, TIVA_IRQ_GPIOP_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOQ_IRQS
+#ifdef CONFIG_TIVA_GPIOQ_IRQS
static int tiva_gpioqhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOQ_BASE, TIVA_IRQ_GPIOQ_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOR_IRQS
+#ifdef CONFIG_TIVA_GPIOR_IRQS
static int tiva_gpiorhandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOR_BASE, TIVA_IRQ_GPIOR_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOS_IRQS
+#ifdef CONFIG_TIVA_GPIOS_IRQS
static int tiva_gpioshandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOS_BASE, TIVA_IRQ_GPIOS_0, context);
}
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOT_IRQS
+#ifdef CONFIG_TIVA_GPIOT_IRQS
static int tiva_gpiothandler(int irq, FAR void *context)
{
return tiva_gpiohandler(TIVA_GPIOT_BASE, TIVA_IRQ_GPIOT_0, context);
@@ -393,75 +393,75 @@ int gpio_irqinitialize(void)
* interrupts
*/
-#ifndef CONFIG_TIVA_DISABLE_GPIOA_IRQS
+#ifdef CONFIG_TIVA_GPIOA_IRQS
irq_attach(TIVA_IRQ_GPIOA, tiva_gpioahandler);
up_enable_irq(TIVA_IRQ_GPIOA);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOB_IRQS
+#ifdef CONFIG_TIVA_GPIOB_IRQS
irq_attach(TIVA_IRQ_GPIOB, tiva_gpiobhandler);
up_enable_irq(TIVA_IRQ_GPIOB);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOC_IRQS
+#ifdef CONFIG_TIVA_GPIOC_IRQS
irq_attach(TIVA_IRQ_GPIOC, tiva_gpiochandler);
up_enable_irq(TIVA_IRQ_GPIOC);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOD_IRQS
+#ifdef CONFIG_TIVA_GPIOD_IRQS
irq_attach(TIVA_IRQ_GPIOD, tiva_gpiodhandler);
up_enable_irq(TIVA_IRQ_GPIOD);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOE_IRQS
+#ifdef CONFIG_TIVA_GPIOE_IRQS
irq_attach(TIVA_IRQ_GPIOE, tiva_gpioehandler);
up_enable_irq(TIVA_IRQ_GPIOE);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOF_IRQS
+#ifdef CONFIG_TIVA_GPIOF_IRQS
irq_attach(TIVA_IRQ_GPIOF, tiva_gpiofhandler);
up_enable_irq(TIVA_IRQ_GPIOF);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOG_IRQS
+#ifdef CONFIG_TIVA_GPIOG_IRQS
irq_attach(TIVA_IRQ_GPIOG, tiva_gpioghandler);
up_enable_irq(TIVA_IRQ_GPIOG);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOH_IRQS
+#ifdef CONFIG_TIVA_GPIOH_IRQS
irq_attach(TIVA_IRQ_GPIOH, tiva_gpiohhandler);
up_enable_irq(TIVA_IRQ_GPIOH);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOJ_IRQS
+#ifdef CONFIG_TIVA_GPIOJ_IRQS
irq_attach(TIVA_IRQ_GPIOJ, tiva_gpiojhandler);
up_enable_irq(TIVA_IRQ_GPIOJ);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOK_IRQS
+#ifdef CONFIG_TIVA_GPIOK_IRQS
irq_attach(TIVA_IRQ_GPIOK, tiva_gpiokhandler);
up_enable_irq(TIVA_IRQ_GPIOK);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOL_IRQS
+#ifdef CONFIG_TIVA_GPIOL_IRQS
irq_attach(TIVA_IRQ_GPIOL, tiva_gpiolhandler);
up_enable_irq(TIVA_IRQ_GPIOL);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOM_IRQS
+#ifdef CONFIG_TIVA_GPIOM_IRQS
irq_attach(TIVA_IRQ_GPIOM, tiva_gpiomhandler);
up_enable_irq(TIVA_IRQ_GPIOM);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPION_IRQS
+#ifdef CONFIG_TIVA_GPION_IRQS
irq_attach(TIVA_IRQ_GPION, tiva_gpionhandler);
up_enable_irq(TIVA_IRQ_GPION);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOP_IRQS
+#ifdef CONFIG_TIVA_GPIOP_IRQS
irq_attach(TIVA_IRQ_GPIOP, tiva_gpiophandler);
up_enable_irq(TIVA_IRQ_GPIOP);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOQ_IRQS
+#ifdef CONFIG_TIVA_GPIOQ_IRQS
irq_attach(TIVA_IRQ_GPIOQ, tiva_gpioqhandler);
up_enable_irq(TIVA_IRQ_GPIOQ);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOR_IRQS
+#ifdef CONFIG_TIVA_GPIOR_IRQS
irq_attach(TIVA_IRQ_GPIOR, tiva_gpiorhandler);
up_enable_irq(TIVA_IRQ_GPIOR);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOS_IRQS
+#ifdef CONFIG_TIVA_GPIOS_IRQS
irq_attach(TIVA_IRQ_GPIOS, tiva_gpioshandler);
up_enable_irq(TIVA_IRQ_GPIOS);
#endif
-#ifndef CONFIG_TIVA_DISABLE_GPIOT_IRQS
+#ifdef CONFIG_TIVA_GPIOT_IRQS
irq_attach(TIVA_IRQ_GPIOT, tiva_gpiothandler);
up_enable_irq(TIVA_IRQ_GPIOT);
#endif
diff --git a/nuttx/arch/arm/src/tiva/tiva_irq.c b/nuttx/arch/arm/src/tiva/tiva_irq.c
index b6048c79f..e3bde7d4e 100644
--- a/nuttx/arch/arm/src/tiva/tiva_irq.c
+++ b/nuttx/arch/arm/src/tiva/tiva_irq.c
@@ -351,7 +351,7 @@ void up_irqinitialize(void)
/* Initialize support for GPIO interrupts if included in this build */
-#ifndef CONFIG_TIVA_DISABLE_GPIO_IRQS
+#ifdef CONFIG_TIVA_GPIO_IRQS
#ifdef CONFIG_HAVE_WEAKFUNCTIONS
if (gpio_irqinitialize != NULL)
#endif