Skip to content

Commit 09da8df

Browse files
committed
Merge tag 'pm+acpi-3.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull ACPI and power management updates from Rafael Wysocki: "As far as the number of commits goes, the top spot belongs to ACPI this time with cpufreq in the second position and a handful of PM core, PNP and cpuidle updates. They are fixes and cleanups mostly, as usual, with a couple of new features in the mix. The most visible change is probably that we will create struct acpi_device objects (visible in sysfs) for all devices represented in the ACPI tables regardless of their status and there will be a new sysfs attribute under those objects allowing user space to check that status via _STA. Consequently, ACPI device eject or generally hot-removal will not delete those objects, unless the table containing the corresponding namespace nodes is unloaded, which is extremely rare. Also ACPI container hotplug will be handled quite a bit differently and cpufreq will support CPU boost ("turbo") generically and not only in the acpi-cpufreq driver. Specifics: - ACPI core changes to make it create a struct acpi_device object for every device represented in the ACPI tables during all namespace scans regardless of the current status of that device. In accordance with this, ACPI hotplug operations will not delete those objects, unless the underlying ACPI tables go away. - On top of the above, new sysfs attribute for ACPI device objects allowing user space to check device status by triggering the execution of _STA for its ACPI object. From Srinivas Pandruvada. - ACPI core hotplug changes reducing code duplication, integrating the PCI root hotplug with the core and reworking container hotplug. - ACPI core simplifications making it use ACPI_COMPANION() in the code "glueing" ACPI device objects to "physical" devices. - ACPICA update to upstream version 20131218. This adds support for the DBG2 and PCCT tables to ACPICA, fixes some bugs and improves debug facilities. From Bob Moore, Lv Zheng and Betty Dall. - Init code change to carry out the early ACPI initialization earlier. That should allow us to use ACPI during the timekeeping initialization and possibly to simplify the EFI initialization too. From Chun-Yi Lee. - Clenups of the inclusions of ACPI headers in many places all over from Lv Zheng and Rashika Kheria (work in progress). - New helper for ACPI _DSM execution and rework of the code in drivers that uses _DSM to execute it via the new helper. From Jiang Liu. - New Win8 OSI blacklist entries from Takashi Iwai. - Assorted ACPI fixes and cleanups from Al Stone, Emil Goode, Hanjun Guo, Lan Tianyu, Masanari Iida, Oliver Neukum, Prarit Bhargava, Rashika Kheria, Tang Chen, Zhang Rui. - intel_pstate driver updates, including proper Baytrail support, from Dirk Brandewie and intel_pstate documentation from Ramkumar Ramachandra. - Generic CPU boost ("turbo") support for cpufreq from Lukasz Majewski. - powernow-k6 cpufreq driver fixes from Mikulas Patocka. - cpufreq core fixes and cleanups from Viresh Kumar, Jane Li, Mark Brown. - Assorted cpufreq drivers fixes and cleanups from Anson Huang, John Tobias, Paul Bolle, Paul Walmsley, Sachin Kamat, Shawn Guo, Viresh Kumar. - cpuidle cleanups from Bartlomiej Zolnierkiewicz. - Support for hibernation APM events from Bin Shi. - Hibernation fix to avoid bringing up nonboot CPUs with ACPI EC disabled during thaw transitions from Bjørn Mork. - PM core fixes and cleanups from Ben Dooks, Leonardo Potenza, Ulf Hansson. - PNP subsystem fixes and cleanups from Dmitry Torokhov, Levente Kurusa, Rashika Kheria. - New tool for profiling system suspend from Todd E Brandt and a cpupower tool cleanup from One Thousand Gnomes" * tag 'pm+acpi-3.14-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (153 commits) thermal: exynos: boost: Automatic enable/disable of BOOST feature (at Exynos4412) cpufreq: exynos4x12: Change L0 driver data to CPUFREQ_BOOST_FREQ Documentation: cpufreq / boost: Update BOOST documentation cpufreq: exynos: Extend Exynos cpufreq driver to support boost cpufreq / boost: Kconfig: Support for software-managed BOOST acpi-cpufreq: Adjust the code to use the common boost attribute cpufreq: Add boost frequency support in core intel_pstate: Add trace point to report internal state. cpufreq: introduce cpufreq_generic_get() routine ARM: SA1100: Create dummy clk_get_rate() to avoid build failures cpufreq: stats: create sysfs entries when cpufreq_stats is a module cpufreq: stats: free table and remove sysfs entry in a single routine cpufreq: stats: remove hotplug notifiers cpufreq: stats: handle cpufreq_unregister_driver() and suspend/resume properly cpufreq: speedstep: remove unused speedstep_get_state platform: introduce OF style 'modalias' support for platform bus PM / tools: new tool for suspend/resume performance optimization ACPI: fix module autoloading for ACPI enumerated devices ACPI: add module autoloading support for ACPI enumerated devices ACPI: fix create_modalias() return value handling ...
2 parents 3aacd62 + 7744064 commit 09da8df

