From 87bd05d78f0f5765f3d3e1517c76794c82dab7cc Mon Sep 17 00:00:00 2001 From: Axel Lin Date: Fri, 21 Jun 2013 18:54:25 +0800 Subject: ARM: OMAP: GPIO: Fix valid range and enable usage of all GPIOs on OMAP5 The omap_gpio driver is used by AM33XX, OMAP3/4, OMAP54XX and DRA7XX SoCs. These SoCs have different gpio count but currently omap_gpio driver uses hard coded 192 which is wrong. This patch fixes this issue by: 1. Move define of OMAP_MAX_GPIO to all arch/arm/include/asm/arch-omap*/gpio.h. 2. Update gpio bank settings and enable GPIO modules 7 & 8 clocks for OMAP5. Thanks for Lubomir Popov to provide valuable comments to fix this issue. Signed-off-by: Axel Lin Tested-by: Lubomir Popov Acked-by: Heiko Schocher --- arch/arm/include/asm/arch-omap4/gpio.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'arch/arm/include/asm/arch-omap4/gpio.h') diff --git a/arch/arm/include/asm/arch-omap4/gpio.h b/arch/arm/include/asm/arch-omap4/gpio.h index 26f19d1..fdf65ed 100644 --- a/arch/arm/include/asm/arch-omap4/gpio.h +++ b/arch/arm/include/asm/arch-omap4/gpio.h @@ -40,6 +40,8 @@ #include +#define OMAP_MAX_GPIO 192 + #define OMAP44XX_GPIO1_BASE 0x4A310000 #define OMAP44XX_GPIO2_BASE 0x48055000 #define OMAP44XX_GPIO3_BASE 0x48057000 -- cgit v1.1