[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240829124118.3256437-1-yujiaoliang@vivo.com>
Date: Thu, 29 Aug 2024 20:41:18 +0800
From: Yu Jiaoliang <yujiaoliang@...o.com>
To: Bjorn Andersson <andersson@...nel.org>,
Konrad Dybcio <konradybcio@...nel.org>,
linux-arm-msm@...r.kernel.org,
linux-kernel@...r.kernel.org
Cc: opensource.kernel@...o.com
Subject: [PATCH v1] bus: qcom: Simplify with dev_err_probe()
Error handling in probe() can be a bit simpler with dev_err_probe().
Signed-off-by: Yu Jiaoliang <yujiaoliang@...o.com>
---
drivers/bus/qcom-ebi2.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/bus/qcom-ebi2.c b/drivers/bus/qcom-ebi2.c
index c1fef1b4bd89..dbd6a99bcc99 100644
--- a/drivers/bus/qcom-ebi2.c
+++ b/drivers/bus/qcom-ebi2.c
@@ -308,10 +308,8 @@ static int qcom_ebi2_probe(struct platform_device *pdev)
return PTR_ERR(ebi2xclk);
ret = clk_prepare_enable(ebi2xclk);
- if (ret) {
- dev_err(dev, "could not enable EBI2X clk (%d)\n", ret);
- return ret;
- }
+ if (ret)
+ return dev_err_probe(dev, ret, "could not enable EBI2X clk\n");
ebi2clk = devm_clk_get(dev, "ebi2");
if (IS_ERR(ebi2clk)) {
--
2.34.1
Powered by blists - more mailing lists