summaryrefslogtreecommitdiff
path: root/drivers/pinctrl
diff options
context:
space:
mode:
authorFlorian Fainelli <florian.fainelli@broadcom.com>2023-08-08 21:07:32 +0300
committerLinus Walleij <linus.walleij@linaro.org>2023-08-10 11:41:20 +0300
commitd2606a6365bde17ee7b1efda9443d6b2e15f6d5a (patch)
tree20bb8ac05717250a20416a81bc113fba9048bf00 /drivers/pinctrl
parent0cec950d3f3435ae39c8a1a4b1423f4ffbf9ec7a (diff)
downloadlinux-d2606a6365bde17ee7b1efda9443d6b2e15f6d5a.tar.xz
pinctrl: iproc-gpio: Silence probe deferral messages
We can have gpiochip_add_data() return -EPROBE_DEFER which will make us produce the "unable to add GPIO chip" message which is confusing. Use dev_err_probe() to silence probe deferral messages. Signed-off-by: Florian Fainelli <florian.fainelli@broadcom.com> Reviewed-by: Dhruva Gole <d-gole@ti.com> Link: https://lore.kernel.org/r/20230808180733.2081353-2-florian.fainelli@broadcom.com Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
Diffstat (limited to 'drivers/pinctrl')
-rw-r--r--drivers/pinctrl/bcm/pinctrl-iproc-gpio.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c
index dcec671661e2..bc7bb9876e57 100644
--- a/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c
+++ b/drivers/pinctrl/bcm/pinctrl-iproc-gpio.c
@@ -891,10 +891,8 @@ static int iproc_gpio_probe(struct platform_device *pdev)
}
ret = gpiochip_add_data(gc, chip);
- if (ret < 0) {
- dev_err(dev, "unable to add GPIO chip\n");
- return ret;
- }
+ if (ret < 0)
+ return dev_err_probe(dev, ret, "unable to add GPIO chip\n");
if (!no_pinconf) {
ret = iproc_gpio_register_pinconf(chip);