<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux-dev/drivers/cpufreq/tegra-cpufreq.c, branch linus/master</title>
<subtitle>Linux kernel development work - see feature branches</subtitle>
<id>https://git.zx2c4.com/linux-dev/atom/drivers/cpufreq/tegra-cpufreq.c?h=linus%2Fmaster</id>
<link rel='self' href='https://git.zx2c4.com/linux-dev/atom/drivers/cpufreq/tegra-cpufreq.c?h=linus%2Fmaster'/>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/'/>
<updated>2015-07-16T07:34:08Z</updated>
<entry>
<title>cpufreq: tegra: Rename tegra-cpufreq to tegra20-cpufreq</title>
<updated>2015-07-16T07:34:08Z</updated>
<author>
<name>Tuomas Tynkkynen</name>
<email>ttynkkynen@nvidia.com</email>
</author>
<published>2015-05-13T14:58:47Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=109e13eaa40dfebf8893234cc5f1535a04e23acf'/>
<id>urn:sha1:109e13eaa40dfebf8893234cc5f1535a04e23acf</id>
<content type='text'>
The Tegra124 will use a different driver for frequency scaling, so
rename the old driver (which handles only Tegra20) appropriately.

Signed-off-by: Tuomas Tynkkynen &lt;ttynkkynen@nvidia.com&gt;
Signed-off-by: Mikko Perttunen &lt;mikko.perttunen@kapsi.fi&gt;
Acked-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Thierry Reding &lt;treding@nvidia.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: tegra: update comment for clarity</title>
<updated>2014-06-10T20:50:50Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-06-10T04:57:12Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=40cc5490132075d7be85a4483caa0a7264f45ed4'/>
<id>urn:sha1:40cc5490132075d7be85a4483caa0a7264f45ed4</id>
<content type='text'>
Tegra's driver got updated a bit (00917dd cpufreq: Tegra: implement intermediate
frequency callbacks) and implements new 'intermediate freq' infrastructure of
core. Above commit updated comments about when to call
clk_prepare_enable(pll_x_clk) and Doug wasn't satisfied with those comments and
said this:

&gt; The "Though when target-freq is intermediate freq, we don't need to
&gt; take this reference." makes me think that this function is actually
&gt; called when target-freq is intermediate freq.  I don't think it is,
&gt; right?

For better clarity just make that comment more explicit about when we call
tegra_target_intermediate().

Reviewed-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Reported-and-reviewed-by: Doug Anderson &lt;dianders@chromium.org&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Tegra: implement intermediate frequency callbacks</title>
<updated>2014-06-05T21:34:07Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-06-02T17:19:29Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=00917ddc7c2fa7d2790241ed3570e8e4a0466923'/>
<id>urn:sha1:00917ddc7c2fa7d2790241ed3570e8e4a0466923</id>
<content type='text'>
Tegra has been switching to intermediate frequency (pll_p_clk) forever.
CPUFreq core has better support for handling notifications for these
frequencies and so we can adapt Tegra's driver to it.

Also do a WARN() if clk_set_parent() fails while moving back to pll_x
as we should have atleast restored to earlier frequency on error.

Tested-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Reviewed-by: Doug Anderson &lt;dianders@chromium.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Tegra: drop wrapper around tegra_update_cpu_speed()</title>
<updated>2014-05-16T23:38:31Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-05-15T05:51:19Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=e7b453d3dd5f251f13bf4670037af70bf611d0cb'/>
<id>urn:sha1:e7b453d3dd5f251f13bf4670037af70bf611d0cb</id>
<content type='text'>
Tegra has implemented an unnecessary wrapper over tegra_update_cpu_speed(), i.e.
tegra_target(), which wasn't doing anything apart of calling
tegra_update_cpu_speed(). Get rid of that and use tegra_target() directly.

Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Acked-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: add 'freq_table' in struct cpufreq_policy</title>
<updated>2014-03-12T00:06:00Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-03-10T09:23:33Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=e0b3165ba521c6824b3e9f563f38a701dfa2d8e6'/>
<id>urn:sha1:e0b3165ba521c6824b3e9f563f38a701dfa2d8e6</id>
<content type='text'>
freq table is not per CPU but per policy, so it makes more sense to
keep it within struct cpufreq_policy instead of a per-cpu variable.

This patch does it. Over that, there is no need to set policy-&gt;freq_table
to NULL in -&gt;exit(), as policy structure is going to be freed soon.

Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Tegra: Use cpufreq_generic_suspend()</title>
<updated>2014-03-06T14:04:12Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-03-04T03:00:30Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=d351cb31146833b67b6db7e46dcd6cb766d584ae'/>
<id>urn:sha1:d351cb31146833b67b6db7e46dcd6cb766d584ae</id>
<content type='text'>
The cpufreq core now supports suspending and resuming of cpufreq
drivers and governors during systems suspend and resume, so use
the common infrastructure instead of defining special PM notifiers
for the same thing.

Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Tested-by: Stephen Warren &lt;swarren@nvidia.com&gt;
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: introduce cpufreq_generic_get() routine</title>
<updated>2014-01-17T01:00:44Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2014-01-09T15:08:43Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=652ed95d5fa6074b3c4ea245deb0691f1acb6656'/>
<id>urn:sha1:652ed95d5fa6074b3c4ea245deb0691f1acb6656</id>
<content type='text'>
CPUFreq drivers that use clock frameworks interface,i.e. clk_get_rate(),
to get CPUs clk rate, have similar sort of code used in most of them.

