diff options
author | Arnd Bergmann <arnd@arndb.de> | 2019-09-12 00:37:28 +0300 |
---|---|---|
committer | Arnd Bergmann <arnd@arndb.de> | 2022-05-07 23:55:48 +0300 |
commit | 0ca7231fe3a98c61f3a87c4cb99082cbfa5210f0 (patch) | |
tree | df14c135f5090e0a7728ce6c713ef2a96c9fc771 /arch/arm/mach-pxa/palmld.c | |
parent | f1131a46f37ea249e7190a1bc0845ee6a4c3f92e (diff) | |
download | linux-0ca7231fe3a98c61f3a87c4cb99082cbfa5210f0.tar.xz |
ARM: pxa: mainstone-wm97xx: use gpio lookup table
This driver hardcodes gpio numbers without a header file.
Use lookup tables instead.
Cc: Marek Vasut <marek.vasut@gmail.com>
Acked-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Acked-by: Robert Jarzmik <robert.jarzmik@free.fr>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Cc: linux-input@vger.kernel.org
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Diffstat (limited to 'arch/arm/mach-pxa/palmld.c')
-rw-r--r-- | arch/arm/mach-pxa/palmld.c | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/arch/arm/mach-pxa/palmld.c b/arch/arm/mach-pxa/palmld.c index d821606ce0b5..32308c63884e 100644 --- a/arch/arm/mach-pxa/palmld.c +++ b/arch/arm/mach-pxa/palmld.c @@ -347,6 +347,14 @@ static struct gpiod_lookup_table palmld_mci_gpio_table = { }, }; +static struct gpiod_lookup_table palmld_wm97xx_touch_gpio_table = { + .dev_id = "wm97xx-touch", + .table = { + GPIO_LOOKUP("gpio-pxa", 27, "touch", GPIO_ACTIVE_HIGH), + { }, + }, +}; + static void __init palmld_init(void) { pxa2xx_mfp_config(ARRAY_AND_SIZE(palmld_pin_config)); @@ -355,6 +363,7 @@ static void __init palmld_init(void) pxa_set_stuart_info(NULL); palm27x_mmc_init(&palmld_mci_gpio_table); + gpiod_add_lookup_table(&palmld_wm97xx_touch_gpio_table); palm27x_pm_init(PALMLD_STR_BASE); palm27x_lcd_init(-1, &palm_320x480_lcd_mode); palm27x_irda_init(GPIO_NR_PALMLD_IR_DISABLE); |