From: Wang Ming <machel@vivo.com>
To: Philipp Zabel <p.zabel@pengutronix.de>,
Wang Ming <machel@vivo.com>,
linux-kernel@vger.kernel.org
Cc: opensource.kernel@vivo.com
Subject: [PATCH v1] reset: hisilicon: Use dev_err_probe instead of dev_err
Date: Tue, 18 Jul 2023 11:04:56 +0800 [thread overview]
Message-ID: <20230718030511.16065-1-machel@vivo.com> (raw)
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>
---
drivers/reset/hisilicon/reset-hi3660.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/reset/hisilicon/reset-hi3660.c b/drivers/reset/hisilicon/reset-hi3660.c
index 965f5ceba7d8..bc8fee6dc14e 100644
--- a/drivers/reset/hisilicon/reset-hi3660.c
+++ b/drivers/reset/hisilicon/reset-hi3660.c
@@ -90,7 +90,7 @@ 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");
+ dev_err_probe(dev, "failed to get hisilicon,rst-syscon\n");
return PTR_ERR(rc->map);
}
--
2.25.1
next reply other threads:[~2023-07-18 3:05 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2023-07-18 3:04 Wang Ming [this message]
2023-07-19 0:48 ` kernel test robot
2023-07-19 2:57 ` kernel test robot
2023-07-19 3:02 ` 回复: " 王明-软件底层技术部
2023-07-19 5:04 ` kernel test robot
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20230718030511.16065-1-machel@vivo.com \
--to=machel@vivo.com \
--cc=linux-kernel@vger.kernel.org \
--cc=opensource.kernel@vivo.com \
--cc=p.zabel@pengutronix.de \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®