diff options
author | Simon Glass <sjg@chromium.org> | 2020-11-29 03:50:03 +0300 |
---|---|---|
committer | Simon Glass <sjg@chromium.org> | 2020-12-13 17:58:18 +0300 |
commit | a2703ce10cfcbe6a82ec8ed9ec10df2aeea08e64 (patch) | |
tree | 3b1e2e1d33b9e0bc9120be2cee4c6ca966876857 /drivers/pinctrl/mvebu | |
parent | 0de1b07406d709c3951dbb1a69ca196d80bd516d (diff) | |
download | u-boot-a2703ce10cfcbe6a82ec8ed9ec10df2aeea08e64.tar.xz |
dm: Remove uses of device_bind_offset()
This function is not needed since the standard device_bind() can be used
instead.
Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/pinctrl/mvebu')
-rw-r--r-- | drivers/pinctrl/mvebu/pinctrl-armada-37xx.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c b/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c index 7bbeb413ba..17d7603ebd 100644 --- a/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c +++ b/drivers/pinctrl/mvebu/pinctrl-armada-37xx.c @@ -547,13 +547,14 @@ static int armada_37xx_gpiochip_register(struct udevice *parent, int subnode; char *name; - /* Lookup GPIO driver */ + /* FIXME: Should not need to lookup GPIO uclass */ drv = lists_uclass_lookup(UCLASS_GPIO); if (!drv) { puts("Cannot find GPIO driver\n"); return -ENOENT; } + /* FIXME: Use livtree and check the result of device_bind() below */ fdt_for_each_subnode(subnode, blob, node) { if (fdtdec_get_bool(blob, subnode, "gpio-controller")) { ret = 0; @@ -567,9 +568,8 @@ static int armada_37xx_gpiochip_register(struct udevice *parent, sprintf(name, "armada-37xx-gpio"); /* Create child device UCLASS_GPIO and bind it */ - device_bind_offset(parent, &armada_37xx_gpio_driver, name, NULL, - subnode, &dev); - dev_set_of_offset(dev, subnode); + device_bind(parent, &armada_37xx_gpio_driver, name, NULL, + offset_to_ofnode(subnode), &dev); return 0; } |