242 files changed

Lines changed: 4649 additions & 2749 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

‎Documentation/ABI/testing/sysfs-devices-system-cpu‎

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -200,3 +200,27 @@ Description: address and size of the percpu note.
200200
note of cpu#.
201201

202202
crash_notes_size: size of the note of cpu#.
203+
204+
205+
What: /sys/devices/system/cpu/intel_pstate/max_perf_pct
206+
/sys/devices/system/cpu/intel_pstate/min_perf_pct
207+
/sys/devices/system/cpu/intel_pstate/no_turbo
208+
Date: February 2013
209+
Contact: linux-pm@vger.kernel.org
210+
Description: Parameters for the Intel P-state driver
211+
212+
Logic for selecting the current P-state in Intel
213+
Sandybridge+ processors. The three knobs control
214+
limits for the P-state that will be requested by the
215+
driver.
216+
217+
max_perf_pct: limits the maximum P state that will be requested by
218+
the driver stated as a percentage of the available performance.
219+
220+
min_perf_pct: limits the minimum P state that will be requested by
221+
the driver stated as a percentage of the available performance.
222+
223+
no_turbo: limits the driver to selecting P states below the turbo
224+
frequency range.
225+
226+
More details can be found in Documentation/cpu-freq/intel-pstate.txt

‎Documentation/acpi/namespace.txt‎

