From: sergei.shtylyov@cogentembedded.com (Sergei Shtylyov)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 3/4] thermal: rcar: Add missing clock handling
Date: Wed, 08 Jan 2014 00:04:04 +0400 [thread overview]
Message-ID: <52CC5DB4.6070205@cogentembedded.com> (raw)
In-Reply-To: <1389121036-3555-4-git-send-email-geert@linux-m68k.org>
Hello.
On 07-01-2014 22:57, Geert Uytterhoeven wrote:
> From: Geert Uytterhoeven <geert+renesas@linux-m68k.org>
> When using DT to instantiate the rcar-thermal device, it prints the
> following error:
> rcar_thermal e61f0000.thermal: thermal sensor was broken
> Explicitly request and enable the thermal clock to fix this.
> Signed-off-by: Geert Uytterhoeven <geert+renesas@linux-m68k.org>
> ---
> drivers/thermal/rcar_thermal.c | 40 +++++++++++++++++++++++++++++++++-------
> 1 file changed, 33 insertions(+), 7 deletions(-)
> diff --git a/drivers/thermal/rcar_thermal.c b/drivers/thermal/rcar_thermal.c
> index 88f92e1a9944..a5629500723a 100644
> --- a/drivers/thermal/rcar_thermal.c
> +++ b/drivers/thermal/rcar_thermal.c
[...]
> @@ -378,23 +380,38 @@ static int rcar_thermal_probe(struct platform_device *pdev)
[...]
> + ret = clk_prepare(common->clk);
> + if (ret < 0) {
> + dev_err(&pdev->dev, "unable to prepare clock\n");
> + return ret;
> + }
> +
> + clk_enable(common->clk);
> +
Why not just clk_prepare_enable()?
[...]
> @@ -465,9 +484,13 @@ error_unregister:
> rcar_thermal_irq_disable(priv);
> }
>
> +error_unpm:
> pm_runtime_put_sync(dev);
> pm_runtime_disable(dev);
>
> + clk_disable(common->clk);
> + clk_unprepare(common->clk);
> +
Why not just clk_disable_unprepare()?
> return ret;
> }
>
> @@ -486,6 +509,9 @@ static int rcar_thermal_remove(struct platform_device *pdev)
> pm_runtime_put_sync(dev);
> pm_runtime_disable(dev);
>
> + clk_disable(common->clk);
> + clk_unprepare(common->clk);
> +
Likewise.
WBR, Sergei
next prev parent reply other threads:[~2014-01-07 20:04 UTC|newest]
Thread overview: 23+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-01-07 18:57 [PATCH 0/4] thermal: rcar: Add missing clock handling Geert Uytterhoeven
2014-01-07 18:57 ` [PATCH 1/4] ARM: shmobile: r8a7791: Add thermal clock in device tree Geert Uytterhoeven
2014-01-08 0:20 ` Laurent Pinchart
2014-01-08 0:52 ` Simon Horman
2014-01-07 18:57 ` [PATCH 2/4] ARM: shmobile: r8a7790: " Geert Uytterhoeven
2014-01-08 0:20 ` Laurent Pinchart
2014-01-08 0:52 ` Simon Horman
2014-01-07 18:57 ` [PATCH 3/4] thermal: rcar: Add missing clock handling Geert Uytterhoeven
2014-01-07 20:04 ` Sergei Shtylyov [this message]
2014-01-07 20:57 ` Gerhard Sittig
2014-01-08 12:20 ` Ben Dooks
2014-01-08 1:08 ` Kuninori Morimoto
2014-01-08 10:23 ` Geert Uytterhoeven
2014-01-13 8:57 ` Geert Uytterhoeven
2014-01-14 0:20 ` Kuninori Morimoto
2014-01-14 1:27 ` Simon Horman
2014-01-08 12:23 ` Ben Dooks
2014-01-08 12:58 ` Geert Uytterhoeven
2014-01-07 18:57 ` [PATCH -trivial 4/4] thermal: rcar: Spelling s/delaye/delay/g Geert Uytterhoeven
2014-01-08 0:12 ` Simon Horman
2014-01-17 8:23 ` Zhang Rui
2014-01-07 21:52 ` [PATCH 0/4] thermal: rcar: Add missing clock handling Valentine
2014-01-07 22:13 ` Geert Uytterhoeven
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=52CC5DB4.6070205@cogentembedded.com \
--to=sergei.shtylyov@cogentembedded.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).