aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm/mach-ux500/board-mop500-stuib.c
diff options
context:
space:
mode:
authorLinus Walleij <linus.walleij@linaro.org>2011-02-15 09:01:35 -0500
committerLinus Walleij <linus.walleij@linaro.org>2011-03-14 09:05:16 -0400
commit4b4f757c807375564ce3d4ff1d088d3847c52f6d (patch)
treeeac756e13f38cb9fd899df6225665a0d8caaff62 /arch/arm/mach-ux500/board-mop500-stuib.c
parent4bc3a698c3db6592490cd685e395e27216ed2454 (diff)
mach-ux500: basic HREFv60 support v2
The HREFv60 variant of the MOP500 family of boards remove the external GPIO expander and route these pins back to some of the readily available internal GPIO pins instead. Based on a patch by Bibek Basu <bibek.basu@stericsson.com> for an internal kernel version. Cc: Bibek Basu <bibek.basu@stericsson.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'arch/arm/mach-ux500/board-mop500-stuib.c')
-rw-r--r--arch/arm/mach-ux500/board-mop500-stuib.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/arch/arm/mach-ux500/board-mop500-stuib.c b/arch/arm/mach-ux500/board-mop500-stuib.c
index 8b6323e229ff..8c979770d872 100644
--- a/arch/arm/mach-ux500/board-mop500-stuib.c
+++ b/arch/arm/mach-ux500/board-mop500-stuib.c
@@ -12,6 +12,7 @@
12#include <linux/interrupt.h> 12#include <linux/interrupt.h>
13#include <linux/i2c.h> 13#include <linux/i2c.h>
14#include <linux/input/matrix_keypad.h> 14#include <linux/input/matrix_keypad.h>
15#include <asm/mach-types.h>
15 16
16#include "board-mop500.h" 17#include "board-mop500.h"
17 18
@@ -154,7 +155,6 @@ static struct bu21013_platform_device tsc_plat_device = {
154 .cs_dis = bu21013_gpio_board_exit, 155 .cs_dis = bu21013_gpio_board_exit,
155 .irq_read_val = bu21013_read_pin_val, 156 .irq_read_val = bu21013_read_pin_val,
156 .irq = NOMADIK_GPIO_TO_IRQ(TOUCH_GPIO_PIN), 157 .irq = NOMADIK_GPIO_TO_IRQ(TOUCH_GPIO_PIN),
157 .cs_pin = GPIO_BU21013_CS,
158 .touch_x_max = TOUCH_XMAX, 158 .touch_x_max = TOUCH_XMAX,
159 .touch_y_max = TOUCH_YMAX, 159 .touch_y_max = TOUCH_YMAX,
160 .ext_clk = false, 160 .ext_clk = false,
@@ -167,7 +167,6 @@ static struct bu21013_platform_device tsc_plat2_device = {
167 .cs_dis = bu21013_gpio_board_exit, 167 .cs_dis = bu21013_gpio_board_exit,
168 .irq_read_val = bu21013_read_pin_val, 168 .irq_read_val = bu21013_read_pin_val,
169 .irq = NOMADIK_GPIO_TO_IRQ(TOUCH_GPIO_PIN), 169 .irq = NOMADIK_GPIO_TO_IRQ(TOUCH_GPIO_PIN),
170 .cs_pin = GPIO_BU21013_CS,
171 .touch_x_max = TOUCH_XMAX, 170 .touch_x_max = TOUCH_XMAX,
172 .touch_y_max = TOUCH_YMAX, 171 .touch_y_max = TOUCH_YMAX,
173 .ext_clk = false, 172 .ext_clk = false,
@@ -189,6 +188,15 @@ static struct i2c_board_info __initdata u8500_i2c3_devices_stuib[] = {
189 188
190void __init mop500_stuib_init(void) 189void __init mop500_stuib_init(void)
191{ 190{
191 if (machine_is_hrefv60()) {
192 tsc_plat_device.cs_pin = HREFV60_TOUCH_RST_GPIO;
193 tsc_plat2_device.cs_pin = HREFV60_TOUCH_RST_GPIO;
194 } else {
195 tsc_plat_device.cs_pin = GPIO_BU21013_CS;
196 tsc_plat2_device.cs_pin = GPIO_BU21013_CS;
197
198 }
199
192 mop500_uib_i2c_add(0, mop500_i2c0_devices_stuib, 200 mop500_uib_i2c_add(0, mop500_i2c0_devices_stuib,
193 ARRAY_SIZE(mop500_i2c0_devices_stuib)); 201 ARRAY_SIZE(mop500_i2c0_devices_stuib));
194 202