From 93a22f8b95756c53e80308820892119c910d2739 Mon Sep 17 00:00:00 2001 From: David Brownell Date: Wed, 15 Oct 2008 22:03:15 -0700 Subject: omap drivers: switch to standard GPIO calls This updates most of the OMAP drivers which are in mainline to switch to using the cross-platform GPIO calls instead of the older OMAP-specific ones. This is all fairly brainless/obvious stuff. Probably the most interesting bit is to observe that the omap-keypad code seems to now have a portable core that could work with non-OMAP matrix keypads. (That would improve with hardware IRQ debouncing enabled, of course...) Signed-off-by: David Brownell Signed-off-by: Tony Lindgren Cc: Dmitry Torokhov Cc: Antonino Daplas Cc: David Woodhouse Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- drivers/video/omap/lcd_inn1610.c | 22 +++++++++++----------- 1 file changed, 11 insertions(+), 11 deletions(-) (limited to 'drivers/video/omap/lcd_inn1610.c') diff --git a/drivers/video/omap/lcd_inn1610.c b/drivers/video/omap/lcd_inn1610.c index 6a42c6a0cd99..4c4f7ee6d733 100644 --- a/drivers/video/omap/lcd_inn1610.c +++ b/drivers/video/omap/lcd_inn1610.c @@ -32,43 +32,43 @@ static int innovator1610_panel_init(struct lcd_panel *panel, { int r = 0; - if (omap_request_gpio(14)) { + if (gpio_request(14, "lcd_en0")) { pr_err(MODULE_NAME ": can't request GPIO 14\n"); r = -1; goto exit; } - if (omap_request_gpio(15)) { + if (gpio_request(15, "lcd_en1")) { pr_err(MODULE_NAME ": can't request GPIO 15\n"); - omap_free_gpio(14); + gpio_free(14); r = -1; goto exit; } /* configure GPIO(14, 15) as outputs */ - omap_set_gpio_direction(14, 0); - omap_set_gpio_direction(15, 0); + gpio_direction_output(14, 0); + gpio_direction_output(15, 0); exit: return r; } static void innovator1610_panel_cleanup(struct lcd_panel *panel) { - omap_free_gpio(15); - omap_free_gpio(14); + gpio_free(15); + gpio_free(14); } static int innovator1610_panel_enable(struct lcd_panel *panel) { /* set GPIO14 and GPIO15 high */ - omap_set_gpio_dataout(14, 1); - omap_set_gpio_dataout(15, 1); + gpio_set_value(14, 1); + gpio_set_value(15, 1); return 0; } static void innovator1610_panel_disable(struct lcd_panel *panel) { /* set GPIO13, GPIO14 and GPIO15 low */ - omap_set_gpio_dataout(14, 0); - omap_set_gpio_dataout(15, 0); + gpio_set_value(14, 0); + gpio_set_value(15, 0); } static unsigned long innovator1610_panel_get_caps(struct lcd_panel *panel) -- cgit v1.2.3-59-g8ed1b