Skip to content

Commit da3d242

Browse files
passgatUlf Hansson
authored andcommitted
pmdomain: imx: gpcv2: replace dev_err() with dev_err_probe()
The patch standardizes the probe() code by replacing the two occurrences of dev_err() with dev_err_probe(). Indeed, dev_err_probe() was used in all other error paths of the probe() function. Note that dev_err_probe() has advantages even if the error code is not EPROBE_DEFER, such as the symbolic output of the error code. Therefore, it should generally be preferred over dev_err(). Co-developed-by: Michael Trimarchi <michael@amarulasolutions.com> Signed-off-by: Michael Trimarchi <michael@amarulasolutions.com> Signed-off-by: Dario Binacchi <dario.binacchi@amarulasolutions.com> Reviewed-by: Marco Felsch <m.felsch@pengutronix.de> Message-ID: <20241025160430.4113467-1-dario.binacchi@amarulasolutions.com> Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
1 parent 88e98cd commit da3d242

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

drivers/pmdomain/imx/gpcv2.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1356,7 +1356,7 @@ static int imx_pgc_domain_probe(struct platform_device *pdev)
13561356

13571357
ret = pm_genpd_init(&domain->genpd, NULL, true);
13581358
if (ret) {
1359-
dev_err(domain->dev, "Failed to init power domain\n");
1359+
dev_err_probe(domain->dev, ret, "Failed to init power domain\n");
13601360
goto out_domain_unmap;
13611361
}
13621362

@@ -1367,7 +1367,7 @@ static int imx_pgc_domain_probe(struct platform_device *pdev)
13671367
ret = of_genpd_add_provider_simple(domain->dev->of_node,
13681368
&domain->genpd);
13691369
if (ret) {
1370-
dev_err(domain->dev, "Failed to add genpd provider\n");
1370+
dev_err_probe(domain->dev, ret, "Failed to add genpd provider\n");
13711371
goto out_genpd_remove;
13721372
}
13731373

0 commit comments

Comments
 (0)