<feed xmlns='http://www.w3.org/2005/Atom'>
<title>kernel/linux.git/drivers/cpufreq, branch linux-2.6.18.y</title>
<subtitle>Linux kernel stable tree (mirror)</subtitle>
<id>https://git.radix-linux.su/kernel/linux.git/atom?h=linux-2.6.18.y</id>
<link rel='self' href='https://git.radix-linux.su/kernel/linux.git/atom?h=linux-2.6.18.y'/>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/'/>
<updated>2006-10-13T20:23:26+00:00</updated>
<entry>
<title>CPUFREQ: Fix some more CPU hotplug locking.</title>
<updated>2006-10-13T20:23:26+00:00</updated>
<author>
<name>Dave Jones</name>
<email>davej@redhat.com</email>
</author>
<published>2006-09-23T01:00:03+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=967cc8158c385ac0087ae3455e8835fa7eb94fd0'/>
<id>urn:sha1:967cc8158c385ac0087ae3455e8835fa7eb94fd0</id>
<content type='text'>
[CPUFREQ] Fix some more CPU hotplug locking.

Lukewarm IQ detected in hotplug locking
BUG: warning at kernel/cpu.c:38/lock_cpu_hotplug()
[&lt;b0134a42&gt;] lock_cpu_hotplug+0x42/0x65
[&lt;b02f8af1&gt;] cpufreq_update_policy+0x25/0xad
[&lt;b0358756&gt;] kprobe_flush_task+0x18/0x40
[&lt;b0355aab&gt;] schedule+0x63f/0x68b
[&lt;b01377c2&gt;] __link_module+0x0/0x1f
[&lt;b0119e7d&gt;] __cond_resched+0x16/0x34
[&lt;b03560bf&gt;] cond_resched+0x26/0x31
[&lt;b0355b0e&gt;] wait_for_completion+0x17/0xb1
[&lt;f965c547&gt;] cpufreq_stat_cpu_callback+0x13/0x20 [cpufreq_stats]
[&lt;f9670074&gt;] cpufreq_stats_init+0x74/0x8b [cpufreq_stats]
[&lt;b0137872&gt;] sys_init_module+0x91/0x174
[&lt;b0102c81&gt;] sysenter_past_esp+0x56/0x79

As there are other places that call cpufreq_update_policy without
the hotplug lock, it seems better to keep the hotplug locking
at the lower level for the time being until this is revamped.

Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Greg Kroah-Hartman &lt;gregkh@suse.de&gt;

</content>
</entry>
<entry>
<title>[CPUFREQ] [2/2] demand load governor modules.</title>
<updated>2006-07-31T22:37:06+00:00</updated>
<author>
<name>Jeremy Fitzhardinge</name>
<email>jeremy@goop.org</email>
</author>
<published>2006-07-06T19:32:01+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ea71497020c55cd39221e0abad5c1752ac6e3f47'/>
<id>urn:sha1:ea71497020c55cd39221e0abad5c1752ac6e3f47</id>
<content type='text'>
Demand-load cpufreq governor modules if needed.

Signed-off-by: Jeremy Fitzhardinge &lt;jeremy@goop.org&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
</content>
</entry>
<entry>
<title>[CPUFREQ] [1/2] add __find_governor helper and clean up some error handling.</title>
<updated>2006-07-31T22:37:06+00:00</updated>
<author>
<name>Jeremy Fitzhardinge</name>
<email>jeremy@goop.org</email>
</author>
<published>2006-07-06T19:30:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=3bcb09a35641f2840bd59d8f82154f830dca282c'/>
<id>urn:sha1:3bcb09a35641f2840bd59d8f82154f830dca282c</id>
<content type='text'>
Adds a __find_governor() helper function to look up a governor by
name.  Also restructures some error handling to conform to the
"single-exit" model which is generally preferred for kernel code.