This patch adds a generic -&gt;get() which will do the same thing for them.
All those drivers are required to now is to set .get to cpufreq_generic_get()
and set their clk pointer in policy-&gt;clk during -&gt;init().

Acked-by: Hans-Christian Egtvedt &lt;egtvedt@samfundet.no&gt;
Acked-by: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Acked-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Acked-by: Shawn Guo &lt;shawn.guo@linaro.org&gt;
Acked-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Mark ARM drivers with CPUFREQ_NEED_INITIAL_FREQ_CHECK flag</title>
<updated>2014-01-06T13:17:25Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2013-12-03T05:50:45Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=ae6b427132ba39d023e332e7d920e9931ff05313'/>
<id>urn:sha1:ae6b427132ba39d023e332e7d920e9931ff05313</id>
<content type='text'>
Sometimes boot loaders set CPU frequency to a value outside of frequency table
present with cpufreq core. In such cases CPU might be unstable if it has to run
on that frequency for long duration of time and so its better to set it to a
frequency which is specified in frequency table.

On some systems we can't really say what frequency we're running at the moment
and so for these we shouldn't check if we are running at a frequency present in
frequency table. And so we really can't force this for all the cpufreq drivers.

Hence we are created another flag here: CPUFREQ_NEED_INITIAL_FREQ_CHECK that
will be marked by platforms which want to go for this check at boot time.

Initially this is done for all ARM platforms but others may follow if required.

Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: tegra: don't error target() when suspended</title>
<updated>2013-11-20T22:28:32Z</updated>
<author>
<name>Stephen Warren</name>
<email>swarren@nvidia.com</email>
</author>
<published>2013-11-20T21:06:22Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=2239aa3d15056e4be807eaa8d778b247156ce552'/>
<id>urn:sha1:2239aa3d15056e4be807eaa8d778b247156ce552</id>
<content type='text'>
d4019f0a92ab "cpufreq: move freq change notifications to cpufreq core"
added code to the cpufreq core to print an error if a cpufreq driver's
.target() function returned an error. This exposed the fact that Tegra's
cpufreq driver returns an error when it is ignoring requests due to the
system being suspended.

Modify Tegra's .target() function not to return an error in this case;
this prevents the error prints. The argument is that since the suspend
hook can't and doesn't inform the cpufreq core when its requests will
be ignored, there's no way for the cpufreq core to squelch them, so it's
not an error for the requests to keep coming. This change make the Tegra
driver consistent with how the Exynos handles the same situation. Note
that s5pv210-cpufreq.c probably suffers from this same issue though.

Fixes: d4019f0a92ab (cpufreq: move freq change notifications to cpufreq core)
Signed-off-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: move freq change notifications to cpufreq core</title>
<updated>2013-10-30T23:11:08Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2013-08-14T14:08:24Z</published>
<link rel='alternate' type='text/html' href='https://git.zx2c4.com/linux-dev/commit/?id=d4019f0a92ab802f385cc9c8ad3ab7b5449712cb'/>
<id>urn:sha1:d4019f0a92ab802f385cc9c8ad3ab7b5449712cb</id>
<content type='text'>
Most of the drivers do following in their -&gt;target_index() routines:

	struct cpufreq_freqs freqs;
	freqs.old = old freq...
	freqs.new = new freq...

	cpufreq_notify_transition(policy, &amp;freqs, CPUFREQ_PRECHANGE);

	/* Change rate here */

	cpufreq_notify_transition(policy, &amp;freqs, CPUFREQ_POSTCHANGE);

This is replicated over all cpufreq drivers today and there doesn't exists a
good enough reason why this shouldn't be moved to cpufreq core instead.

There are few special cases though, like exynos5440, which doesn't do everything
on the call to -&gt;target_index() routine and call some kind of bottom halves for
doing this work, work/tasklet/etc..

They may continue doing notification from their own code as flag:
CPUFREQ_ASYNC_NOTIFICATION is already set for them.

All drivers are also modified in this patch to avoid breaking 'git bisect', as
double notification would happen otherwise.

Acked-by: Hans-Christian Egtvedt &lt;egtvedt@samfundet.no&gt;
Acked-by: Jesper Nilsson &lt;jesper.nilsson@axis.com&gt;
Acked-by: Linus Walleij &lt;linus.walleij@linaro.org&gt;
Acked-by: Russell King &lt;linux@arm.linux.org.uk&gt;
Acked-by: Stephen Warren &lt;swarren@nvidia.com&gt;
Tested-by: Andrew Lunn &lt;andrew@lunn.ch&gt;
Tested-by: Nicolas Pitre &lt;nicolas.pitre@linaro.org&gt;
Reviewed-by: Lan Tianyu &lt;tianyu.lan@intel.com&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
</feed>
