From: Imre Deak Date: Fri, 10 Feb 2006 14:52:13 +0000 (+0200) Subject: ARM: OMAP: Add ads7846 hw params in board-nokia770.c X-Git-Tag: v2.6.16-omap1~73 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=ec98e34f10d63813b59a78d456dd5e089b18e43d;p=linux-2.6-omap-h63xx.git ARM: OMAP: Add ads7846 hw params in board-nokia770.c Signed-off-by: Imre Deak Signed-off-by: Juha Yrjölä --- diff --git a/arch/arm/mach-omap1/board-nokia770.c b/arch/arm/mach-omap1/board-nokia770.c index 5ad8c3fa084..90f794e7c46 100644 --- a/arch/arm/mach-omap1/board-nokia770.c +++ b/arch/arm/mach-omap1/board-nokia770.c @@ -11,9 +11,11 @@ #include #include #include -#include #include +#include +#include + #include #include #include @@ -71,6 +73,18 @@ static struct platform_device nokia770_kp_device = { .resource = nokia770_kp_resources, }; +static struct platform_device *nokia770_devices[] __initdata = { + &nokia770_kp_device, +}; + +static struct ads7846_platform_data nokia770_ads7846_platform_data __initdata = { + .x_max = 0x0fff, + .y_max = 0x0fff, + .x_plate_ohms = 120, + .pressure_max = 200, + +}; + static struct spi_board_info nokia770_spi_board_info[] __initdata = { [0] = { .modalias = "lcd_lph8923", @@ -78,11 +92,16 @@ static struct spi_board_info nokia770_spi_board_info[] __initdata = { .chip_select = 3, .max_speed_hz = 12000000, }, + [1] = { + .modalias = "ads7846", + .bus_num = 2, + .chip_select = 0, + .max_speed_hz = 2500000, + .irq = OMAP_GPIO_IRQ(15), + .platform_data = &nokia770_ads7846_platform_data, + }, }; -static struct platform_device *nokia770_devices[] __initdata = { - &nokia770_kp_device, -}; /* assume no Mini-AB port */