From ec98e34f10d63813b59a78d456dd5e089b18e43d Mon Sep 17 00:00:00 2001 From: Imre Deak Date: Fri, 10 Feb 2006 16:52:13 +0200 Subject: [PATCH] ARM: OMAP: Add ads7846 hw params in board-nokia770.c MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Imre Deak Signed-off-by: Juha Yrjölä --- arch/arm/mach-omap1/board-nokia770.c | 27 +++++++++++++++++++++++---- 1 file changed, 23 insertions(+), 4 deletions(-) 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 */ -- 2.41.1