diff options
author | Heikki Krogerus <heikki.krogerus@linux.intel.com> | 2013-12-03 07:49:58 -0500 |
---|---|---|
committer | Linus Walleij <linus.walleij@linaro.org> | 2013-12-11 06:49:29 -0500 |
commit | 7bb3ed21f9506126bd590b8bf0676bad5bfa6336 (patch) | |
tree | 2a25237a6930f854965c13ec24fb297b76dc72a8 /arch/arm/mach-tegra/board-paz00.c | |
parent | fdd6a5fe89880f1d97bbf62fea27fd7ca76f2d21 (diff) |
ARM: tegra: add gpiod_lookup table for paz00
This makes it possible to request the gpio descriptors in
rfkill_gpio driver regardless of the platform.
Signed-off-by: Heikki Krogerus <heikki.krogerus@linux.intel.com>
Acked-by: Stephen Warren <swarren@nvidia.com>
Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'arch/arm/mach-tegra/board-paz00.c')
-rw-r--r-- | arch/arm/mach-tegra/board-paz00.c | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/arch/arm/mach-tegra/board-paz00.c b/arch/arm/mach-tegra/board-paz00.c index 06f024070dab..e4dec9fcb084 100644 --- a/arch/arm/mach-tegra/board-paz00.c +++ b/arch/arm/mach-tegra/board-paz00.c | |||
@@ -18,6 +18,7 @@ | |||
18 | */ | 18 | */ |
19 | 19 | ||
20 | #include <linux/platform_device.h> | 20 | #include <linux/platform_device.h> |
21 | #include <linux/gpio/driver.h> | ||
21 | #include <linux/rfkill-gpio.h> | 22 | #include <linux/rfkill-gpio.h> |
22 | #include "board.h" | 23 | #include "board.h" |
23 | 24 | ||
@@ -36,7 +37,17 @@ static struct platform_device wifi_rfkill_device = { | |||
36 | }, | 37 | }, |
37 | }; | 38 | }; |
38 | 39 | ||
40 | static struct gpiod_lookup_table wifi_gpio_lookup = { | ||
41 | .dev_id = "rfkill_gpio", | ||
42 | .table = { | ||
43 | GPIO_LOOKUP_IDX("tegra-gpio", 25, NULL, 0, 0), | ||
44 | GPIO_LOOKUP_IDX("tegra-gpio", 85, NULL, 1, 0), | ||
45 | { }, | ||
46 | }, | ||
47 | }; | ||
48 | |||
39 | void __init tegra_paz00_wifikill_init(void) | 49 | void __init tegra_paz00_wifikill_init(void) |
40 | { | 50 | { |
51 | gpiod_add_lookup_table(&wifi_gpio_lookup); | ||
41 | platform_device_register(&wifi_rfkill_device); | 52 | platform_device_register(&wifi_rfkill_device); |
42 | } | 53 | } |