aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-omap1
diff options
context:
space:
mode:
authorKevin Hilman <khilman@ti.com>2011-04-21 12:53:06 -0400
committerKevin Hilman <khilman@ti.com>2011-06-16 14:13:51 -0400
commit28f3b5a073b6dbafbb78cae65b22ea90547d7a87 (patch)
tree7e4f1ce8067c39d50c84081a26dec08143edff8c /arch/arm/mach-omap1
parenteef4bec7bf2fa9953f6b8f371d5914d014f45d40 (diff)
gpio/omap: conslidate enable/disable of GPIO IRQs, remove ifdefs
Cleanup GPIO IRQ enable/disable handling by removing SoC-specific Also split enable/disable IRQ into separate functions for better readability and also facilitate potentially moving to generic irq_chip in the future. Signed-off-by: Kevin Hilman <khilman@ti.com>
Diffstat (limited to 'arch/arm/mach-omap1')
-rw-r--r--arch/arm/mach-omap1/gpio15xx.c4
-rw-r--r--arch/arm/mach-omap1/gpio16xx.c5
-rw-r--r--arch/arm/mach-omap1/gpio7xx.c4
3 files changed, 13 insertions, 0 deletions
diff --git a/arch/arm/mach-omap1/gpio15xx.c b/arch/arm/mach-omap1/gpio15xx.c
index 487a08749655..91756245e860 100644
--- a/arch/arm/mach-omap1/gpio15xx.c
+++ b/arch/arm/mach-omap1/gpio15xx.c
@@ -39,6 +39,8 @@ static struct omap_gpio_reg_offs omap15xx_mpuio_regs = {
39 .datain = OMAP_MPUIO_INPUT_LATCH, 39 .datain = OMAP_MPUIO_INPUT_LATCH,
40 .dataout = OMAP_MPUIO_OUTPUT, 40 .dataout = OMAP_MPUIO_OUTPUT,
41 .irqstatus = OMAP_MPUIO_GPIO_INT, 41 .irqstatus = OMAP_MPUIO_GPIO_INT,
42 .irqenable = OMAP_MPUIO_GPIO_MASKIT,
43 .irqenable_inv = true,
42}; 44};
43 45
44static struct __initdata omap_gpio_platform_data omap15xx_mpu_gpio_config = { 46static struct __initdata omap_gpio_platform_data omap15xx_mpu_gpio_config = {
@@ -77,6 +79,8 @@ static struct omap_gpio_reg_offs omap15xx_gpio_regs = {
77 .datain = OMAP1510_GPIO_DATA_INPUT, 79 .datain = OMAP1510_GPIO_DATA_INPUT,
78 .dataout = OMAP1510_GPIO_DATA_OUTPUT, 80 .dataout = OMAP1510_GPIO_DATA_OUTPUT,
79 .irqstatus = OMAP1510_GPIO_INT_STATUS, 81 .irqstatus = OMAP1510_GPIO_INT_STATUS,
82 .irqenable = OMAP1510_GPIO_INT_MASK,
83 .irqenable_inv = true,
80}; 84};
81 85
82static struct __initdata omap_gpio_platform_data omap15xx_gpio_config = { 86static struct __initdata omap_gpio_platform_data omap15xx_gpio_config = {
diff --git a/arch/arm/mach-omap1/gpio16xx.c b/arch/arm/mach-omap1/gpio16xx.c
index 3e52b7f3d9cb..a6d4a71ea4af 100644
--- a/arch/arm/mach-omap1/gpio16xx.c
+++ b/arch/arm/mach-omap1/gpio16xx.c
@@ -42,6 +42,8 @@ static struct omap_gpio_reg_offs omap16xx_mpuio_regs = {
42 .datain = OMAP_MPUIO_INPUT_LATCH, 42 .datain = OMAP_MPUIO_INPUT_LATCH,
43 .dataout = OMAP_MPUIO_OUTPUT, 43 .dataout = OMAP_MPUIO_OUTPUT,
44 .irqstatus = OMAP_MPUIO_GPIO_INT, 44 .irqstatus = OMAP_MPUIO_GPIO_INT,
45 .irqenable = OMAP_MPUIO_GPIO_MASKIT,
46 .irqenable_inv = true,
45}; 47};
46 48
47static struct __initdata omap_gpio_platform_data omap16xx_mpu_gpio_config = { 49static struct __initdata omap_gpio_platform_data omap16xx_mpu_gpio_config = {
@@ -82,6 +84,9 @@ static struct omap_gpio_reg_offs omap16xx_gpio_regs = {
82 .datain = OMAP1610_GPIO_DATAIN, 84 .datain = OMAP1610_GPIO_DATAIN,
83 .dataout = OMAP1610_GPIO_DATAOUT, 85 .dataout = OMAP1610_GPIO_DATAOUT,
84 .irqstatus = OMAP1610_GPIO_IRQSTATUS1, 86 .irqstatus = OMAP1610_GPIO_IRQSTATUS1,
87 .irqenable = OMAP1610_GPIO_IRQENABLE1,
88 .set_irqenable = OMAP1610_GPIO_SET_IRQENABLE1,
89 .clr_irqenable = OMAP1610_GPIO_CLEAR_IRQENABLE1,
85}; 90};
86 91
87static struct __initdata omap_gpio_platform_data omap16xx_gpio1_config = { 92static struct __initdata omap_gpio_platform_data omap16xx_gpio1_config = {
diff --git a/arch/arm/mach-omap1/gpio7xx.c b/arch/arm/mach-omap1/gpio7xx.c
index 35e8b31688d0..12bcd9f2864a 100644
--- a/arch/arm/mach-omap1/gpio7xx.c
+++ b/arch/arm/mach-omap1/gpio7xx.c
@@ -44,6 +44,8 @@ static struct omap_gpio_reg_offs omap7xx_mpuio_regs = {
44 .datain = OMAP_MPUIO_INPUT_LATCH / 2, 44 .datain = OMAP_MPUIO_INPUT_LATCH / 2,
45 .dataout = OMAP_MPUIO_OUTPUT / 2, 45 .dataout = OMAP_MPUIO_OUTPUT / 2,
46 .irqstatus = OMAP_MPUIO_GPIO_INT / 2, 46 .irqstatus = OMAP_MPUIO_GPIO_INT / 2,
47 .irqenable = OMAP_MPUIO_GPIO_MASKIT / 2,
48 .irqenable_inv = true,
47}; 49};
48 50
49static struct __initdata omap_gpio_platform_data omap7xx_mpu_gpio_config = { 51static struct __initdata omap_gpio_platform_data omap7xx_mpu_gpio_config = {
@@ -82,6 +84,8 @@ static struct omap_gpio_reg_offs omap7xx_gpio_regs = {
82 .datain = OMAP7XX_GPIO_DATA_INPUT, 84 .datain = OMAP7XX_GPIO_DATA_INPUT,
83 .dataout = OMAP7XX_GPIO_DATA_OUTPUT, 85 .dataout = OMAP7XX_GPIO_DATA_OUTPUT,
84 .irqstatus = OMAP7XX_GPIO_INT_STATUS, 86 .irqstatus = OMAP7XX_GPIO_INT_STATUS,
87 .irqenable = OMAP7XX_GPIO_INT_MASK,
88 .irqenable_inv = true,
85}; 89};
86 90
87static struct __initdata omap_gpio_platform_data omap7xx_gpio1_config = { 91static struct __initdata omap_gpio_platform_data omap7xx_gpio1_config = {