Lines changed: 1 addition & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -235,10 +235,6 @@ Wysocki <rafael.j.wysocki@intel.com>.
235235
named object's type in the second column). In that case the object's
236236
directory in sysfs will contain the 'path' attribute whose value is
237237
the full path to the node from the namespace root.
238-
struct acpi_device objects are created for the ACPI namespace nodes
239-
whose _STA control methods return PRESENT or FUNCTIONING. The power
240-
resource nodes or nodes without _STA are assumed to be both PRESENT
241-
and FUNCTIONING.
242238
F:
243239
The struct acpi_device object is created for a fixed hardware
244240
feature (as indicated by the fixed feature flag's name in the second
@@ -340,7 +336,7 @@ Wysocki <rafael.j.wysocki@intel.com>.
340336
| +-------------+-------+----------------+
341337
| |
342338
| | +- - - - - - - +- - - - - - +- - - - - - - -+
343-
| +-| * PNP0C0D:00 | \_SB_.LID0 | acpi:PNP0C0D: |
339+
| +-| PNP0C0D:00 | \_SB_.LID0 | acpi:PNP0C0D: |
344340
| | +- - - - - - - +- - - - - - +- - - - - - - -+
345341
| |
346342
| | +------------+------------+-----------------------+
@@ -390,6 +386,3 @@ Wysocki <rafael.j.wysocki@intel.com>.
390386
attribute (as described earlier in this document).
391387
NOTE: N/A indicates the device object does not have the 'path' or the
392388
'modalias' attribute.
393-
NOTE: The PNP0C0D device listed above is highlighted (marked by "*")
394-
to indicate it will be created only when its _STA methods return
395-
PRESENT or FUNCTIONING.

‎Documentation/cpu-freq/boost.txt‎

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ Introduction
1717
Some CPUs support a functionality to raise the operating frequency of
1818
some cores in a multi-core package if certain conditions apply, mostly
1919
if the whole chip is not fully utilized and below it's intended thermal
20-
budget. This is done without operating system control by a combination
21-
of hardware and firmware.
20+
budget. The decision about boost disable/enable is made either at hardware
21+
(e.g. x86) or software (e.g ARM).
2222
On Intel CPUs this is called "Turbo Boost", AMD calls it "Turbo-Core",
2323
in technical documentation "Core performance boost". In Linux we use
2424
the term "boost" for convenience.
@@ -48,24 +48,24 @@ be desirable:
4848
User controlled switch
4949
----------------------
5050

51-
To allow the user to toggle the boosting functionality, the acpi-cpufreq
52-
driver exports a sysfs knob to disable it. There is a file:
51+
To allow the user to toggle the boosting functionality, the cpufreq core
52+
driver exports a sysfs knob to enable or disable it. There is a file:
5353
/sys/devices/system/cpu/cpufreq/boost
5454
which can either read "0" (boosting disabled) or "1" (boosting enabled).
55-
Reading the file is always supported, even if the processor does not
56-
support boosting. In this case the file will be read-only and always
57-
reads as "0". Explicitly changing the permissions and writing to that
58-
file anyway will return EINVAL.
55+
The file is exported only when cpufreq driver supports boosting.
56+
Explicitly changing the permissions and writing to that file anyway will
57+
return EINVAL.
5958

6059
On supported CPUs one can write either a "0" or a "1" into this file.
6160
This will either disable the boost functionality on all cores in the
62-
whole system (0) or will allow the hardware to boost at will (1).
61+
whole system (0) or will allow the software or hardware to boost at will
62+
(1).
6363

6464
Writing a "1" does not explicitly boost the system, but just allows the
65-
CPU (and the firmware) to boost at their discretion. Some implementations
66-
take external factors like the chip's temperature into account, so
67-
boosting once does not necessarily mean that it will occur every time
68-
even using the exact same software setup.
65+
CPU to boost at their discretion. Some implementations take external
66+
factors like the chip's temperature into account, so boosting once does
67+
not necessarily mean that it will occur every time even using the exact
68+
same software setup.
6969

7070

7171
AMD legacy cpb switch
Lines changed: 40 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,40 @@
1+
Intel P-state driver
2+
--------------------
3+
4+
This driver implements a scaling driver with an internal governor for
5+
Intel Core processors. The driver follows the same model as the
6+
Transmeta scaling driver (longrun.c) and implements the setpolicy()
7+
instead of target(). Scaling drivers that implement setpolicy() are
8+
assumed to implement internal governors by the cpufreq core. All the
9+
logic for selecting the current P state is contained within the
10+
driver; no external governor is used by the cpufreq core.
11+
12+
Intel SandyBridge+ processors are supported.
13+
14+
New sysfs files for controlling P state selection have been added to
15+
/sys/devices/system/cpu/intel_pstate/
16+
17+
max_perf_pct: limits the maximum P state that will be requested by
18+
the driver stated as a percentage of the available performance.
19+
20+
min_perf_pct: limits the minimum P state that will be requested by
21+
the driver stated as a percentage of the available performance.
22+
23+
no_turbo: limits the driver to selecting P states below the turbo
24+
frequency range.
25+
26+
For contemporary Intel processors, the frequency is controlled by the
27+
processor itself and the P-states exposed to software are related to
28+
performance levels. The idea that frequency can be set to a single
29+
frequency is fiction for Intel Core processors. Even if the scaling
30+
driver selects a single P state the actual frequency the processor
31+
will run at is selected by the processor itself.
32+
33+
New debugfs files have also been added to /sys/kernel/debug/pstate_snb/
34+
35+
deadband
36+
d_gain_pct
37+
i_gain_pct
38+
p_gain_pct
39+
sample_rate_ms
40+
setpoint

‎Documentation/kernel-parameters.txt‎

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -343,6 +343,9 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
343343
no: ACPI OperationRegions are not marked as reserved,
344344
no further checks are performed.
345345

346+
acpi_no_memhotplug [ACPI] Disable memory hotplug. Useful for kdump
347+
kernels.
348+
346349
add_efi_memmap [EFI; X86] Include EFI memory map in
347350
kernel's map of available physical RAM.
348351

‎MAINTAINERS‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -257,6 +257,7 @@ F: Documentation/ABI/testing/sysfs-bus-acpi
257257
F: drivers/pci/*acpi*
258258
F: drivers/pci/*/*acpi*
259259
F: drivers/pci/*/*/*acpi*
260+
F: tools/power/acpi
260261

261262
ACPI COMPONENT ARCHITECTURE (ACPICA)
262263
M: Robert Moore <robert.moore@intel.com>
@@ -271,6 +272,7 @@ T: git git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
271272
S: Supported
272273
F: drivers/acpi/acpica/
273274
F: include/acpi/
275+
F: tools/power/acpi/
274276

275277
ACPI FAN DRIVER
276278
M: Zhang Rui <rui.zhang@intel.com>

‎arch/arm/mach-exynos/common.c‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -303,6 +303,11 @@ void __init exynos_cpuidle_init(void)
303303
platform_device_register(&exynos_cpuidle);
304304
}
305305

