summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorramesh.chandrasekaran <ramesh.chandrasekaran@stericsson.com>2012-11-09 12:11:40 +0530
committerRajanikanth H.V <rajanikanth.hv@stericsson.com>2012-12-14 17:07:16 +0530
commit8e4248c289acb96696c25fe409a203ea24715691 (patch)
tree920c0509272ab87fd2ce571be68f4f8bd855cb0a
parent27d24abd7a8d59f6f72d583c6cb13c359d32f6cd (diff)
mach-ux500: touchscreen: Add platform data and gpio setting
Signed-off-by: ramesh.chandrasekaran <ramesh.chandrasekaran@stericsson.com>
-rw-r--r--arch/arm/mach-ux500/board-mop500.c25
-rw-r--r--arch/arm/mach-ux500/devices-db8500.c10
2 files changed, 25 insertions, 10 deletions
diff --git a/arch/arm/mach-ux500/board-mop500.c b/arch/arm/mach-ux500/board-mop500.c
index ea703097be6..ec62f4fb2d5 100644
--- a/arch/arm/mach-ux500/board-mop500.c
+++ b/arch/arm/mach-ux500/board-mop500.c
@@ -140,17 +140,18 @@ static struct ab8500_gpio_platform_data ab8500_gpio_pdata = {
* Pin GPIO37 (ApeSpiCSn)
* Pin GPIO38 (ApeSpiDout)
* Pin GPIO39 (ApeSpiDin) are configured as GPIO
- * GpioSel6 = 0x02 => Pin GPIO42 (SysClkReq5) is configured as GPIO
+ * GpioSel6 = 0x03 => Pin GPIO41 (ModSDA) is configured as GPIO
+ Pin GPIO42 (SysClkReq5) is configured as GPIO
* AlternaFunction = 0x00 => If Pins GPIO10 to 13 are not configured
* as GPIO then this register selectes the alternate fucntions
*/
- .config_reg = {0x0F, 0x9E, 0x80, 0x01, 0x78, 0x02, 0x00},
+ .config_reg = {0x0F, 0x9E, 0x80, 0x01, 0x78, 0x03},
/*
* config_direction allows for the initial GPIO direction to
* be set. For Snowball we set GPIO26 to output.
*/
- .config_direction = {0x00, 0x00, 0x00, 0x02, 0x00, 0x00},
+ .config_direction = {0xA, 0x00, 0x00, 0x02, 0x00, 0x03},
/*
* config_pullups allows for the intial configuration of the
@@ -230,7 +231,7 @@ static struct gpio_keys_button snowball_key_array[] = {
.debounce_interval = 50,
.wakeup = 1,
},
- {
+/* {
.gpio = 151,
.type = EV_KEY,
.code = KEY_2,
@@ -239,6 +240,7 @@ static struct gpio_keys_button snowball_key_array[] = {
.debounce_interval = 50,
.wakeup = 1,
},
+*/
{
.gpio = 152,
.type = EV_KEY,
@@ -664,6 +666,16 @@ static struct i2c_board_info __initdata snowball_i2c0_devices[] = {
#endif
};
+#ifdef CONFIG_TOUCHSCREEN_STMT07
+static struct i2c_board_info __initdata snowball_i2c1_devices[] = {
+ {
+ /* STM TS controller */
+ I2C_BOARD_INFO("ftk", 0x4B),
+ .irq = NOMADIK_GPIO_TO_IRQ(152),
+ },
+};
+#endif
+
static struct i2c_board_info __initdata mop500_i2c2_devices[] = {
{
/* lp5521 LED driver, 1st device */
@@ -1297,7 +1309,10 @@ static void __init snowball_init_machine(void)
i2c_register_board_info(0, snowball_i2c0_devices,
ARRAY_SIZE(snowball_i2c0_devices));
-
+#ifdef CONFIG_TOUCHSCREEN_STMT07
+ i2c_register_board_info(1, snowball_i2c1_devices,
+ ARRAY_SIZE(snowball_i2c1_devices));
+#endif
/* This board has full regulator constraints */
regulator_has_full_constraints();
}
diff --git a/arch/arm/mach-ux500/devices-db8500.c b/arch/arm/mach-ux500/devices-db8500.c
index 28f6da58e1e..68e8b33418c 100644
--- a/arch/arm/mach-ux500/devices-db8500.c
+++ b/arch/arm/mach-ux500/devices-db8500.c
@@ -212,16 +212,16 @@ static int mcde_platform_set_display_clocks(void)
static struct mcde_platform_data mcde_u8500_pdata = {
/*
- * [0] = 3: 24 bits DPI: connect LSB Ch B to D[0:7]
- * [3] = 4: 24 bits DPI: connect MID Ch B to D[24:31]
- * [4] = 5: 24 bits DPI: connect MSB Ch B to D[32:39]
+ * [0] = 5: 24 bits DPI: connect MSB Ch B to D[0:7]
+ * [3] = 4: 24 bits DPI: connect MID Ch B to D[15:8]
+ * [4] = 3: 24 bits DPI: connect LSB Ch B to D[31:24]
*
* [1] = 3: TV out : connect LSB Ch B to D[8:15]
*/
#define DONT_CARE 0
- .outmux = { 3, 3, DONT_CARE, 4, 5 },
+ .outmux = { 5, 4, DONT_CARE, 3, DONT_CARE },
#undef DONT_CARE
- .syncmux = 0x00, /* DPI channel A and B on output pins A and B resp */
+ .syncmux = 0x40,
#ifdef CONFIG_MCDE_DISPLAY_DSI
.regulator_vana_id = "vdddsi1v2",
#endif