public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
* cpufreq: get cpufreq_frequency_table from clk driver
@ 2017-02-21 11:13 Vlad Zakharov
  2017-02-23  4:54 ` Viresh Kumar
  0 siblings, 1 reply; 2+ messages in thread
From: Vlad Zakharov @ 2017-02-21 11:13 UTC (permalink / raw)
  To: linux-pm@vger.kernel.org
  Cc: linux-kernel@vger.kernel.org, viresh.kumar@linaro.org,
	mturquette@baylibre.com, sboyd@codeaurora.org, rjw@rjwysocki.net,
	linux-clk@vger.kernel.org, linux-snps-arc@lists.infradead.org

Hello,

I am trying to implement a cpufreq driver for ARCHS cpu.

And I faced with one question I am not able to answer myself. cpufreq framework allows us using cpufreq frequency tables
that store available for current policy range of frequencies with any additional data. As I understand for example it
can be clock configurations for this particular frequency.

Also I have a clk driver that manages actual cpu frequency. In fact it uses very similar tables that contain frequencies
and corresponding values of clock configurations registers that are to be set up with current frequency.

So the question is can I get such tables from clk driver somehow? I would be very convenient: this tables differs for
ARCHS CPU. E.g. on different boards it is clocked by different PLLs and oscillators.

Do you know any way to get the tables from clk driver? Any suggestions or comments might be very helpful.

Thanks!

-- 
Best regards,
Vlad Zakharov <vzakhar@synopsys.com>

^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: cpufreq: get cpufreq_frequency_table from clk driver
  2017-02-21 11:13 cpufreq: get cpufreq_frequency_table from clk driver Vlad Zakharov
@ 2017-02-23  4:54 ` Viresh Kumar
  0 siblings, 0 replies; 2+ messages in thread
From: Viresh Kumar @ 2017-02-23  4:54 UTC (permalink / raw)
  To: Vlad Zakharov
  Cc: linux-pm@vger.kernel.org, linux-kernel@vger.kernel.org,
	mturquette@baylibre.com, sboyd@codeaurora.org, rjw@rjwysocki.net,
	linux-clk@vger.kernel.org, linux-snps-arc@lists.infradead.org

On 21-02-17, 11:13, Vlad Zakharov wrote:
> Hello,
> 
> I am trying to implement a cpufreq driver for ARCHS cpu.

You mean ARC architecture here ?

> And I faced with one question I am not able to answer myself. cpufreq framework allows us using cpufreq frequency tables
> that store available for current policy range of frequencies with any additional data. As I understand for example it
> can be clock configurations for this particular frequency.

Yes, it can be any platform specific data. Yes, but it is better
handled by the clk driver in your case and cpufreq driver just needs
to call clk_set_rate().

> Also I have a clk driver that manages actual cpu frequency. In fact it uses very similar tables that contain frequencies
> and corresponding values of clock configurations registers that are to be set up with current frequency.

Good.

> So the question is can I get such tables from clk driver somehow? I would be very convenient: this tables differs for
> ARCHS CPU. E.g. on different boards it is clocked by different PLLs and oscillators.

Not that I am aware of. Just make copies for every board or if you can
use device tree, get it using OPP tables.

-- 
viresh

^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2017-02-23  4:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2017-02-21 11:13 cpufreq: get cpufreq_frequency_table from clk driver Vlad Zakharov
2017-02-23  4:54 ` Viresh Kumar

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox