linux-gpio.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] pinctrl: qcom-pmic-gpio: silence -EPROBE_DEFER message on probe
@ 2023-08-17 14:59 Brian Masney
  2023-08-17 15:01 ` Konrad Dybcio
  0 siblings, 1 reply; 6+ messages in thread
From: Brian Masney @ 2023-08-17 14:59 UTC (permalink / raw)
  To: andersson, linus.walleij
  Cc: agross, konrad.dybcio, linux-arm-msm, linux-gpio, linux-kernel

The following message shows up one or more times when booting a Qualcomm
SA8775 Development board:

    qcom-spmi-gpio c440000.spmi:pmic@2:gpio@8800: can't add gpio chip

Convert this over to use dev_err_probe() to silence this message.

Signed-off-by: Brian Masney <bmasney@redhat.com>
---
 drivers/pinctrl/qcom/pinctrl-spmi-gpio.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)

diff --git a/drivers/pinctrl/qcom/pinctrl-spmi-gpio.c b/drivers/pinctrl/qcom/pinctrl-spmi-gpio.c
index deded9c6fd7d..d7576fa14935 100644
--- a/drivers/pinctrl/qcom/pinctrl-spmi-gpio.c
+++ b/drivers/pinctrl/qcom/pinctrl-spmi-gpio.c
@@ -1154,10 +1154,8 @@ static int pmic_gpio_probe(struct platform_device *pdev)
 	girq->child_irq_domain_ops.translate = pmic_gpio_domain_translate;
 
 	ret = gpiochip_add_data(&state->chip, state);
-	if (ret) {
-		dev_err(state->dev, "can't add gpio chip\n");
-		return ret;
-	}
+	if (ret)
+		return dev_err_probe(state->dev, ret, "can't add gpio chip\n");
 
 	/*
 	 * For DeviceTree-supported systems, the gpio core checks the
-- 
2.41.0


^ permalink raw reply related	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2023-08-21 13:12 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2023-08-17 14:59 [PATCH] pinctrl: qcom-pmic-gpio: silence -EPROBE_DEFER message on probe Brian Masney
2023-08-17 15:01 ` Konrad Dybcio
2023-08-17 16:26   ` Brian Masney
2023-08-18 13:51     ` Krzysztof Kozlowski
2023-08-18 13:59       ` Krzysztof Kozlowski
2023-08-21 13:11         ` Brian Masney

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).