From 46580c03062da8c047238a6b3d2b2b13af1700b5 Mon Sep 17 00:00:00 2001 From: Mike Rapoport Date: Tue, 14 Apr 2009 08:33:49 +0300 Subject: [ARM] pxa: update pxa2xx_spi_chip initialization to use .gpio_cs field Signed-off-by: Mike Rapoport Signed-off-by: Eric Miao --- arch/arm/mach-pxa/poodle.c | 15 +-------------- 1 file changed, 1 insertion(+), 14 deletions(-) (limited to 'arch/arm/mach-pxa/poodle.c') diff --git a/arch/arm/mach-pxa/poodle.c b/arch/arm/mach-pxa/poodle.c index 74f4ce600ca4..ac431ed10399 100644 --- a/arch/arm/mach-pxa/poodle.c +++ b/arch/arm/mach-pxa/poodle.c @@ -214,13 +214,8 @@ static struct ads7846_platform_data poodle_ads7846_info = { .gpio_pendown = POODLE_GPIO_TP_INT, }; -static void ads7846_cs(u32 command) -{ - gpio_set_value(POODLE_GPIO_TP_CS, !(command == PXA2XX_CS_ASSERT)); -} - static struct pxa2xx_spi_chip poodle_ads7846_chip = { - .cs_control = ads7846_cs, + .gpio_cs = POODLE_GPIO_TP_CS, }; static struct spi_board_info poodle_spi_devices[] = { @@ -236,14 +231,6 @@ static struct spi_board_info poodle_spi_devices[] = { static void __init poodle_init_spi(void) { - int err; - - err = gpio_request(POODLE_GPIO_TP_CS, "ADS7846_CS"); - if (err) - return; - - gpio_direction_output(POODLE_GPIO_TP_CS, 1); - pxa2xx_set_spi_info(1, &poodle_spi_info); spi_register_board_info(ARRAY_AND_SIZE(poodle_spi_devices)); } -- cgit v1.2.3