aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJochen Friedrich <jochen@scram.de>2011-08-18 16:53:57 -0400
committerRussell King <rmk+kernel@arm.linux.org.uk>2011-10-17 04:12:41 -0400
commitf24dec9fdafadca53bf9db460da2cbbbfccdb584 (patch)
treef0895b019d633ba98bca4eb0830b2010ef5c0092
parentb380ab4f85d641574d91b12b333848a0731a497c (diff)
ARM: 7027/1: simpad: Add ucb1x00 GPIO definitions and register GPIO
Add ucb1x00 GPIO definitions to simpad.h and add gpio_base to ucb1x00 platform device so the pins are available using the GPIO API. Signed-off-by: Jochen Friedrich <jochen@scram.de> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
-rw-r--r--arch/arm/mach-sa1100/include/mach/simpad.h13
-rw-r--r--arch/arm/mach-sa1100/simpad.c1
2 files changed, 14 insertions, 0 deletions
diff --git a/arch/arm/mach-sa1100/include/mach/simpad.h b/arch/arm/mach-sa1100/include/mach/simpad.h
index 9296c4513ce1..231550da7db8 100644
--- a/arch/arm/mach-sa1100/include/mach/simpad.h
+++ b/arch/arm/mach-sa1100/include/mach/simpad.h
@@ -48,6 +48,19 @@
48#define GPIO_SMART_CARD GPIO_GPIO10 48#define GPIO_SMART_CARD GPIO_GPIO10
49#define IRQ_GPIO_SMARD_CARD IRQ_GPIO10 49#define IRQ_GPIO_SMARD_CARD IRQ_GPIO10
50 50
51/*--- ucb1x00 GPIO ---*/
52#define SIMPAD_UCB1X00_GPIO_BASE (GPIO_MAX + 1)
53#define SIMPAD_UCB1X00_GPIO_PROG1 (SIMPAD_UCB1X00_GPIO_BASE)
54#define SIMPAD_UCB1X00_GPIO_PROG2 (SIMPAD_UCB1X00_GPIO_BASE + 1)
55#define SIMPAD_UCB1X00_GPIO_UP (SIMPAD_UCB1X00_GPIO_BASE + 2)
56#define SIMPAD_UCB1X00_GPIO_DOWN (SIMPAD_UCB1X00_GPIO_BASE + 3)
57#define SIMPAD_UCB1X00_GPIO_LEFT (SIMPAD_UCB1X00_GPIO_BASE + 4)
58#define SIMPAD_UCB1X00_GPIO_RIGHT (SIMPAD_UCB1X00_GPIO_BASE + 5)
59#define SIMPAD_UCB1X00_GPIO_6 (SIMPAD_UCB1X00_GPIO_BASE + 6)
60#define SIMPAD_UCB1X00_GPIO_7 (SIMPAD_UCB1X00_GPIO_BASE + 7)
61#define SIMPAD_UCB1X00_GPIO_HEADSET (SIMPAD_UCB1X00_GPIO_BASE + 8)
62#define SIMPAD_UCB1X00_GPIO_SPEAKER (SIMPAD_UCB1X00_GPIO_BASE + 9)
63
51// CS3 Latch is write only, a shadow is necessary 64// CS3 Latch is write only, a shadow is necessary
52 65
53#define CS3BUSTYPE unsigned volatile long 66#define CS3BUSTYPE unsigned volatile long
diff --git a/arch/arm/mach-sa1100/simpad.c b/arch/arm/mach-sa1100/simpad.c
index cfb76077bd25..718b802bbff3 100644
--- a/arch/arm/mach-sa1100/simpad.c
+++ b/arch/arm/mach-sa1100/simpad.c
@@ -132,6 +132,7 @@ static struct resource simpad_flash_resources [] = {
132static struct mcp_plat_data simpad_mcp_data = { 132static struct mcp_plat_data simpad_mcp_data = {
133 .mccr0 = MCCR0_ADM, 133 .mccr0 = MCCR0_ADM,
134 .sclk_rate = 11981000, 134 .sclk_rate = 11981000,
135 .gpio_base = SIMPAD_UCB1X00_GPIO_BASE,
135}; 136};
136 137
137 138