diff options
| author | Takashi YOSHII <takashi.yoshii.zj@renesas.com> | 2010-11-19 02:49:38 -0500 |
|---|---|---|
| committer | Paul Mundt <lethal@linux-sh.org> | 2010-11-19 02:49:38 -0500 |
| commit | 3256c789882281b2eac5978c7d38f6f0bbd16ed6 (patch) | |
| tree | 632b6b39d820258c64b00004be4e3332295996c4 | |
| parent | 1cdf370244d5f0a4cf5ed672967cc2e16235908d (diff) | |
ARM: mach-shmobile: ag5evm: use gpio.
Ag5evm board now uses gpio api to initialize pins and peripherals.
Signed-off-by: Takashi YOSHII <takashi.yoshii.zj@renesas.com>
Signed-off-by: Paul Mundt <lethal@linux-sh.org>
| -rw-r--r-- | arch/arm/mach-shmobile/Kconfig | 1 | ||||
| -rw-r--r-- | arch/arm/mach-shmobile/board-ag5evm.c | 17 |
2 files changed, 11 insertions, 7 deletions
diff --git a/arch/arm/mach-shmobile/Kconfig b/arch/arm/mach-shmobile/Kconfig index 2910ba282482..7d56e86c75e0 100644 --- a/arch/arm/mach-shmobile/Kconfig +++ b/arch/arm/mach-shmobile/Kconfig | |||
| @@ -61,6 +61,7 @@ endchoice | |||
| 61 | config MACH_AG5EVM | 61 | config MACH_AG5EVM |
| 62 | bool "AG5EVM board" | 62 | bool "AG5EVM board" |
| 63 | depends on ARCH_SH73A0 | 63 | depends on ARCH_SH73A0 |
| 64 | select ARCH_REQUIRE_GPIOLIB | ||
| 64 | 65 | ||
| 65 | comment "SH-Mobile System Configuration" | 66 | comment "SH-Mobile System Configuration" |
| 66 | 67 | ||
diff --git a/arch/arm/mach-shmobile/board-ag5evm.c b/arch/arm/mach-shmobile/board-ag5evm.c index bade04accc80..e0bc0811dc48 100644 --- a/arch/arm/mach-shmobile/board-ag5evm.c +++ b/arch/arm/mach-shmobile/board-ag5evm.c | |||
| @@ -121,16 +121,19 @@ void __init ag5evm_init_irq(void) | |||
| 121 | 121 | ||
| 122 | static void __init ag5evm_init(void) | 122 | static void __init ag5evm_init(void) |
| 123 | { | 123 | { |
| 124 | sh73a0_pinmux_init(); | ||
| 125 | |||
| 124 | /* enable SCIFA2 */ | 126 | /* enable SCIFA2 */ |
| 125 | __raw_writeb(0x12, PORT154CR); /* TXD */ | 127 | gpio_request(GPIO_FN_SCIFA2_TXD1, NULL); |
| 126 | __raw_writeb(0x22, PORT155CR); /* RXD */ | 128 | gpio_request(GPIO_FN_SCIFA2_RXD1, NULL); |
| 127 | __raw_writeb(0x12, PORT156CR); /* RTS */ | 129 | gpio_request(GPIO_FN_SCIFA2_RTS1_, NULL); |
| 128 | __raw_writeb(0x22, PORT157CR); /* CTS */ | 130 | gpio_request(GPIO_FN_SCIFA2_CTS1_, NULL); |
| 129 | 131 | ||
| 130 | /* enable SMSC911X */ | 132 | /* enable SMSC911X */ |
| 131 | __raw_writeb(0x20, PORT144CR); /* PINTA2 */ | 133 | gpio_request(GPIO_PORT144, NULL); /* PINTA2 */ |
| 132 | __raw_writeb(0x10, PORT145CR); /* RESET */ | 134 | gpio_direction_input(GPIO_PORT144); |
| 133 | __raw_writel(__raw_readl(PORTR159_128DR) & ~(1 << 17), PORTR159_128DR); | 135 | gpio_request(GPIO_PORT145, NULL); /* RESET */ |
| 136 | gpio_direction_output(GPIO_PORT145, 1); | ||
| 134 | 137 | ||
| 135 | #ifdef CONFIG_CACHE_L2X0 | 138 | #ifdef CONFIG_CACHE_L2X0 |
| 136 | /* Shared attribute override enable, 64K*8way */ | 139 | /* Shared attribute override enable, 64K*8way */ |
