From: Greg Ungerer <gerg@linux-m68k.org>
To: Dan Carpenter <dan.carpenter@oracle.com>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>,
Defang Bo <bodefang@126.com>, Steven King <sfking@fdwdc.com>,
linux-m68k@lists.linux-m68k.org, linux-kernel@vger.kernel.org,
kernel-janitors@vger.kernel.org,
Marc Kleine-Budde <mkl@pengutronix.de>,
Christophe JAILLET <christophe.jaillet@wanadoo.fr>
Subject: Re: [PATCH] m68k: coldfire: return success for clk_enable(NULL)
Date: Fri, 30 Jul 2021 16:56:36 +1000 [thread overview]
Message-ID: <10e74100-2f3b-6c71-3e13-ba9a33766bf1@linux-m68k.org> (raw)
In-Reply-To: <20210729122702.GA27150@kili>
On 29/7/21 10:27 pm, Dan Carpenter wrote:
> The clk_enable is supposed work when CONFIG_HAVE_CLK is false, but it
> returns -EINVAL. That means some drivers fail during probe.
>
> [ 1.680000] flexcan: probe of flexcan.0 failed with error -22
>
> Fixes: c1fb1bf64bb6 ("m68k: let clk_enable() return immediately if clk is NULL")
> Fixes: bea8bcb12da0 ("m68knommu: Add support for the Coldfire m5441x.")
> Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Thanks Dan.
Applied to the m68knommu git tree, for-next branch, with Marc's Acked-by added.
Regards
Greg
> ---
> I can't actually compile test this, but it's correct.
>
> arch/m68k/coldfire/clk.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/arch/m68k/coldfire/clk.c b/arch/m68k/coldfire/clk.c
> index 2ed841e94111..d03b6c4aa86b 100644
> --- a/arch/m68k/coldfire/clk.c
> +++ b/arch/m68k/coldfire/clk.c
> @@ -78,7 +78,7 @@ int clk_enable(struct clk *clk)
> unsigned long flags;
>
> if (!clk)
> - return -EINVAL;
> + return 0;
>
> spin_lock_irqsave(&clk_lock, flags);
> if ((clk->enabled++ == 0) && clk->clk_ops)
>
prev parent reply other threads:[~2021-07-30 6:56 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-07-29 12:27 [PATCH] m68k: coldfire: return success for clk_enable(NULL) Dan Carpenter
2021-07-29 12:36 ` Marc Kleine-Budde
2021-07-30 6:56 ` Greg Ungerer [this message]
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=10e74100-2f3b-6c71-3e13-ba9a33766bf1@linux-m68k.org \
--to=gerg@linux-m68k.org \
--cc=bodefang@126.com \
--cc=christophe.jaillet@wanadoo.fr \
--cc=dan.carpenter@oracle.com \
--cc=geert@linux-m68k.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-m68k@lists.linux-m68k.org \
--cc=mkl@pengutronix.de \
--cc=sfking@fdwdc.com \
/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;
as well as URLs for NNTP newsgroup(s).