306+
void __init exynos_cpufreq_init(void)
307+
{
308+
platform_device_register_simple("exynos-cpufreq", -1, NULL, 0);
309+
}
310+
306311
void __init exynos_init_late(void)
307312
{
308313
if (of_machine_is_compatible("samsung,exynos5440"))

‎arch/arm/mach-exynos/common.h‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@ void exynos_init_io(void);
2222
void exynos4_restart(enum reboot_mode mode, const char *cmd);
2323
void exynos5_restart(enum reboot_mode mode, const char *cmd);
2424
void exynos_cpuidle_init(void);
25+
void exynos_cpufreq_init(void);
2526
void exynos_init_late(void);
2627

2728
void exynos_firmware_init(void);

‎arch/arm/mach-exynos/cpuidle.c‎

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -172,8 +172,8 @@ static int exynos4_enter_lowpower(struct cpuidle_device *dev,
172172
{
173173
int new_index = index;
174174

175-
/* This mode only can be entered when other core's are offline */
176-
if (num_online_cpus() > 1)
175+
/* AFTR can only be entered when cores other than CPU0 are offline */
176+
if (num_online_cpus() > 1 || dev->cpu != 0)
177177
new_index = drv->safe_state_index;
178178

179179
if (new_index == 0)
@@ -235,10 +235,6 @@ static int exynos_cpuidle_probe(struct platform_device *pdev)
235235
device = &per_cpu(exynos4_cpuidle_device, cpu_id);
236236
device->cpu = cpu_id;
237237

238-
/* Support IDLE only */
239-
if (cpu_id != 0)
240-
device->state_count = 1;
241-
242238
ret = cpuidle_register_device(device);
243239
if (ret) {
244240
dev_err(&pdev->dev, "failed to register cpuidle device\n");

‎arch/arm/mach-exynos/mach-exynos4-dt.c‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,7 @@
2222
static void __init exynos4_dt_machine_init(void)
2323
{
2424
exynos_cpuidle_init();
25+
exynos_cpufreq_init();
2526

2627
of_platform_populate(NULL, of_default_bus_match_table, NULL, NULL);
2728
}

0 commit comments

Comments
 (0)