summaryrefslogtreecommitdiff
path: root/drivers/gpio/pm8916_gpio.c
diff options
context:
space:
mode:
authorTom Rini <trini@konsulko.com>2019-10-08 18:45:26 -0400
committerTom Rini <trini@konsulko.com>2019-10-08 18:45:26 -0400
commitefea5a34bb5be542630ce7161bd3b9cc26a0bcf3 (patch)
treefb747d83d81f9c3400a561782114e4c6ecd61a07 /drivers/gpio/pm8916_gpio.c
parent9d536fe8ae7672bdee091f9100389b6f3e53cfc6 (diff)
parentcc2d27dcdc3e1c76d09d54015e3992380bd7e0fa (diff)
Merge https://gitlab.denx.de/u-boot/custodians/u-boot-x86
- Rename existing FSP code to fsp1 - Add fsp2 directory in preparation to support FSP 2.0 - Various x86 platform codes update - Various bug fixes and updates in dm core, sandbox and spl
Diffstat (limited to 'drivers/gpio/pm8916_gpio.c')
-rw-r--r--drivers/gpio/pm8916_gpio.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/drivers/gpio/pm8916_gpio.c b/drivers/gpio/pm8916_gpio.c
index bbe214d5ee..74a773c099 100644
--- a/drivers/gpio/pm8916_gpio.c
+++ b/drivers/gpio/pm8916_gpio.c
@@ -172,16 +172,16 @@ static int pm8916_gpio_probe(struct udevice *dev)
priv->pid = dev_read_addr(dev);
if (priv->pid == FDT_ADDR_T_NONE)
- return -EINVAL;
+ return log_msg_ret("bad address", -EINVAL);
/* Do a sanity check */
reg = pmic_reg_read(dev->parent, priv->pid + REG_TYPE);
if (reg != 0x10)
- return -ENODEV;
+ return log_msg_ret("bad type", -ENXIO);
reg = pmic_reg_read(dev->parent, priv->pid + REG_SUBTYPE);
if (reg != 0x5 && reg != 0x1)
- return -ENODEV;
+ return log_msg_ret("bad subtype", -ENXIO);
return 0;
}
@@ -257,16 +257,16 @@ static int pm8941_pwrkey_probe(struct udevice *dev)
priv->pid = devfdt_get_addr(dev);
if (priv->pid == FDT_ADDR_T_NONE)
- return -EINVAL;
+ return log_msg_ret("bad address", -EINVAL);
/* Do a sanity check */
reg = pmic_reg_read(dev->parent, priv->pid + REG_TYPE);
if (reg != 0x1)
- return -ENODEV;
+ return log_msg_ret("bad type", -ENXIO);
reg = pmic_reg_read(dev->parent, priv->pid + REG_SUBTYPE);
if (reg != 0x1)
- return -ENODEV;
+ return log_msg_ret("bad subtype", -ENXIO);
return 0;
}