summaryrefslogtreecommitdiff
path: root/drivers/reset
diff options
context:
space:
mode:
authorWang Ming <machel@vivo.com>2023-07-26 14:45:45 +0300
committerPhilipp Zabel <p.zabel@pengutronix.de>2023-07-28 19:07:01 +0300
commit38d09b989721ad14cbbeb82a28c1c6978438bcce (patch)
tree8a8ec45ff0c37aaa2fcda749e2a9072e80180d4e /drivers/reset
parentf7cb24e466ee939e70e986e14db8338ab44b177c (diff)
downloadlinux-38d09b989721ad14cbbeb82a28c1c6978438bcce.tar.xz
reset: hisilicon: Use dev_err_probe instead of dev_err
The probe process may generate EPROBE_DEFER. In this case, dev_err_probe can still record err information. This helps simplify code and standardize error output. Signed-off-by: Wang Ming <machel@vivo.com> Link: https://lore.kernel.org/r/20230726114555.5011-1-machel@vivo.com Signed-off-by: Philipp Zabel <p.zabel@pengutronix.de>
Diffstat (limited to 'drivers/reset')
-rw-r--r--drivers/reset/hisilicon/reset-hi3660.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/reset/hisilicon/reset-hi3660.c b/drivers/reset/hisilicon/reset-hi3660.c
index 087f28e326ee..1beb275275ad 100644
--- a/drivers/reset/hisilicon/reset-hi3660.c
+++ b/drivers/reset/hisilicon/reset-hi3660.c
@@ -90,8 +90,8 @@ static int hi3660_reset_probe(struct platform_device *pdev)
"hisi,rst-syscon");
}
if (IS_ERR(rc->map)) {
- dev_err(dev, "failed to get hisilicon,rst-syscon\n");
- return PTR_ERR(rc->map);
+ return dev_err_probe(dev, PTR_ERR(rc->map),
+ "failed to get hisilicon,rst-syscon\n");
}
rc->rst.ops = &hi3660_reset_ops,