aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDan Carpenter <[email protected]>2021-08-08 01:00:16 +0200
committerArnd Bergmann <[email protected]>2021-08-12 22:34:13 +0200
commitd2c334f49c8305ff8ce31ea33183977a2935ba55 (patch)
tree9d9fd8a90f586353b946eac9bd2292c8a993bed6
parent9c8300b1608748669b4b5b67e3fea71d07ca35af (diff)
bus: ixp4xx: return on error in ixp4xx_exp_probe()
This code was intended to return an error code if regmap_read() fails but the return statement was missing. Fixes: 1c953bda90ca ("bus: ixp4xx: Add a driver for IXP4xx expansion bus") Signed-off-by: Dan Carpenter <[email protected]> Signed-off-by: Linus Walleij <[email protected]> Link: https://lore.kernel.org/r/[email protected]' Signed-off-by: Arnd Bergmann <[email protected]>
-rw-r--r--drivers/bus/intel-ixp4xx-eb.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/bus/intel-ixp4xx-eb.c b/drivers/bus/intel-ixp4xx-eb.c
index 9acd00da413c..a4388440aca7 100644
--- a/drivers/bus/intel-ixp4xx-eb.c
+++ b/drivers/bus/intel-ixp4xx-eb.c
@@ -369,7 +369,7 @@ static int ixp4xx_exp_probe(struct platform_device *pdev)
/* We check that the regmap work only on first read */
ret = regmap_read(eb->rmap, IXP4XX_EXP_CNFG0, &val);
if (ret)
- dev_err_probe(dev, ret, "cannot read regmap\n");
+ return dev_err_probe(dev, ret, "cannot read regmap\n");
if (val & IXP4XX_EXP_CNFG0_MEM_MAP)
eb->bus_base = IXP4XX_EXP_BOOT_BASE;
else