All of lore.kernel.org
 help / color / mirror / Atom feed
From: viresh.kumar@st.com (Viresh Kumar)
To: linux-arm-kernel@lists.infradead.org
Subject: announcing the clk-next branch
Date: Fri, 27 Apr 2012 09:40:55 +0530	[thread overview]
Message-ID: <4F9A1C4F.6020304@st.com> (raw)
In-Reply-To: <CAJOA=zOGSh3et4nxE=JdojL4uDjgt8o+oiOU4pmbM=oU2U6prA@mail.gmail.com>

On 4/25/2012 7:02 AM, Turquette, Mike wrote:
> If the branch is missing anything that I have ACK'd then please let me know.

Author: Viresh Kumar <viresh.kumar@st.com>
Date:   Wed Apr 11 11:34:35 2012 +0530

    clk: clk_set_rate() must fail if CLK_SET_RATE_GATE is set and clk is enabled
    
    This is well documented but isn't implemented. clk_set_rate() must check if
    flags have CLK_SET_RATE_GATE bit set and is enabled too.
    
    Untested patch.
    
    Signed-off-by: Viresh Kumar <viresh.kumar@st.com>
---
 drivers/clk/clk.c |    5 +++++
 1 files changed, 5 insertions(+), 0 deletions(-)

diff --git a/drivers/clk/clk.c b/drivers/clk/clk.c
index 865d0dd..2bcce5a 100644
--- a/drivers/clk/clk.c
+++ b/drivers/clk/clk.c
@@ -898,6 +898,11 @@ int clk_set_rate(struct clk *clk, unsigned long rate)
        if (rate == clk->rate)
                goto out;
 
+       if ((clk->flags & CLK_SET_RATE_GATE) && __clk_is_enabled(clk)) {
+               ret = -EBUSY;
+               goto out;
+       }
+


-- 
viresh

  parent reply	other threads:[~2012-04-27  4:10 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-25  1:32 announcing the clk-next branch Turquette, Mike
2012-04-25 12:38 ` Sascha Hauer
2012-04-25 12:42   ` Russell King - ARM Linux
2012-04-25 15:15     ` Turquette, Mike
2012-04-26  3:56 ` Viresh Kumar
2012-04-30 14:41   ` Arnd Bergmann
2012-04-30 16:16     ` viresh kumar
2012-04-30 16:37       ` Arnd Bergmann
2012-04-30 16:40         ` viresh kumar
2012-04-30 17:00           ` Arnd Bergmann
2012-04-27  4:10 ` Viresh Kumar [this message]
2012-04-27  6:14 ` Viresh Kumar
2012-04-27  7:09   ` Shawn Guo
2012-04-27 17:54     ` Turquette, Mike
2012-04-28  4:52       ` Shawn Guo
2012-04-30 14:43       ` Arnd Bergmann

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=4F9A1C4F.6020304@st.com \
    --to=viresh.kumar@st.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.