summaryrefslogtreecommitdiff
path: root/arch/arm/mach-imx/devices/platform-gpio-mxc.c
diff options
context:
space:
mode:
Diffstat (limited to 'arch/arm/mach-imx/devices/platform-gpio-mxc.c')
-rw-r--r--arch/arm/mach-imx/devices/platform-gpio-mxc.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/arch/arm/mach-imx/devices/platform-gpio-mxc.c b/arch/arm/mach-imx/devices/platform-gpio-mxc.c
index 78628ef12672..355de845224c 100644
--- a/arch/arm/mach-imx/devices/platform-gpio-mxc.c
+++ b/arch/arm/mach-imx/devices/platform-gpio-mxc.c
@@ -24,7 +24,8 @@ struct platform_device *__init mxc_register_gpio(char *name, int id,
.flags = IORESOURCE_IRQ,
},
};
+ unsigned int nres;
- return platform_device_register_resndata(&mxc_aips_bus,
- name, id, res, ARRAY_SIZE(res), NULL, 0);
+ nres = irq_high ? ARRAY_SIZE(res) : ARRAY_SIZE(res) - 1;
+ return platform_device_register_resndata(&mxc_aips_bus, name, id, res, nres, NULL, 0);
}