<feed xmlns='http://www.w3.org/2005/Atom'>
<title>linux/drivers/cpufreq, branch v3.13</title>
<subtitle>Mirror of https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/
</subtitle>
<id>https://git.shady.money/linux/atom?h=v3.13</id>
<link rel='self' href='https://git.shady.money/linux/atom?h=v3.13'/>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/'/>
<updated>2014-01-06T21:16:14Z</updated>
<entry>
<title>intel_pstate: Add X86_FEATURE_APERFMPERF to cpu match parameters.</title>
<updated>2014-01-06T21:16:14Z</updated>
<author>
<name>Dirk Brandewie</name>
<email>dirk.j.brandewie@intel.com</email>
</author>
<published>2014-01-06T18:59:16Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=6cbd7ee10e2842a3d1f9b60abede1c8f3d1f1130'/>
<id>urn:sha1:6cbd7ee10e2842a3d1f9b60abede1c8f3d1f1130</id>
<content type='text'>
KVM environments do not support APERF/MPERF MSRs. intel_pstate cannot
operate without these registers.

The previous validity checks in intel_pstate_msrs_not_valid() are
insufficent in nested KVMs.

References: https://bugzilla.redhat.com/show_bug.cgi?id=1046317
Signed-off-by: Dirk Brandewie &lt;dirk.j.brandewie@intel.com&gt;
Cc: All applicable &lt;stable@vger.kernel.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>intel_pstate: Fail initialization if P-state information is missing</title>
<updated>2013-12-31T12:37:46Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2013-12-31T12:37:46Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=98a947abdd54e5de909bebadfced1696ccad30cf'/>
<id>urn:sha1:98a947abdd54e5de909bebadfced1696ccad30cf</id>
<content type='text'>
If pstate.current_pstate is 0 after the initial
intel_pstate_get_cpu_pstates(), this means that we were unable to
obtain any useful P-state information and there is no reason to
continue, so free memory and return an error in that case.

This fixes the following divide error occuring in a nested KVM
guest:

