public inbox for linux-arm-kernel@lists.infradead.org 
 help / color / mirror / Atom feed
From: gregory.clement@free-electrons•com (Gregory CLEMENT)
To: linux-arm-kernel@lists•infradead.org
Subject: [PATCH 1/2] ARM: mvebu: mvebu-soc-id: add missing clk_put() call
Date: Mon, 12 May 2014 17:03:22 +0200	[thread overview]
Message-ID: <5370E2BA.7040109@free-electrons.com> (raw)
In-Reply-To: <1399903900-29977-2-git-send-email-thomas.petazzoni@free-electrons.com>

Hi Thomas,

On 12/05/2014 16:11, Thomas Petazzoni wrote:
> The mvebu-soc-id code in mach-mvebu/ needs to enable a clock to read
> the SoC device ID and revision number. To do so, it does a clk_get(),
> then a clk_prepare_enable(), reads the value, and disables the clock
> with clk_disable_unprepare(). However, it forgets to clk_put() the
> clock. This commit fixes this issue.
> 
> Signed-off-by: Thomas Petazzoni <thomas.petazzoni@free-electrons•com>
> Cc: <stable@vger•kernel.org> # 3.14+
> Fixes: af8d1c63afcbf36eea06789c92e22d4af118d2fb ('ARM: mvebu: Add support to get the ID and the revision of a SoC')

Acked-by: Gregory CLEMENT <gregory.clement@free-electrons•com>


Thanks,

Gregory

> ---
>  arch/arm/mach-mvebu/mvebu-soc-id.c | 1 +
>  1 file changed, 1 insertion(+)
> 
> diff --git a/arch/arm/mach-mvebu/mvebu-soc-id.c b/arch/arm/mach-mvebu/mvebu-soc-id.c
> index f3d4cf5..b52af6f 100644
> --- a/arch/arm/mach-mvebu/mvebu-soc-id.c
> +++ b/arch/arm/mach-mvebu/mvebu-soc-id.c
> @@ -109,6 +109,7 @@ static int __init mvebu_soc_id_init(void)
>  
>  res_ioremap:
>  	clk_disable_unprepare(clk);
> +	clk_put(clk);
>  
>  clk_err:
>  	of_node_put(child);
> 


-- 
Gregory Clement, Free Electrons
Kernel, drivers, real-time and embedded Linux
development, consulting, training and support.
http://free-electrons.com

  reply	other threads:[~2014-05-12 15:03 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-05-12 14:11 [PATCH 0/2] ARM: mvebu: fix PCIe/mvebu-soc-id issue Thomas Petazzoni
2014-05-12 14:11 ` [PATCH 1/2] ARM: mvebu: mvebu-soc-id: add missing clk_put() call Thomas Petazzoni
2014-05-12 15:03   ` Gregory CLEMENT [this message]
2014-05-12 14:11 ` [PATCH 2/2] ARM: mvebu: mvebu-soc-id: keep clock enabled if PCIe unit is enabled Thomas Petazzoni
2014-05-12 15:18   ` Gregory CLEMENT
2014-05-12 15:30   ` Willy Tarreau
2014-05-12 14:33 ` [PATCH 0/2] ARM: mvebu: fix PCIe/mvebu-soc-id issue Andrew Lunn
2014-05-13  7:22 ` Willy Tarreau
2014-05-13 15:13 ` Jason Cooper
2014-05-13 15:17   ` Thomas Petazzoni

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=5370E2BA.7040109@free-electrons.com \
    --to=gregory.clement@free-electrons$(echo .)com \
    --cc=linux-arm-kernel@lists$(echo .)infradead.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html
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