summaryrefslogtreecommitdiff
path: root/drivers/gpio
diff options
context:
space:
mode:
authorSimon Glass <sjg@chromium.org>2018-02-03 10:36:59 -0700
committerSimon Glass <sjg@chromium.org>2018-02-18 15:53:32 -0700
commit995b60b5937133639500d89a01da0d88af3cff15 (patch)
tree9f64725d6b96f2d194435c55bf3cb963371ea54b /drivers/gpio
parent7e87816caa2b54e7cca9aca9b29981e54fcd0496 (diff)
downloadu-boot-995b60b5937133639500d89a01da0d88af3cff15.tar.gz
u-boot-995b60b5937133639500d89a01da0d88af3cff15.tar.bz2
u-boot-995b60b5937133639500d89a01da0d88af3cff15.zip
sandbox: Rename 'num-gpios' property to avoid dtc warning
At present dtc produces these warnings when compiling sandbox: arch/sandbox/dts/test.dtb: Warning (gpios_property): Could not get phandle node for /base-gpios:num-gpios(cell 0) arch/sandbox/dts/test.dtb: Warning (gpios_property): Missing property '#gpio-cells' in node /reset-ctl or bad phandle (referred from /extra-gpios:num-gpios[0]) Both are due to it assuming that the 'num-gpios' property holds a phandle pointing to a GPIO node. To avoid these warnings, rename the sandbox property so that it does not include the string 'gpios'. Signed-off-by: Simon Glass <sjg@chromium.org>
Diffstat (limited to 'drivers/gpio')
-rw-r--r--drivers/gpio/sandbox.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/gpio/sandbox.c b/drivers/gpio/sandbox.c
index 4f7b62eba0..2a18f32857 100644
--- a/drivers/gpio/sandbox.c
+++ b/drivers/gpio/sandbox.c
@@ -198,7 +198,8 @@ static int sandbox_gpio_ofdata_to_platdata(struct udevice *dev)
{
struct gpio_dev_priv *uc_priv = dev_get_uclass_priv(dev);
- uc_priv->gpio_count = dev_read_u32_default(dev, "num-gpios", 0);
+ uc_priv->gpio_count = dev_read_u32_default(dev, "sandbox,gpio-count",
+ 0);
uc_priv->bank_name = dev_read_string(dev, "gpio-bank-name");
return 0;