diff options
author | Bartosz Golaszewski <bgolaszewski@baylibre.com> | 2019-02-11 13:36:57 +0300 |
---|---|---|
committer | Sekhar Nori <nsekhar@ti.com> | 2019-02-12 10:58:41 +0300 |
commit | c08df69149db9bbd0b21802f93b65e8d32d44069 (patch) | |
tree | 4f4644563d8625944770583d591155315908712e /arch/arm/mach-davinci | |
parent | 3d2ab9f35ebda97de7392716022a4ed8ab646861 (diff) | |
download | linux-c08df69149db9bbd0b21802f93b65e8d32d44069.tar.xz |
ARM: davinci: omapl138-hawk: use gpio lookup entries for usb gpios
Add lookup entries for the vbus and overcurrent gpios for omapl138-hawk.
Signed-off-by: Bartosz Golaszewski <bgolaszewski@baylibre.com>
Reviewed-by: Linus Walleij <linus.walleij@linaro.org>
Signed-off-by: Sekhar Nori <nsekhar@ti.com>
Diffstat (limited to 'arch/arm/mach-davinci')
-rw-r--r-- | arch/arm/mach-davinci/board-omapl138-hawk.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/arch/arm/mach-davinci/board-omapl138-hawk.c b/arch/arm/mach-davinci/board-omapl138-hawk.c index 8e8d51f4a276..dc7e363d3fa2 100644 --- a/arch/arm/mach-davinci/board-omapl138-hawk.c +++ b/arch/arm/mach-davinci/board-omapl138-hawk.c @@ -302,6 +302,14 @@ static const short da850_hawk_usb11_pins[] = { -1 }; +static struct gpiod_lookup_table hawk_usb_gpio_lookup = { + .dev_id = "ohci-da8xx", + .table = { + GPIO_LOOKUP("davinci_gpio", DA850_USB1_VBUS_PIN, "vbus", 0), + GPIO_LOOKUP("davinci_gpio", DA850_USB1_OC_PIN, "oc", 0), + }, +}; + static int hawk_usb_set_power(unsigned port, int on) { gpio_set_value(DA850_USB1_VBUS_PIN, on); @@ -390,6 +398,8 @@ static __init void omapl138_hawk_usb_init(void) goto usb11_setup_oc_fail; } + gpiod_add_lookup_table(&hawk_usb_gpio_lookup); + ret = da8xx_register_usb11(&omapl138_hawk_usb11_pdata); if (ret) { pr_warn("%s: USB 1.1 registration failed: %d\n", __func__, ret); |