Signed-off-by: Jeremy Fitzhardinge &lt;jeremy@goop.org&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
</content>
</entry>
<entry>
<title>[CPUFREQ] return error when failing to set minfreq</title>
<updated>2006-07-31T22:37:05+00:00</updated>
<author>
<name>Mattia Dongili</name>
<email>malattia@linux.it</email>
</author>
<published>2006-07-05T21:12:20+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=9c9a43ed2734081124407c779b36a4761c41139b'/>
<id>urn:sha1:9c9a43ed2734081124407c779b36a4761c41139b</id>
<content type='text'>
I just stumbled on this bug/feature, this is how to reproduce it:

# echo 450000 &gt; /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq
# echo 450000 &gt; /sys/devices/system/cpu/cpu0/cpufreq/scaling_max_freq
# echo powersave &gt; /sys/devices/system/cpu/cpu0/cpufreq/scaling_governor
# cpufreq-info -p
450000 450000 powersave
# echo 1800000 &gt; /sys/devices/system/cpu/cpu0/cpufreq/scaling_min_freq ; echo $?
0
# cpufreq-info -p
450000 450000 powersave

Here it is. The kernel refuses to set a min_freq higher than the
max_freq but it allows a max_freq lower than min_freq (lowering min_freq
also).

This behaviour is pretty straightforward (but undocumented) and it
doesn't return an error altough failing to accomplish the requested
action (set min_freq).
The problem (IMO) is basically that userspace is not allowed to set a
full policy atomically while the kernel always does that thus it must
enforce an ordering on operations.

The attached patch returns -EINVAL if trying to increase frequencies
starting from scaling_min_freq and documents the correct ordering of writes.

Signed-off-by: Mattia Dongili &lt;malattia@linux.it&gt;
Signed-off-by: Dominik Brodowski &lt;linux at dominikbrodowski.net&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;

--
</content>
</entry>
<entry>
<title>[PATCH] Reorganize the cpufreq cpu hotplug locking to not be totally bizare</title>
<updated>2006-07-26T14:21:40+00:00</updated>
<author>
<name>Arjan van de Ven</name>
<email>arjan@linux.intel.com</email>
</author>
<published>2006-07-26T13:40:07+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=153d7f3fcae7ed4e19328549aa9467acdfbced10'/>
<id>urn:sha1:153d7f3fcae7ed4e19328549aa9467acdfbced10</id>
<content type='text'>
The patch below moves the cpu hotplugging higher up in the cpufreq
layering; this is needed to avoid recursive taking of the cpu hotplug
lock and to otherwise detangle the mess.

The new rules are:
1. you must do lock_cpu_hotplug() around the following functions:
   __cpufreq_driver_target
   __cpufreq_governor (for CPUFREQ_GOV_LIMITS operation only)
   __cpufreq_set_policy
2. governer methods (.governer) must NOT take the lock_cpu_hotplug()
   lock in any way; they are called with the lock taken already
3. if your governer spawns a thread that does things, like calling
   __cpufreq_driver_target, your thread must honor rule #1.
4. the policy lock and other cpufreq internal locks nest within
   the lock_cpu_hotplug() lock.

I'm not entirely happy about how the __cpufreq_governor rule ended up
(conditional locking rule depending on the argument) but basically all
callers pass this as a constant so it's not too horrible.

The patch also removes the cpufreq_governor() function since during the
locking audit it turned out to be entirely unused (so no need to fix it)

