From 4cae90b75bf38e18f1ae336b91dfc52027e1c5a5 Mon Sep 17 00:00:00 2001 From: juhosg Date: Tue, 31 May 2011 22:53:30 +0000 Subject: ar71xx: enable GPIO support for the AR933x SoCs git-svn-id: svn://svn.openwrt.org/openwrt/trunk@27057 3c298f89-4303-0410-b956-a3cf2f4a3e73 --- target/linux/ar71xx/files/arch/mips/ar71xx/gpio.c | 9 +++++++-- .../ar71xx/files/arch/mips/include/asm/mach-ar71xx/ar71xx.h | 2 ++ 2 files changed, 9 insertions(+), 2 deletions(-) (limited to 'target/linux/ar71xx/files') diff --git a/target/linux/ar71xx/files/arch/mips/ar71xx/gpio.c b/target/linux/ar71xx/files/arch/mips/ar71xx/gpio.c index 0ee684700..10d80817f 100644 --- a/target/linux/ar71xx/files/arch/mips/ar71xx/gpio.c +++ b/target/linux/ar71xx/files/arch/mips/ar71xx/gpio.c @@ -1,7 +1,7 @@ /* - * Atheros AR71xx SoC GPIO API support + * Atheros AR7XXX/AR9XXX SoC GPIO API support * - * Copyright (C) 2008-2010 Gabor Juhos + * Copyright (C) 2008-2011 Gabor Juhos * Copyright (C) 2008 Imre Kaloz * * This program is free software; you can redistribute it and/or modify it @@ -172,6 +172,11 @@ void __init ar71xx_gpio_init(void) ar71xx_gpio_chip.ngpio = AR91XX_GPIO_COUNT; break; + case AR71XX_SOC_AR9330: + case AR71XX_SOC_AR9331: + ar71xx_gpio_chip.ngpio = AR933X_GPIO_COUNT; + break; + case AR71XX_SOC_AR9341: case AR71XX_SOC_AR9342: case AR71XX_SOC_AR9344: diff --git a/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/ar71xx.h b/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/ar71xx.h index 759c8e6ab..6d43e2515 100644 --- a/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/ar71xx.h +++ b/target/linux/ar71xx/files/arch/mips/include/asm/mach-ar71xx/ar71xx.h @@ -455,6 +455,8 @@ static inline u32 ar71xx_usb_ctrl_rr(unsigned reg) #define AR91XX_GPIO_COUNT 22 +#define AR933X_GPIO_COUNT 30 + #define AR934X_GPIO_FUNC_SPI_CS_1_EN BIT(14) #define AR934X_GPIO_FUNC_SPI_CS_0_EN BIT(13) -- cgit v1.2.3