linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Peter De Schrijver <pdeschrijver@nvidia.com>
To: Stephen Boyd <sboyd@codeaurora.org>
Cc: Michael Turquette <mturquette@baylibre.com>,
	<linux-clk@vger.kernel.org>, <linux-kernel@vger.kernel.org>
Subject: Re: [PATCH] clk: Re-evaluate clock rate on min/max update
Date: Fri, 28 Apr 2017 10:17:43 +0300	[thread overview]
Message-ID: <20170428071743.GL30730@tbergstrom-lnx.Nvidia.com> (raw)
In-Reply-To: <20170413074819.GS30730@tbergstrom-lnx.Nvidia.com>

On Thu, Apr 13, 2017 at 10:48:19AM +0300, Peter De Schrijver wrote:
> On Wed, Apr 12, 2017 at 09:46:05AM -0700, Stephen Boyd wrote:
> > On 03/21, Peter De Schrijver wrote:
> > > Whenever a user change its min or max rate limit of a clock, we need to
> > > re-evaluate the current clock rate and possibly change it if the new limits
> > > require so. To do this clk_set_rate_range() already calls
> > > clk_core_set_rate_nolock, however this won't have the intended effect
> > > because the core clock rate hasn't changed. To fix this, move the test to
> > > avoid setting the same core clock rate again, to clk_set_rate() so
> > > clk_core_set_rate_nolock() can change the clock rate when min or max have
> > > been updated, even when the core clock rate has not changed.
> > 
> > I'd expect some sort of Fixes: tag here? Or it never worked!?
> 
> I don't think this ever worked.
> 
> > 
> > > 
> > > Signed-off-by: Peter De Schrijver <pdeschrijver@nvidia.com>
> > 
> > I seem to recall some problems here around rate aggregation that
> > we fixed after the patches merged. Sorry, but I have to go back
> > and look at those conversations to refresh my memory and make
> > sure this is all fine.
> > 
> > Are you relying on the rate setting op to be called with the new
> > min/max requirements if the aggregated rate is the same? I don't
> > understand why clk drivers care.
> > 
> 
> No. But I do rely on the rate setting op to be called when a new min or max
> rate would cause the rate to be changed even when there is no new rate request.
> 
> Eg:
> 
> min = 100MHz, max = 500MHz, current rate request is 400MHz, then max changes to
> 300MHz. Today the rate setting op will not be called, while I think it should
> be called to lower the rate to 300MHz.
> 

Any news on this? or do you think this is an unreasonable assumption?

Thanks,

Peter.

  reply	other threads:[~2017-04-28  7:18 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-03-21 13:43 [PATCH] clk: Re-evaluate clock rate on min/max update Peter De Schrijver
2017-04-07 11:44 ` Peter De Schrijver
2017-04-12 16:46 ` Stephen Boyd
2017-04-13  7:48   ` Peter De Schrijver
2017-04-28  7:17     ` Peter De Schrijver [this message]
2017-05-16  7:38       ` Peter De Schrijver
2017-06-01  9:12     ` Stephen Boyd
2017-06-02 10:15       ` Peter De Schrijver
2017-06-02 22:45         ` Stephen Boyd

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=20170428071743.GL30730@tbergstrom-lnx.Nvidia.com \
    --to=pdeschrijver@nvidia.com \
    --cc=linux-clk@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=mturquette@baylibre.com \
    --cc=sboyd@codeaurora.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).