From: Hiago De Franco <hiagofranco@gmail.com>
To: linux-remoteproc@vger.kernel.org
Cc: Bjorn Andersson <andersson@kernel.org>,
Mathieu Poirier <mathieu.poirier@linaro.org>,
Shawn Guo <shawnguo@kernel.org>,
Sascha Hauer <s.hauer@pengutronix.de>,
Pengutronix Kernel Team <kernel@pengutronix.de>,
Fabio Estevam <festevam@gmail.com>,
imx@lists.linux.dev, linux-arm-kernel@lists.infradead.org,
linux-kernel@vger.kernel.org,
Hiago De Franco <hiago.franco@toradex.com>
Subject: [PATCH] remoteproc: imx_rproc: replace devm_clk_get() with devm_clk_get_optional()
Date: Wed, 23 Apr 2025 12:51:31 -0300 [thread overview]
Message-ID: <20250423155131.101473-1-hiagofranco@gmail.com> (raw)
From: Hiago De Franco <hiago.franco@toradex.com>
The "clocks" device tree property is not mandatory, and if not provided
Linux will shut down the remote processor power domain during boot if it
is not present, even if it is running (e.g. it was started by U-Boot's
bootaux command).
Use the optional devm_clk_get instead.
Signed-off-by: Hiago De Franco <hiago.franco@toradex.com>
---
drivers/remoteproc/imx_rproc.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/remoteproc/imx_rproc.c b/drivers/remoteproc/imx_rproc.c
index 74299af1d7f1..45b5b23980ec 100644
--- a/drivers/remoteproc/imx_rproc.c
+++ b/drivers/remoteproc/imx_rproc.c
@@ -1033,7 +1033,7 @@ static int imx_rproc_clk_enable(struct imx_rproc *priv)
if (dcfg->method == IMX_RPROC_NONE)
return 0;
- priv->clk = devm_clk_get(dev, NULL);
+ priv->clk = devm_clk_get_optional(dev, NULL);
if (IS_ERR(priv->clk)) {
dev_err(dev, "Failed to get clock\n");
return PTR_ERR(priv->clk);
--
2.39.5
next reply other threads:[~2025-04-23 15:52 UTC|newest]
Thread overview: 11+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-04-23 15:51 Hiago De Franco [this message]
2025-04-23 17:14 ` [PATCH] remoteproc: imx_rproc: replace devm_clk_get() with devm_clk_get_optional() Mathieu Poirier
2025-04-23 19:21 ` Hiago De Franco
2025-04-25 15:45 ` Mathieu Poirier
2025-04-26 13:49 ` Peng Fan
2025-04-26 21:47 ` Mathieu Poirier
2025-04-27 2:08 ` Peng Fan
2025-04-28 14:10 ` Hiago De Franco
2025-04-28 17:12 ` Hiago De Franco
2025-04-30 6:08 ` Peng Fan
2025-04-30 17:52 ` Hiago De Franco
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=20250423155131.101473-1-hiagofranco@gmail.com \
--to=hiagofranco@gmail.com \
--cc=andersson@kernel.org \
--cc=festevam@gmail.com \
--cc=hiago.franco@toradex.com \
--cc=imx@lists.linux.dev \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-remoteproc@vger.kernel.org \
--cc=mathieu.poirier@linaro.org \
--cc=s.hauer@pengutronix.de \
--cc=shawnguo@kernel.org \
/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