linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: nicolas.ferre@atmel.com (Nicolas Ferre)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] clocksource: atmel-st: use return value from clk_prepare_enable()
Date: Tue, 19 Jan 2016 09:33:39 +0100	[thread overview]
Message-ID: <569DF4E3.2000302@atmel.com> (raw)
In-Reply-To: <1453145698-23661-1-git-send-email-alexandre.belloni@free-electrons.com>

Le 18/01/2016 20:34, Alexandre Belloni a ?crit :
> ret is used to detect an error but it was not properly updated after
> calling clk_prepare_enable() thus it made it impossible to detect an error
> when enabling the slow clock.
> 
> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
> ---
>  drivers/clocksource/timer-atmel-st.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/clocksource/timer-atmel-st.c b/drivers/clocksource/timer-atmel-st.c
> index 29d21d68df5a..c69070c6ad91 100644
> --- a/drivers/clocksource/timer-atmel-st.c
> +++ b/drivers/clocksource/timer-atmel-st.c
> @@ -225,7 +225,7 @@ static void __init atmel_st_timer_init(struct device_node *node)
>  	if (IS_ERR(sclk))
>  		panic(pr_fmt("Unable to get slow clock\n"));
>  
> -	clk_prepare_enable(sclk);
> +	ret = clk_prepare_enable(sclk);

Yes, sure...
Acked-by: Nicolas Ferre <nicolas.ferre@atmel.com>

Thanks!


>  	if (ret)
>  		panic(pr_fmt("Could not enable slow clock\n"));
>  
> 


-- 
Nicolas Ferre

  reply	other threads:[~2016-01-19  8:33 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-01-18 19:34 [PATCH] clocksource: atmel-st: use return value from clk_prepare_enable() Alexandre Belloni
2016-01-19  8:33 ` Nicolas Ferre [this message]
2016-01-19  8:49 ` Daniel Lezcano

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=569DF4E3.2000302@atmel.com \
    --to=nicolas.ferre@atmel.com \
    --cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).