The patch works on my testbox, but it could use more testing
(otoh... it can't be much worse than the current code)

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
</entry>
<entry>
<title>[cpufreq] ondemand: make shutdown sequence more robust</title>
<updated>2006-07-23T19:05:00+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@macmini.osdl.org</email>
</author>
<published>2006-07-23T19:05:00+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=2cd7cbdf4bd0d0fe58e4dc903e8b413412595504'/>
<id>urn:sha1:2cd7cbdf4bd0d0fe58e4dc903e8b413412595504</id>
<content type='text'>
Shutting down the ondemand policy was fraught with potential
problems, causing issues for SMP suspend (which wants to hot-
unplug) all but the last CPU.

This should fix at least the worst problems (divide-by-zero
and infinite wait for the workqueue to shut down).

Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
</entry>
<entry>
<title>[PATCH] Fix cpufreq vs hotplug lockdep recursion.</title>
<updated>2006-07-07T16:46:45+00:00</updated>
<author>
<name>Dave Jones</name>
<email>davej@redhat.com</email>
</author>
<published>2006-07-07T16:31:27+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=a496e25dfb25493a57bcee5d66875d6ff80a9093'/>
<id>urn:sha1:a496e25dfb25493a57bcee5d66875d6ff80a9093</id>
<content type='text'>
[ There's some not quite baked bits in cpufreq-git right now
  so sending this on as a patch instead ]

On Thu, 2006-07-06 at 07:58 -0700, Tom London wrote:

&gt; After installing .2356 I get this each time I boot:
&gt; =======================================================
&gt; [ INFO: possible circular locking dependency detected ]
&gt; -------------------------------------------------------
&gt; S06cpuspeed/1620 is trying to acquire lock:
&gt;  (dbs_mutex){--..}, at: [&lt;c060d6bb&gt;] mutex_lock+0x21/0x24
&gt;
&gt; but task is already holding lock:
&gt;  (cpucontrol){--..}, at: [&lt;c060d6bb&gt;] mutex_lock+0x21/0x24
&gt;
&gt; which lock already depends on the new lock.
&gt;

make sure the cpu hotplug recursive mutex (yuck) is taken early in the
cpufreq codepaths to avoid a AB-BA deadlock.

Signed-off-by: Arjan van de Ven &lt;arjan@linux.intel.com&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
Signed-off-by: Linus Torvalds &lt;torvalds@osdl.org&gt;
</content>
</entry>
<entry>
<title>Merge master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq</title>
<updated>2006-07-04T21:00:26+00:00</updated>
<author>
<name>Linus Torvalds</name>
<email>torvalds@g5.osdl.org</email>
</author>
<published>2006-07-04T21:00:26+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ca78f6baca863afe2e6a244a0fe94b3a70211d46'/>
<id>urn:sha1:ca78f6baca863afe2e6a244a0fe94b3a70211d46</id>
<content type='text'>
* master.kernel.org:/pub/scm/linux/kernel/git/davej/cpufreq:
  Move workqueue exports to where the functions are defined.
  [CPUFREQ] Misc cleanups in ondemand.
  [CPUFREQ] Make ondemand sampling per CPU and remove the mutex usage in sampling path.
  [CPUFREQ] Add queue_delayed_work_on() interface for workqueues.
  [CPUFREQ] Remove slowdown from ondemand sampling path.
</content>
</entry>
<entry>
<title>Remove obsolete #include &lt;linux/config.h&gt;</title>
<updated>2006-06-30T17:25:36+00:00</updated>
<author>
<name>Jörn Engel</name>
<email>joern@wohnheim.fh-wedel.de</email>
</author>
<published>2006-06-30T17:25:36+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=6ab3d5624e172c553004ecc862bfeac16d9d68b7'/>
<id>urn:sha1:6ab3d5624e172c553004ecc862bfeac16d9d68b7</id>
<content type='text'>
Signed-off-by: Jörn Engel &lt;joern@wohnheim.fh-wedel.de&gt;
Signed-off-by: Adrian Bunk &lt;bunk@stusta.de&gt;
</content>
</entry>
<entry>
<title>[CPUFREQ] Misc cleanups in ondemand.</title>
<updated>2006-06-30T05:36:40+00:00</updated>
<author>
<name>Venkatesh Pallipadi</name>
<email>venkatesh.pallipadi@intel.com</email>
</author>
<published>2006-06-28T20:52:18+00:00</published>
<link rel='alternate' type='text/html' href='https://git.radix-linux.su/kernel/linux.git/commit/?id=ffac80e925e54d84f6ea580231aa46d0ef051756'/>
<id>urn:sha1:ffac80e925e54d84f6ea580231aa46d0ef051756</id>
<content type='text'>
Misc cleanups in ondemand. Should have zero functional impact.
Also adding Alexey as author.

Signed-off-by: Alexey Starikovskiy &lt;alexey.y.starikovskiy@intel.com&gt;
Signed-off-by: Venkatesh Pallipadi &lt;venkatesh.pallipadi@intel.com&gt;
Signed-off-by: Dave Jones &lt;davej@redhat.com&gt;
</content>
</entry>
</feed>