Intel P-state driver initializing.
Intel pstate controlling: cpu 0
cpufreq: __cpufreq_add_dev: -&gt;get() failed
divide error: 0000 [#1] SMP
Modules linked in:
CPU: 0 PID: 1 Comm: swapper/0 Not tainted 3.13.0-0.rc4.git5.1.fc21.x86_64 #1
Hardware name: Bochs Bochs, BIOS Bochs 01/01/2011
task: ffff88001ea20000 ti: ffff88001e9bc000 task.ti: ffff88001e9bc000
RIP: 0010:[&lt;ffffffff815c551d&gt;]  [&lt;ffffffff815c551d&gt;] intel_pstate_timer_func+0x11d/0x2b0
RSP: 0000:ffff88001ee03e18  EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffff88001a454348 RCX: 0000000000006100
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffff88001ee03e38 R08: 0000000000000000 R09: 0000000000000000
R10: ffff88001ea20000 R11: 0000000000000000 R12: 00000c0a1ea20000
R13: 1ea200001ea20000 R14: ffffffff815c5400 R15: ffff88001a454348
FS:  0000000000000000(0000) GS:ffff88001ee00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 000000008005003b
CR2: 0000000000000000 CR3: 0000000001c0c000 CR4: 00000000000006f0
Stack:
 fffffffb1a454390 ffffffff821a4500 ffff88001a454390 0000000000000100
 ffff88001ee03ea8 ffffffff81083e9a ffffffff81083e15 ffffffff82d5ed40
 ffffffff8258cc60 0000000000000000 ffffffff81ac39de 0000000000000000
Call Trace:
 &lt;IRQ&gt;
 [&lt;ffffffff81083e9a&gt;] call_timer_fn+0x8a/0x310
 [&lt;ffffffff81083e15&gt;] ? call_timer_fn+0x5/0x310
 [&lt;ffffffff815c5400&gt;] ? pid_param_set+0x130/0x130
 [&lt;ffffffff81084354&gt;] run_timer_softirq+0x234/0x380
 [&lt;ffffffff8107aee4&gt;] __do_softirq+0x104/0x430
 [&lt;ffffffff8107b5fd&gt;] irq_exit+0xcd/0xe0
 [&lt;ffffffff81770645&gt;] smp_apic_timer_interrupt+0x45/0x60
 [&lt;ffffffff8176efb2&gt;] apic_timer_interrupt+0x72/0x80
 &lt;EOI&gt;
 [&lt;ffffffff810e15cd&gt;] ? vprintk_emit+0x1dd/0x5e0
 [&lt;ffffffff81757719&gt;] printk+0x67/0x69
 [&lt;ffffffff815c1493&gt;] __cpufreq_add_dev.isra.13+0x883/0x8d0
 [&lt;ffffffff815c14f0&gt;] cpufreq_add_dev+0x10/0x20
 [&lt;ffffffff814a14d1&gt;] subsys_interface_register+0xb1/0xf0
 [&lt;ffffffff815bf5cf&gt;] cpufreq_register_driver+0x9f/0x210
 [&lt;ffffffff81fb19af&gt;] intel_pstate_init+0x27d/0x3be
 [&lt;ffffffff81761e3e&gt;] ? mutex_unlock+0xe/0x10
 [&lt;ffffffff81fb1732&gt;] ? cpufreq_gov_dbs_init+0x12/0x12
 [&lt;ffffffff8100214a&gt;] do_one_initcall+0xfa/0x1b0
 [&lt;ffffffff8109dbf5&gt;] ? parse_args+0x225/0x3f0
 [&lt;ffffffff81f64193&gt;] kernel_init_freeable+0x1fc/0x287
 [&lt;ffffffff81f638d0&gt;] ? do_early_param+0x88/0x88
 [&lt;ffffffff8174b530&gt;] ? rest_init+0x150/0x150
 [&lt;ffffffff8174b53e&gt;] kernel_init+0xe/0x130
 [&lt;ffffffff8176e27c&gt;] ret_from_fork+0x7c/0xb0
 [&lt;ffffffff8174b530&gt;] ? rest_init+0x150/0x150
Code: c1 e0 05 48 63 bc 03 10 01 00 00 48 63 83 d0 00 00 00 48 63 d6 48 c1 e2 08 c1 e1 08 4c 63 c2 48 c1 e0 08 48 98 48 c1 e0 08 48 99 &lt;49&gt; f7 f8 48 98 48 0f af f8 48 c1 ff 08 29 f9 89 ca c1 fa 1f 89
RIP  [&lt;ffffffff815c551d&gt;] intel_pstate_timer_func+0x11d/0x2b0
 RSP &lt;ffff88001ee03e18&gt;
---[ end trace f166110ed22cc37a ]---
Kernel panic - not syncing: Fatal exception in interrupt

Reported-and-tested-by: Kashyap Chamarthy &lt;kchamart@redhat.com&gt;
Cc: Josh Boyer &lt;jwboyer@fedoraproject.org&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
Cc: All applicable &lt;stable@vger.kernel.org&gt;
</content>
</entry>
<entry>
<title>cpufreq: preserve user_policy across suspend/resume</title>
<updated>2013-12-29T14:31:21Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2013-12-24T01:41:01Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=08fd8c1cf0a99abf34e09a8b99b74872e0d73a23'/>
<id>urn:sha1:08fd8c1cf0a99abf34e09a8b99b74872e0d73a23</id>
<content type='text'>
Prevent __cpufreq_add_dev() from overwriting the existing values of
user_policy.{min|max|policy|governor} with defaults during resume
from system suspend.

Fixes: 5302c3fb2e62 ("cpufreq: Perform light-weight init/teardown during suspend/resume")
Reported-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Cc: 3.12+ &lt;stable@vger.kernel.org&gt; # 3.12+
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq: Clean up after a failing light-weight initialization</title>
<updated>2013-12-29T14:30:36Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2013-12-27T00:07:11Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=72368d122c7479aa6e14fbbd334717b8a0c157a6'/>
<id>urn:sha1:72368d122c7479aa6e14fbbd334717b8a0c157a6</id>
<content type='text'>
If cpufreq_policy_restore() returns NULL during system resume,
__cpufreq_add_dev() should just fall back to the full initialization
instead of returning an error, because that may actually make things
work.  Moreover, it should not leave stale fallback data behind after
it has failed to restore a previously existing policy.

This change is based on Viresh Kumar's work.

Fixes: 5302c3fb2e62 ("cpufreq: Perform light-weight init/teardown during suspend/resume")
Reported-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
Acked-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Cc: 3.12+ &lt;stable@vger.kernel.org&gt; # 3.12+
</content>
</entry>
<entry>
<title>cpufreq: Use CONFIG_CPU_FREQ_DEFAULT_* to set initial policy for setpolicy drivers</title>
<updated>2013-12-21T23:51:52Z</updated>
<author>
<name>Jason Baron</name>
<email>jbaron@akamai.com</email>
</author>
<published>2013-12-19T22:50:50Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=a27a9ab706c8f5bb8bbd320d2e9c5d089e380c6a'/>
<id>urn:sha1:a27a9ab706c8f5bb8bbd320d2e9c5d089e380c6a</id>
<content type='text'>
When configuring a default governor (via CONFIG_CPU_FREQ_DEFAULT_*) with the
intel_pstate driver, the desired default policy is not properly set. For
example, setting 'CONFIG_CPU_FREQ_DEFAULT_GOV_PERFORMANCE' ends up with the
'powersave' policy being set.

Fix by configuring the correct default policy, if either 'powersave' or
'performance' are requested. Otherwise, fallback to what the driver originally
set via its 'init' routine.

Signed-off-by: Jason Baron &lt;jbaron@akamai.com&gt;
Acked-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: remove sysfs files for CPUs which failed to come back after resume</title>
<updated>2013-12-21T23:47:46Z</updated>
<author>
<name>Viresh Kumar</name>
<email>viresh.kumar@linaro.org</email>
</author>
<published>2013-12-20T15:56:02Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=42f921a6f10c6c2079b093a115eb7e3c3508357f'/>
<id>urn:sha1:42f921a6f10c6c2079b093a115eb7e3c3508357f</id>
<content type='text'>
There are cases where cpufreq_add_dev() may fail for some CPUs
during system resume. With the current code we will still have
sysfs cpufreq files for those CPUs and struct cpufreq_policy
would be already freed for them. Hence any operation on those
sysfs files would result in kernel warnings.

Example of problems resulting from resume errors (from Bjørn Mork):

WARNING: CPU: 0 PID: 6055 at fs/sysfs/file.c:343 sysfs_open_file+0x77/0x212()
missing sysfs attribute operations for kobject: (null)
Modules linked in: [stripped as irrelevant]
CPU: 0 PID: 6055 Comm: grep Tainted: G      D      3.13.0-rc2 #153
Hardware name: LENOVO 2776LEG/2776LEG, BIOS 6EET55WW (3.15 ) 12/19/2011
 0000000000000009 ffff8802327ebb78 ffffffff81380b0e 0000000000000006
 ffff8802327ebbc8 ffff8802327ebbb8 ffffffff81038635 0000000000000000
 ffffffff811823c7 ffff88021a19e688 ffff88021a19e688 ffff8802302f9310
Call Trace:
 [&lt;ffffffff81380b0e&gt;] dump_stack+0x55/0x76
 [&lt;ffffffff81038635&gt;] warn_slowpath_common+0x7c/0x96
 [&lt;ffffffff811823c7&gt;] ? sysfs_open_file+0x77/0x212
 [&lt;ffffffff810386e3&gt;] warn_slowpath_fmt+0x41/0x43
 [&lt;ffffffff81182dec&gt;] ? sysfs_get_active+0x6b/0x82
 [&lt;ffffffff81182382&gt;] ? sysfs_open_file+0x32/0x212
 [&lt;ffffffff811823c7&gt;] sysfs_open_file+0x77/0x212
 [&lt;ffffffff81182350&gt;] ? sysfs_schedule_callback+0x1ac/0x1ac
 [&lt;ffffffff81122562&gt;] do_dentry_open+0x17c/0x257
 [&lt;ffffffff8112267e&gt;] finish_open+0x41/0x4f
 [&lt;ffffffff81130225&gt;] do_last+0x80c/0x9ba
 [&lt;ffffffff8112dbbd&gt;] ? inode_permission+0x40/0x42
 [&lt;ffffffff81130606&gt;] path_openat+0x233/0x4a1
 [&lt;ffffffff81130b7e&gt;] do_filp_open+0x35/0x85
 [&lt;ffffffff8113b787&gt;] ? __alloc_fd+0x172/0x184
 [&lt;ffffffff811232ea&gt;] do_sys_open+0x6b/0xfa
 [&lt;ffffffff811233a7&gt;] SyS_openat+0xf/0x11
 [&lt;ffffffff8138c812&gt;] system_call_fastpath+0x16/0x1b

To fix this, remove those sysfs files or put the associated kobject
in case of such errors. Also, to make it simple, remove the cpufreq
sysfs links from all the CPUs (except for the policy-&gt;cpu) during
suspend, as that operation won't result in a loss of sysfs file
permissions and we can create those links during resume just fine.

Fixes: 5302c3fb2e62 ("cpufreq: Perform light-weight init/teardown during suspend/resume")
Reported-and-tested-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Signed-off-by: Viresh Kumar &lt;viresh.kumar@linaro.org&gt;
Cc: 3.12+ &lt;stable@vger.kernel.org&gt; # 3.12+
[rjw: Changelog]
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>cpufreq_ at32ap-cpufreq.c: Fix section mismatch</title>
<updated>2013-12-10T07:46:38Z</updated>
<author>
<name>Matthias Brugger</name>
<email>matthias.bgg@gmail.com</email>
</author>
<published>2013-12-05T09:59:57Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=fa1513f60a370a38512ccad4da11548f236768c4'/>
<id>urn:sha1:fa1513f60a370a38512ccad4da11548f236768c4</id>
<content type='text'>
The function at32_cpufreq_driver_init was marked as __init but will be
called from inside the cpufreq framework. This lead to the following a
section mismatch during compilation:

WARNING: drivers/built-in.o(.data+0x2448): Section mismatch in reference
from the variable at32_driver to the function
.init.text:at32_cpufreq_driver_init()
The variable at32_driver references
the function __init at32_cpufreq_driver_init()
If the reference is valid then annotate the
variable with __init* or __refdata (see linux/init.h) or name the
variable:
*_template, *_timer, *_sht, *_ops, *_probe, *_probe_one, *_console

Signed-off-by: Matthias Brugger &lt;matthias.bgg@gmail.com&gt;
</content>
</entry>
<entry>
<title>Revert "cpufreq: fix garbage kobjects on errors during suspend/resume"</title>
<updated>2013-12-08T00:32:41Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2013-12-08T00:23:58Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=d4faadd5d5b368a7051fef374ee933ec3606713b'/>
<id>urn:sha1:d4faadd5d5b368a7051fef374ee933ec3606713b</id>
<content type='text'>
Commit 2167e2399dc5 (cpufreq: fix garbage kobjects on errors during
suspend/resume) breaks suspend/resume on Martin Ziegler's system
(hard lockup during resume), so revert it.

Fixes: 2167e2399dc5 (cpufreq: fix garbage kobjects on errors during suspend/resume)
References: https://bugzilla.kernel.org/show_bug.cgi?id=66751
Reported-by: Martin Ziegler &lt;ziegler@uni-freiburg.de&gt;
Cc: 3.12+ &lt;stable@vger.kernel.org&gt; # 3.12+
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>Revert "cpufreq: suspend governors on system suspend/hibernate"</title>
<updated>2013-12-08T00:04:17Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2013-12-08T00:04:17Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=12205a4b79bef56ef618a4b7caa840c5c971cff2'/>
<id>urn:sha1:12205a4b79bef56ef618a4b7caa840c5c971cff2</id>
<content type='text'>
Commit 5a87182aa21d (cpufreq: suspend governors on system
suspend/hibernate) causes hibernation problems to happen on
Bjørn Mork's and Paul Bolle's systems, so revert it.

Fixes: 5a87182aa21d (cpufreq: suspend governors on system suspend/hibernate)
Reported-by: Bjørn Mork &lt;bjorn@mork.no&gt;
Reported-by: Paul Bolle &lt;pebolle@tiscali.nl&gt;
Signed-off-by: Rafael J. Wysocki &lt;rafael.j.wysocki@intel.com&gt;
</content>
</entry>
<entry>
<title>Merge branches 'pm-cpuidle' and 'pm-cpufreq'</title>
<updated>2013-12-06T01:17:59Z</updated>
<author>
<name>Rafael J. Wysocki</name>
<email>rafael.j.wysocki@intel.com</email>
</author>
<published>2013-12-06T01:17:59Z</published>
<link rel='alternate' type='text/html' href='https://git.shady.money/linux/commit/?id=7cdcec991c06cd6d792b304851cc245cfec507a7'/>
<id>urn:sha1:7cdcec991c06cd6d792b304851cc245cfec507a7</id>
<content type='text'>
* pm-cpuidle:
  cpuidle: Check for dev before deregistering it.
  intel_idle: Fixed C6 state on Avoton/Rangeley processors

* pm-cpufreq:
  cpufreq: fix garbage kobjects on errors during suspend/resume
  cpufreq: suspend governors on system suspend/hibernate
</content>
</entry>
</feed>
