aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2013-07-03 17:35:40 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2013-07-03 17:35:40 -0400
commitf991fae5c6d42dfc5029150b05a78cf3f6c18cc9 (patch)
treed140deb437bde0631778b4984eeb72c1f4ee0c1d /Documentation
parentd4141531f63a29bb2a980092b6f2828c385e6edd (diff)
parent2c843bd92ec276ecb68504b3b5ffa7066183f032 (diff)
Merge tag 'pm+acpi-3.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm
Pull power management and ACPI updates from Rafael Wysocki: "This time the total number of ACPI commits is slightly greater than the number of cpufreq commits, but Viresh Kumar (who works on cpufreq) remains the most active patch submitter. To me, the most significant change is the addition of offline/online device operations to the driver core (with the Greg's blessing) and the related modifications of the ACPI core hotplug code. Next are the freezer updates from Colin Cross that should make the freezing of tasks a bit less heavy weight. We also have a couple of regression fixes, a number of fixes for issues that have not been identified as regressions, two new drivers and a bunch of cleanups all over. Highlights: - Hotplug changes to support graceful hot-removal failures. It sometimes is necessary to fail device hot-removal operations gracefully if they cannot be carried out completely. For example, if memory from a memory module being hot-removed has been allocated for the kernel's own use and cannot be moved elsewhere, it's desirable to fail the hot-removal operation in a graceful way rather than to crash the kernel, but currenty a success or a kernel crash are the only possible outcomes of an attempted memory hot-removal. Needless to say, that is not a very attractive alternative and it had to be addressed. However, in order to make it work for memory, I first had to make it work for CPUs and for this purpose I needed to modify the ACPI processor driver. It's been split into two parts, a resident one handling the low-level initialization/cleanup and a modular one playing the actual driver's role (but it binds to the CPU system device objects rather than to the ACPI device objects representing processors). That's been sort of like a live brain surgery on a patient who's riding a bike. So this is a little scary, but since we found and fixed a couple of regressions it caused to happen during the early linux-next testing (a month ago), nobody has complained. As a bonus we remove some duplicated ACPI hotplug code, because the ACPI-based CPU hotplug is now going to use the common ACPI hotplug code. - Lighter weight freezing of tasks. These changes from Colin Cross and Mandeep Singh Baines are targeted at making the freezing of tasks a bit less heavy weight operation. They reduce the number of tasks woken up every time during the freezing, by using the observation that the freezer simply doesn't need to wake up some of them and wait for them all to call refrigerator(). The time needed for the freezer to decide to report a failure is reduced too. Also reintroduced is the check causing a lockdep warining to trigger when try_to_freeze() is called with locks held (which is generally unsafe and shouldn't happen). - cpufreq updates First off, a commit from Srivatsa S Bhat fixes a resume regression introduced during the 3.10 cycle causing some cpufreq sysfs attributes to return wrong values to user space after resume. The fix is kind of fresh, but also it's pretty obvious once Srivatsa has identified the root cause. Second, we have a new freqdomain_cpus sysfs attribute for the acpi-cpufreq driver to provide information previously available via related_cpus. From Lan Tianyu. Finally, we fix a number of issues, mostly related to the CPUFREQ_POSTCHANGE notifier and cpufreq Kconfig options and clean up some code. The majority of changes from Viresh Kumar with bits from Jacob Shin, Heiko Stübner, Xiaoguang Chen, Ezequiel Garcia, Arnd Bergmann, and Tang Yuantian. - ACPICA update A usual bunch of updates from the ACPICA upstream. During the 3.4 cycle we introduced support for ACPI 5 extended sleep registers, but they are only supposed to be used if the HW-reduced mode bit is set in the FADT flags and the code attempted to use them without checking that bit. That caused suspend/resume regressions to happen on some systems. Fix from Lv Zheng causes those registers to be used only if the HW-reduced mode bit is set. Apart from this some other ACPICA bugs are fixed and code cleanups are made by Bob Moore, Tomasz Nowicki, Lv Zheng, Chao Guan, and Zhang Rui. - cpuidle updates New driver for Xilinx Zynq processors is added by Michal Simek. Multidriver support simplification, addition of some missing kerneldoc comments and Kconfig-related fixes come from Daniel Lezcano. - ACPI power management updates Changes to make suspend/resume work correctly in Xen guests from Konrad Rzeszutek Wilk, sparse warning fix from Fengguang Wu and cleanups and fixes of the ACPI device power state selection routine. - ACPI documentation updates Some previously missing pieces of ACPI documentation are added by Lv Zheng and Aaron Lu (hopefully, that will help people to uderstand how the ACPI subsystem works) and one outdated doc is updated by Hanjun Guo. - Assorted ACPI updates We finally nailed down the IA-64 issue that was the reason for reverting commit 9f29ab11ddbf ("ACPI / scan: do not match drivers against objects having scan handlers"), so we can fix it and move the ACPI scan handler check added to the ACPI video driver back to the core. A mechanism for adding CMOS RTC address space handlers is introduced by Lan Tianyu to allow some EC-related breakage to be fixed on some systems. A spec-compliant implementation of acpi_os_get_timer() is added by Mika Westerberg. The evaluation of _STA is added to do_acpi_find_child() to avoid situations in which a pointer to a disabled device object is returned instead of an enabled one with the same _ADR value. From Jeff Wu. Intel BayTrail PCH (Platform Controller Hub) support is added to the ACPI driver for Intel Low-Power Subsystems (LPSS) and that driver is modified to work around a couple of known BIOS issues. Changes from Mika Westerberg and Heikki Krogerus. The EC driver is fixed by Vasiliy Kulikov to use get_user() and put_user() instead of dereferencing user space pointers blindly. Code cleanups are made by Bjorn Helgaas, Nicholas Mazzuca and Toshi Kani. - Assorted power management updates The "runtime idle" helper routine is changed to take the return values of the callbacks executed by it into account and to call rpm_suspend() if they return 0, which allows us to reduce the overall code bloat a bit (by dropping some code that's not necessary any more after that modification). The runtime PM documentation is updated by Alan Stern (to reflect the "runtime idle" behavior change). New trace points for PM QoS are added by Sahara (<keun-o.park@windriver.com>). PM QoS documentation is updated by Lan Tianyu. Code cleanups are made and minor issues are addressed by Bernie Thompson, Bjorn Helgaas, Julius Werner, and Shuah Khan. - devfreq updates New driver for the Exynos5-bus device from Abhilash Kesavan. Minor cleanups, fixes and MAINTAINERS update from MyungJoo Ham, Abhilash Kesavan, Paul Bolle, Rajagopal Venkat, and Wei Yongjun. - OMAP power management updates Adaptive Voltage Scaling (AVS) SmartReflex voltage control driver updates from Andrii Tseglytskyi and Nishanth Menon." * tag 'pm+acpi-3.11-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/linux-pm: (162 commits) cpufreq: Fix cpufreq regression after suspend/resume ACPI / PM: Fix possible NULL pointer deref in acpi_pm_device_sleep_state() PM / Sleep: Warn about system time after resume with pm_trace cpufreq: don't leave stale policy pointer in cdbs->cur_policy acpi-cpufreq: Add new sysfs attribute freqdomain_cpus cpufreq: make sure frequency transitions are serialized ACPI: implement acpi_os_get_timer() according the spec ACPI / EC: Add HP Folio 13 to ec_dmi_table in order to skip DSDT scan ACPI: Add CMOS RTC Operation Region handler support ACPI / processor: Drop unused variable from processor_perflib.c cpufreq: tegra: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: s3c64xx: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: omap: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: imx6q: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: exynos: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: dbx500: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: davinci: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: arm-big-little: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: powernow-k8: call CPUFREQ_POSTCHANGE notfier in error cases cpufreq: pcc: call CPUFREQ_POSTCHANGE notfier in error cases ...
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/ABI/testing/sysfs-bus-acpi58
-rw-r--r--Documentation/ABI/testing/sysfs-class-devfreq20
-rw-r--r--Documentation/ABI/testing/sysfs-devices-online20
-rw-r--r--Documentation/ABI/testing/sysfs-devices-sun2
-rw-r--r--Documentation/ABI/testing/sysfs-devices-system-cpu15
-rw-r--r--Documentation/ABI/testing/sysfs-firmware-acpi10
-rw-r--r--Documentation/acpi/namespace.txt395
-rw-r--r--Documentation/acpi/video_extension.txt106
-rw-r--r--Documentation/cpu-freq/cpu-drivers.txt10
-rw-r--r--Documentation/cpu-hotplug.txt6
-rw-r--r--Documentation/kernel-parameters.txt9
-rw-r--r--Documentation/power/pm_qos_interface.txt50
-rw-r--r--Documentation/power/runtime_pm.txt20
-rw-r--r--Documentation/power/video_extension.txt37
-rw-r--r--Documentation/trace/events-power.txt31
15 files changed, 724 insertions, 65 deletions
diff --git a/Documentation/ABI/testing/sysfs-bus-acpi b/Documentation/ABI/testing/sysfs-bus-acpi
new file mode 100644
index 000000000000..7fa9cbc75344
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-bus-acpi
@@ -0,0 +1,58 @@
1What: /sys/bus/acpi/devices/.../path
2Date: December 2006
3Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
4Description:
5 This attribute indicates the full path of ACPI namespace
6 object associated with the device object. For example,
7 \_SB_.PCI0.
8 This file is not present for device objects representing
9 fixed ACPI hardware features (like power and sleep
10 buttons).
11
12What: /sys/bus/acpi/devices/.../modalias
13Date: July 2007
14Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
15Description:
16 This attribute indicates the PNP IDs of the device object.
17 That is acpi:HHHHHHHH:[CCCCCCC:]. Where each HHHHHHHH or
18 CCCCCCCC contains device object's PNPID (_HID or _CID).
19
20What: /sys/bus/acpi/devices/.../hid
21Date: April 2005
22Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
23Description:
24 This attribute indicates the hardware ID (_HID) of the
25 device object. For example, PNP0103.
26 This file is present for device objects having the _HID
27 control method.
28
29What: /sys/bus/acpi/devices/.../description
30Date: October 2012
31Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
32Description:
33 This attribute contains the output of the device object's
34 _STR control method, if present.
35
36What: /sys/bus/acpi/devices/.../adr
37Date: October 2012
38Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
39Description:
40 This attribute contains the output of the device object's
41 _ADR control method, which is present for ACPI device
42 objects representing devices having standard enumeration
43 algorithms, such as PCI.
44
45What: /sys/bus/acpi/devices/.../uid
46Date: October 2012
47Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
48Description:
49 This attribute contains the output of the device object's
50 _UID control method, if present.
51
52What: /sys/bus/acpi/devices/.../eject
53Date: December 2006
54Contact: Rafael J. Wysocki <rjw@rjwysocki.net>
55Description:
56 Writing 1 to this attribute will trigger hot removal of
57 this device object. This file exists for every device
58 object that has _EJ0 method.
diff --git a/Documentation/ABI/testing/sysfs-class-devfreq b/Documentation/ABI/testing/sysfs-class-devfreq
index 0ba6ea2f89d9..ee39acacf6f8 100644
--- a/Documentation/ABI/testing/sysfs-class-devfreq
+++ b/Documentation/ABI/testing/sysfs-class-devfreq
@@ -78,3 +78,23 @@ Contact: Nishanth Menon <nm@ti.com>
78Description: 78Description:
79 The /sys/class/devfreq/.../available_governors shows 79 The /sys/class/devfreq/.../available_governors shows
80 currently available governors in the system. 80 currently available governors in the system.
81
82What: /sys/class/devfreq/.../min_freq
83Date: January 2013
84Contact: MyungJoo Ham <myungjoo.ham@samsung.com>
85Description:
86 The /sys/class/devfreq/.../min_freq shows and stores
87 the minimum frequency requested by users. It is 0 if
88 the user does not care. min_freq overrides the
89 frequency requested by governors.
90
91What: /sys/class/devfreq/.../max_freq
92Date: January 2013
93Contact: MyungJoo Ham <myungjoo.ham@samsung.com>
94Description:
95 The /sys/class/devfreq/.../max_freq shows and stores
96 the maximum frequency requested by users. It is 0 if
97 the user does not care. max_freq overrides the
98 frequency requested by governors and min_freq.
99 The max_freq overrides min_freq because max_freq may be
100 used to throttle devices to avoid overheating.
diff --git a/Documentation/ABI/testing/sysfs-devices-online b/Documentation/ABI/testing/sysfs-devices-online
new file mode 100644
index 000000000000..f990026c0740
--- /dev/null
+++ b/Documentation/ABI/testing/sysfs-devices-online
@@ -0,0 +1,20 @@
1What: /sys/devices/.../online
2Date: April 2013
3Contact: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
4Description:
5 The /sys/devices/.../online attribute is only present for
6 devices whose bus types provide .online() and .offline()
7 callbacks. The number read from it (0 or 1) reflects the value
8 of the device's 'offline' field. If that number is 1 and '0'
9 (or 'n', or 'N') is written to this file, the device bus type's
10 .offline() callback is executed for the device and (if
11 successful) its 'offline' field is updated accordingly. In
12 turn, if that number is 0 and '1' (or 'y', or 'Y') is written to
13 this file, the device bus type's .online() callback is executed
14 for the device and (if successful) its 'offline' field is
15 updated as appropriate.
16
17 After a successful execution of the bus type's .offline()
18 callback the device cannot be used for any purpose until either
19 it is removed (i.e. device_del() is called for it), or its bus
20 type's .online() is exeucted successfully.
diff --git a/Documentation/ABI/testing/sysfs-devices-sun b/Documentation/ABI/testing/sysfs-devices-sun
index 86be9848a77e..625ce4b63758 100644
--- a/Documentation/ABI/testing/sysfs-devices-sun
+++ b/Documentation/ABI/testing/sysfs-devices-sun
@@ -1,4 +1,4 @@
1Whatt: /sys/devices/.../sun 1What: /sys/devices/.../sun
2Date: October 2012 2Date: October 2012
3Contact: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com> 3Contact: Yasuaki Ishimatsu <isimatu.yasuaki@jp.fujitsu.com>
4Description: 4Description:
diff --git a/Documentation/ABI/testing/sysfs-devices-system-cpu b/Documentation/ABI/testing/sysfs-devices-system-cpu
index 2447698aed41..468e4d48f884 100644
--- a/Documentation/ABI/testing/sysfs-devices-system-cpu
+++ b/Documentation/ABI/testing/sysfs-devices-system-cpu
@@ -144,6 +144,21 @@ Description: Discover and change clock speed of CPUs
144 to learn how to control the knobs. 144 to learn how to control the knobs.
145 145
146 146
147What: /sys/devices/system/cpu/cpu#/cpufreq/freqdomain_cpus
148Date: June 2013
149Contact: cpufreq@vger.kernel.org
150Description: Discover CPUs in the same CPU frequency coordination domain
151
152 freqdomain_cpus is the list of CPUs (online+offline) that share
153 the same clock/freq domain (possibly at the hardware level).
154 That information may be hidden from the cpufreq core and the
155 value of related_cpus may be different from freqdomain_cpus. This
156 attribute is useful for user space DVFS controllers to get better
157 power/performance results for platforms using acpi-cpufreq.
158
159 This file is only present if the acpi-cpufreq driver is in use.
160
161
147What: /sys/devices/system/cpu/cpu*/cache/index3/cache_disable_{0,1} 162What: /sys/devices/system/cpu/cpu*/cache/index3/cache_disable_{0,1}
148Date: August 2008 163Date: August 2008
149KernelVersion: 2.6.27 164KernelVersion: 2.6.27
diff --git a/Documentation/ABI/testing/sysfs-firmware-acpi b/Documentation/ABI/testing/sysfs-firmware-acpi
index ce9bee98b43b..b4436cca97a8 100644
--- a/Documentation/ABI/testing/sysfs-firmware-acpi
+++ b/Documentation/ABI/testing/sysfs-firmware-acpi
@@ -44,6 +44,16 @@ Description:
44 or 0 (unset). Attempts to write any other values to it will 44 or 0 (unset). Attempts to write any other values to it will
45 cause -EINVAL to be returned. 45 cause -EINVAL to be returned.
46 46
47What: /sys/firmware/acpi/hotplug/force_remove
48Date: May 2013
49Contact: Rafael J. Wysocki <rafael.j.wysocki@intel.com>
50Description:
51 The number in this file (0 or 1) determines whether (1) or not
52 (0) the ACPI subsystem will allow devices to be hot-removed even
53 if they cannot be put offline gracefully (from the kernel's
54 viewpoint). That number can be changed by writing a boolean
55 value to this file.
56
47What: /sys/firmware/acpi/interrupts/ 57What: /sys/firmware/acpi/interrupts/
48Date: February 2008 58Date: February 2008
49Contact: Len Brown <lenb@kernel.org> 59Contact: Len Brown <lenb@kernel.org>
diff --git a/Documentation/acpi/namespace.txt b/Documentation/acpi/namespace.txt
new file mode 100644
index 000000000000..260f6a3661fa
--- /dev/null
+++ b/Documentation/acpi/namespace.txt
@@ -0,0 +1,395 @@
1ACPI Device Tree - Representation of ACPI Namespace
2
3Copyright (C) 2013, Intel Corporation
4Author: Lv Zheng <lv.zheng@intel.com>
5
6
7Abstract:
8
9The Linux ACPI subsystem converts ACPI namespace objects into a Linux
10device tree under the /sys/devices/LNXSYSTEM:00 and updates it upon
11receiving ACPI hotplug notification events. For each device object in this
12hierarchy there is a corresponding symbolic link in the
13/sys/bus/acpi/devices.
14This document illustrates the structure of the ACPI device tree.
15
16
17Credit:
18
19Thanks for the help from Zhang Rui <rui.zhang@intel.com> and Rafael J.
20Wysocki <rafael.j.wysocki@intel.com>.
21
22
231. ACPI Definition Blocks
24
25 The ACPI firmware sets up RSDP (Root System Description Pointer) in the
26 system memory address space pointing to the XSDT (Extended System
27 Description Table). The XSDT always points to the FADT (Fixed ACPI
28 Description Table) using its first entry, the data within the FADT
29 includes various fixed-length entries that describe fixed ACPI features
30 of the hardware. The FADT contains a pointer to the DSDT
31 (Differentiated System Descripition Table). The XSDT also contains
32 entries pointing to possibly multiple SSDTs (Secondary System
33 Description Table).
34
35 The DSDT and SSDT data is organized in data structures called definition
36 blocks that contain definitions of various objects, including ACPI
37 control methods, encoded in AML (ACPI Machine Language). The data block
38 of the DSDT along with the contents of SSDTs represents a hierarchical
39 data structure called the ACPI namespace whose topology reflects the
40 structure of the underlying hardware platform.
41
42 The relationships between ACPI System Definition Tables described above
43 are illustrated in the following diagram.
44
45 +---------+ +-------+ +--------+ +------------------------+
46 | RSDP | +->| XSDT | +->| FADT | | +-------------------+ |
47 +---------+ | +-------+ | +--------+ +-|->| DSDT | |
48 | Pointer | | | Entry |-+ | ...... | | | +-------------------+ |
49 +---------+ | +-------+ | X_DSDT |--+ | | Definition Blocks | |
50 | Pointer |-+ | ..... | | ...... | | +-------------------+ |
51 +---------+ +-------+ +--------+ | +-------------------+ |
52 | Entry |------------------|->| SSDT | |
53 +- - - -+ | +-------------------| |
54 | Entry | - - - - - - - -+ | | Definition Blocks | |
55 +- - - -+ | | +-------------------+ |
56 | | +- - - - - - - - - -+ |
57 +-|->| SSDT | |
58 | +-------------------+ |
59 | | Definition Blocks | |
60 | +- - - - - - - - - -+ |
61 +------------------------+
62 |
63 OSPM Loading |
64 \|/
65 +----------------+
66 | ACPI Namespace |
67 +----------------+
68
69 Figure 1. ACPI Definition Blocks
70
71 NOTE: RSDP can also contain a pointer to the RSDT (Root System
72 Description Table). Platforms provide RSDT to enable
73 compatibility with ACPI 1.0 operating systems. The OS is expected
74 to use XSDT, if present.
75
76
772. Example ACPI Namespace
78
79 All definition blocks are loaded into a single namespace. The namespace
80 is a hierarchy of objects identified by names and paths.
81 The following naming conventions apply to object names in the ACPI
82 namespace:
83 1. All names are 32 bits long.
84 2. The first byte of a name must be one of 'A' - 'Z', '_'.
85 3. Each of the remaining bytes of a name must be one of 'A' - 'Z', '0'
86 - '9', '_'.
87 4. Names starting with '_' are reserved by the ACPI specification.
88 5. The '\' symbol represents the root of the namespace (i.e. names
89 prepended with '\' are relative to the namespace root).
90 6. The '^' symbol represents the parent of the current namespace node
91 (i.e. names prepended with '^' are relative to the parent of the
92 current namespace node).
93
94 The figure below shows an example ACPI namespace.
95
96 +------+
97 | \ | Root
98 +------+
99 |
100 | +------+
101 +-| _PR | Scope(_PR): the processor namespace
102 | +------+
103 | |
104 | | +------+
105 | +-| CPU0 | Processor(CPU0): the first processor
106 | +------+
107 |
108 | +------+
109 +-| _SB | Scope(_SB): the system bus namespace
110 | +------+
111 | |
112 | | +------+
113 | +-| LID0 | Device(LID0); the lid device
114 | | +------+
115 | | |
116 | | | +------+
117 | | +-| _HID | Name(_HID, "PNP0C0D"): the hardware ID
118 | | | +------+
119 | | |
120 | | | +------+
121 | | +-| _STA | Method(_STA): the status control method
122 | | +------+
123 | |
124 | | +------+
125 | +-| PCI0 | Device(PCI0); the PCI root bridge
126 | +------+
127 | |
128 | | +------+
129 | +-| _HID | Name(_HID, "PNP0A08"): the hardware ID
130 | | +------+
131 | |
132 | | +------+
133 | +-| _CID | Name(_CID, "PNP0A03"): the compatible ID
134 | | +------+
135 | |
136 | | +------+
137 | +-| RP03 | Scope(RP03): the PCI0 power scope
138 | | +------+
139 | | |
140 | | | +------+
141 | | +-| PXP3 | PowerResource(PXP3): the PCI0 power resource
142 | | +------+
143 | |
144 | | +------+
145 | +-| GFX0 | Device(GFX0): the graphics adapter
146 | +------+
147 | |
148 | | +------+
149 | +-| _ADR | Name(_ADR, 0x00020000): the PCI bus address
150 | | +------+
151 | |
152 | | +------+
153 | +-| DD01 | Device(DD01): the LCD output device
154 | +------+
155 | |
156 | | +------+
157 | +-| _BCL | Method(_BCL): the backlight control method
158 | +------+
159 |
160 | +------+
161 +-| _TZ | Scope(_TZ): the thermal zone namespace
162 | +------+
163 | |
164 | | +------+
165 | +-| FN00 | PowerResource(FN00): the FAN0 power resource
166 | | +------+
167 | |
168 | | +------+
169 | +-| FAN0 | Device(FAN0): the FAN0 cooling device
170 | | +------+
171 | | |
172 | | | +------+
173 | | +-| _HID | Name(_HID, "PNP0A0B"): the hardware ID
174 | | +------+
175 | |
176 | | +------+
177 | +-| TZ00 | ThermalZone(TZ00); the FAN thermal zone
178 | +------+
179 |
180 | +------+
181 +-| _GPE | Scope(_GPE): the GPE namespace
182 +------+
183
184 Figure 2. Example ACPI Namespace
185
186
1873. Linux ACPI Device Objects
188
189 The Linux kernel's core ACPI subsystem creates struct acpi_device
190 objects for ACPI namespace objects representing devices, power resources
191 processors, thermal zones. Those objects are exported to user space via
192 sysfs as directories in the subtree under /sys/devices/LNXSYSTM:00. The
193 format of their names is <bus_id:instance>, where 'bus_id' refers to the
194 ACPI namespace representation of the given object and 'instance' is used
195 for distinguishing different object of the same 'bus_id' (it is
196 two-digit decimal representation of an unsigned integer).
197
198 The value of 'bus_id' depends on the type of the object whose name it is
199 part of as listed in the table below.
200
201 +---+-----------------+-------+----------+
202 | | Object/Feature | Table | bus_id |
203 +---+-----------------+-------+----------+
204 | N | Root | xSDT | LNXSYSTM |
205 +---+-----------------+-------+----------+
206 | N | Device | xSDT | _HID |
207 +---+-----------------+-------+----------+
208 | N | Processor | xSDT | LNXCPU |
209 +---+-----------------+-------+----------+
210 | N | ThermalZone | xSDT | LNXTHERM |
211 +---+-----------------+-------+----------+
212 | N | PowerResource | xSDT | LNXPOWER |
213 +---+-----------------+-------+----------+
214 | N | Other Devices | xSDT | device |
215 +---+-----------------+-------+----------+
216 | F | PWR_BUTTON | FADT | LNXPWRBN |
217 +---+-----------------+-------+----------+
218 | F | SLP_BUTTON | FADT | LNXSLPBN |
219 +---+-----------------+-------+----------+
220 | M | Video Extension | xSDT | LNXVIDEO |
221 +---+-----------------+-------+----------+
222 | M | ATA Controller | xSDT | LNXIOBAY |
223 +---+-----------------+-------+----------+
224 | M | Docking Station | xSDT | LNXDOCK |
225 +---+-----------------+-------+----------+
226
227 Table 1. ACPI Namespace Objects Mapping
228
229 The following rules apply when creating struct acpi_device objects on
230 the basis of the contents of ACPI System Description Tables (as
231 indicated by the letter in the first column and the notation in the
232 second column of the table above):
233 N:
234 The object's source is an ACPI namespace node (as indicated by the
235 named object's type in the second column). In that case the object's
236 directory in sysfs will contain the 'path' attribute whose value is
237 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.
242 F:
243 The struct acpi_device object is created for a fixed hardware
244 feature (as indicated by the fixed feature flag's name in the second
245 column), so its sysfs directory will not contain the 'path'
246 attribute.
247 M:
248 The struct acpi_device object is created for an ACPI namespace node
249 with specific control methods (as indicated by the ACPI defined
250 device's type in the second column). The 'path' attribute containing
251 its namespace path will be present in its sysfs directory. For
252 example, if the _BCL method is present for an ACPI namespace node, a
253 struct acpi_device object with LNXVIDEO 'bus_id' will be created for
254 it.
255
256 The third column of the above table indicates which ACPI System
257 Description Tables contain information used for the creation of the
258 struct acpi_device objects represented by the given row (xSDT means DSDT
259 or SSDT).
260
261 The forth column of the above table indicates the 'bus_id' generation
262 rule of the struct acpi_device object:
263 _HID:
264 _HID in the last column of the table means that the object's bus_id
265 is derived from the _HID/_CID identification objects present under
266 the corresponding ACPI namespace node. The object's sysfs directory
267 will then contain the 'hid' and 'modalias' attributes that can be
268 used to retrieve the _HID and _CIDs of that object.
269 LNXxxxxx:
270 The 'modalias' attribute is also present for struct acpi_device
271 objects having bus_id of the "LNXxxxxx" form (pseudo devices), in
272 which cases it contains the bus_id string itself.
273 device:
274 'device' in the last column of the table indicates that the object's
275 bus_id cannot be determined from _HID/_CID of the corresponding
276 ACPI namespace node, although that object represents a device (for
277 example, it may be a PCI device with _ADR defined and without _HID
278 or _CID). In that case the string 'device' will be used as the
279 object's bus_id.
280
281
2824. Linux ACPI Physical Device Glue
283
284 ACPI device (i.e. struct acpi_device) objects may be linked to other
285 objects in the Linux' device hierarchy that represent "physical" devices
286 (for example, devices on the PCI bus). If that happens, it means that
287 the ACPI device object is a "companion" of a device otherwise
288 represented in a different way and is used (1) to provide configuration
289 information on that device which cannot be obtained by other means and
290 (2) to do specific things to the device with the help of its ACPI
291 control methods. One ACPI device object may be linked this way to
292 multiple "physical" devices.
293
294 If an ACPI device object is linked to a "physical" device, its sysfs
295 directory contains the "physical_node" symbolic link to the sysfs
296 directory of the target device object. In turn, the target device's
297 sysfs directory will then contain the "firmware_node" symbolic link to
298 the sysfs directory of the companion ACPI device object.
299 The linking mechanism relies on device identification provided by the
300 ACPI namespace. For example, if there's an ACPI namespace object
301 representing a PCI device (i.e. a device object under an ACPI namespace
302 object representing a PCI bridge) whose _ADR returns 0x00020000 and the
303 bus number of the parent PCI bridge is 0, the sysfs directory
304 representing the struct acpi_device object created for that ACPI
305 namespace object will contain the 'physical_node' symbolic link to the
306 /sys/devices/pci0000:00/0000:00:02:0/ sysfs directory of the
307 corresponding PCI device.
308
309 The linking mechanism is generally bus-specific. The core of its
310 implementation is located in the drivers/acpi/glue.c file, but there are
311 complementary parts depending on the bus types in question located
312 elsewhere. For example, the PCI-specific part of it is located in
313 drivers/pci/pci-acpi.c.
314
315
3165. Example Linux ACPI Device Tree
317
318 The sysfs hierarchy of struct acpi_device objects corresponding to the
319 example ACPI namespace illustrated in Figure 2 with the addition of
320 fixed PWR_BUTTON/SLP_BUTTON devices is shown below.
321
322 +--------------+---+-----------------+
323 | LNXSYSTEM:00 | \ | acpi:LNXSYSTEM: |
324 +--------------+---+-----------------+
325 |
326 | +-------------+-----+----------------+
327 +-| LNXPWRBN:00 | N/A | acpi:LNXPWRBN: |
328 | +-------------+-----+----------------+
329 |
330 | +-------------+-----+----------------+
331 +-| LNXSLPBN:00 | N/A | acpi:LNXSLPBN: |
332 | +-------------+-----+----------------+
333 |
334 | +-----------+------------+--------------+
335 +-| LNXCPU:00 | \_PR_.CPU0 | acpi:LNXCPU: |
336 | +-----------+------------+--------------+
337 |
338 | +-------------+-------+----------------+
339 +-| LNXSYBUS:00 | \_SB_ | acpi:LNXSYBUS: |
340 | +-------------+-------+----------------+
341 | |
342 | | +- - - - - - - +- - - - - - +- - - - - - - -+
343 | +-| * PNP0C0D:00 | \_SB_.LID0 | acpi:PNP0C0D: |
344 | | +- - - - - - - +- - - - - - +- - - - - - - -+
345 | |
346 | | +------------+------------+-----------------------+
347 | +-| PNP0A08:00 | \_SB_.PCI0 | acpi:PNP0A08:PNP0A03: |
348 | +------------+------------+-----------------------+
349 | |
350 | | +-----------+-----------------+-----+
351 | +-| device:00 | \_SB_.PCI0.RP03 | N/A |
352 | | +-----------+-----------------+-----+
353 | | |
354 | | | +-------------+----------------------+----------------+
355 | | +-| LNXPOWER:00 | \_SB_.PCI0.RP03.PXP3 | acpi:LNXPOWER: |
356 | | +-------------+----------------------+----------------+
357 | |
358 | | +-------------+-----------------+----------------+
359 | +-| LNXVIDEO:00 | \_SB_.PCI0.GFX0 | acpi:LNXVIDEO: |
360 | +-------------+-----------------+----------------+
361 | |
362 | | +-----------+-----------------+-----+
363 | +-| device:01 | \_SB_.PCI0.DD01 | N/A |
364 | +-----------+-----------------+-----+
365 |
366 | +-------------+-------+----------------+
367 +-| LNXSYBUS:01 | \_TZ_ | acpi:LNXSYBUS: |
368 +-------------+-------+----------------+
369 |
370 | +-------------+------------+----------------+
371 +-| LNXPOWER:0a | \_TZ_.FN00 | acpi:LNXPOWER: |
372 | +-------------+------------+----------------+
373 |
374 | +------------+------------+---------------+
375 +-| PNP0C0B:00 | \_TZ_.FAN0 | acpi:PNP0C0B: |
376 | +------------+------------+---------------+
377 |
378 | +-------------+------------+----------------+
379 +-| LNXTHERM:00 | \_TZ_.TZ00 | acpi:LNXTHERM: |
380 +-------------+------------+----------------+
381
382 Figure 3. Example Linux ACPI Device Tree
383
384 NOTE: Each node is represented as "object/path/modalias", where:
385 1. 'object' is the name of the object's directory in sysfs.
386 2. 'path' is the ACPI namespace path of the corresponding
387 ACPI namespace object, as returned by the object's 'path'
388 sysfs attribute.
389 3. 'modalias' is the value of the object's 'modalias' sysfs
390 attribute (as described earlier in this document).
391 NOTE: N/A indicates the device object does not have the 'path' or the
392 '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.
diff --git a/Documentation/acpi/video_extension.txt b/Documentation/acpi/video_extension.txt
new file mode 100644
index 000000000000..78b32ac02466
--- /dev/null
+++ b/Documentation/acpi/video_extension.txt
@@ -0,0 +1,106 @@
1ACPI video extensions
2~~~~~~~~~~~~~~~~~~~~~
3
4This driver implement the ACPI Extensions For Display Adapters for
5integrated graphics devices on motherboard, as specified in ACPI 2.0
6Specification, Appendix B, allowing to perform some basic control like
7defining the video POST device, retrieving EDID information or to
8setup a video output, etc. Note that this is an ref. implementation
9only. It may or may not work for your integrated video device.
10
11The ACPI video driver does 3 things regarding backlight control:
12
131 Export a sysfs interface for user space to control backlight level
14
15If the ACPI table has a video device, and acpi_backlight=vendor kernel
16command line is not present, the driver will register a backlight device
17and set the required backlight operation structure for it for the sysfs
18interface control. For every registered class device, there will be a
19directory named acpi_videoX under /sys/class/backlight.
20
21The backlight sysfs interface has a standard definition here:
22Documentation/ABI/stable/sysfs-class-backlight.
23
24And what ACPI video driver does is:
25actual_brightness: on read, control method _BQC will be evaluated to
26get the brightness level the firmware thinks it is at;
27bl_power: not implemented, will set the current brightness instead;
28brightness: on write, control method _BCM will run to set the requested
29brightness level;
30max_brightness: Derived from the _BCL package(see below);
31type: firmware
32
33Note that ACPI video backlight driver will always use index for
34brightness, actual_brightness and max_brightness. So if we have
35the following _BCL package:
36
37Method (_BCL, 0, NotSerialized)
38{
39 Return (Package (0x0C)
40 {
41 0x64,
42 0x32,
43 0x0A,
44 0x14,
45 0x1E,
46 0x28,
47 0x32,
48 0x3C,
49 0x46,
50 0x50,
51 0x5A,
52 0x64
53 })
54}
55
56The first two levels are for when laptop are on AC or on battery and are
57not used by Linux currently. The remaining 10 levels are supported levels
58that we can choose from. The applicable index values are from 0 (that
59corresponds to the 0x0A brightness value) to 9 (that corresponds to the
600x64 brightness value) inclusive. Each of those index values is regarded
61as a "brightness level" indicator. Thus from the user space perspective
62the range of available brightness levels is from 0 to 9 (max_brightness)
63inclusive.
64
652 Notify user space about hotkey event
66
67There are generally two cases for hotkey event reporting:
68i) For some laptops, when user presses the hotkey, a scancode will be
69 generated and sent to user space through the input device created by
70 the keyboard driver as a key type input event, with proper remap, the
71 following key code will appear to user space:
72
73 EV_KEY, KEY_BRIGHTNESSUP
74 EV_KEY, KEY_BRIGHTNESSDOWN
75 etc.
76
77For this case, ACPI video driver does not need to do anything(actually,
78it doesn't even know this happened).
79
80ii) For some laptops, the press of the hotkey will not generate the
81 scancode, instead, firmware will notify the video device ACPI node
82 about the event. The event value is defined in the ACPI spec. ACPI
83 video driver will generate an key type input event according to the
84 notify value it received and send the event to user space through the
85 input device it created:
86
87 event keycode
88 0x86 KEY_BRIGHTNESSUP
89 0x87 KEY_BRIGHTNESSDOWN
90 etc.
91
92so this would lead to the same effect as case i) now.
93
94Once user space tool receives this event, it can modify the backlight
95level through the sysfs interface.
96
973 Change backlight level in the kernel
98
99This works for machines covered by case ii) in Section 2. Once the driver
100received a notification, it will set the backlight level accordingly. This does
101not affect the sending of event to user space, they are always sent to user
102space regardless of whether or not the video module controls the backlight level
103directly. This behaviour can be controlled through the brightness_switch_enabled
104module parameter as documented in kernel-parameters.txt. It is recommended to
105disable this behaviour once a GUI environment starts up and wants to have full
106control of the backlight level.
diff --git a/Documentation/cpu-freq/cpu-drivers.txt b/Documentation/cpu-freq/cpu-drivers.txt
index a3585eac83b6..19fa98e07bf7 100644
--- a/Documentation/cpu-freq/cpu-drivers.txt
+++ b/Documentation/cpu-freq/cpu-drivers.txt
@@ -186,7 +186,7 @@ As most cpufreq processors only allow for being set to a few specific
186frequencies, a "frequency table" with some functions might assist in 186frequencies, a "frequency table" with some functions might assist in
187some work of the processor driver. Such a "frequency table" consists 187some work of the processor driver. Such a "frequency table" consists
188of an array of struct cpufreq_frequency_table entries, with any value in 188of an array of struct cpufreq_frequency_table entries, with any value in
189"index" you want to use, and the corresponding frequency in 189"driver_data" you want to use, and the corresponding frequency in
190"frequency". At the end of the table, you need to add a 190"frequency". At the end of the table, you need to add a
191cpufreq_frequency_table entry with frequency set to CPUFREQ_TABLE_END. And 191cpufreq_frequency_table entry with frequency set to CPUFREQ_TABLE_END. And
192if you want to skip one entry in the table, set the frequency to 192if you want to skip one entry in the table, set the frequency to
@@ -214,10 +214,4 @@ int cpufreq_frequency_table_target(struct cpufreq_policy *policy,
214is the corresponding frequency table helper for the ->target 214is the corresponding frequency table helper for the ->target
215stage. Just pass the values to this function, and the unsigned int 215stage. Just pass the values to this function, and the unsigned int
216index returns the number of the frequency table entry which contains 216index returns the number of the frequency table entry which contains
217the frequency the CPU shall be set to. PLEASE NOTE: This is not the 217the frequency the CPU shall be set to.
218"index" which is in this cpufreq_table_entry.index, but instead
219cpufreq_table[index]. So, the new frequency is
220cpufreq_table[index].frequency, and the value you stored into the
221frequency table "index" field is
222cpufreq_table[index].index.
223
diff --git a/Documentation/cpu-hotplug.txt b/Documentation/cpu-hotplug.txt
index 0efd1b905b9d..edd4b4df3932 100644
--- a/Documentation/cpu-hotplug.txt
+++ b/Documentation/cpu-hotplug.txt
@@ -370,8 +370,10 @@ A: There is no clear spec defined way from ACPI that can give us that
370 CPUs in MADT as hotpluggable CPUS. In the case there are no disabled CPUS 370 CPUs in MADT as hotpluggable CPUS. In the case there are no disabled CPUS
371 we assume 1/2 the number of CPUs currently present can be hotplugged. 371 we assume 1/2 the number of CPUs currently present can be hotplugged.
372 372
373 Caveat: Today's ACPI MADT can only provide 256 entries since the apicid field 373 Caveat: ACPI MADT can only provide 256 entries in systems with only ACPI 2.0c
374 in MADT is only 8 bits. 374 or earlier ACPI version supported, because the apicid field in MADT is only
375 8 bits. From ACPI 3.0, this limitation was removed since the apicid field
376 was extended to 32 bits with x2APIC introduced.
375 377
376User Space Notification 378User Space Notification
377 379
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index 3c80382a84dd..ef8bd35814cf 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -3231,6 +3231,15 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
3231 video= [FB] Frame buffer configuration 3231 video= [FB] Frame buffer configuration
3232 See Documentation/fb/modedb.txt. 3232 See Documentation/fb/modedb.txt.
3233 3233
3234 video.brightness_switch_enabled= [0,1]
3235 If set to 1, on receiving an ACPI notify event
3236 generated by hotkey, video driver will adjust brightness
3237 level and then send out the event to user space through
3238 the allocated input device; If set to 0, video driver
3239 will only send out the event without touching backlight
3240 brightness level.
3241 default: 1
3242
3234 virtio_mmio.device= 3243 virtio_mmio.device=
3235 [VMMIO] Memory mapped virtio (platform) device. 3244 [VMMIO] Memory mapped virtio (platform) device.
3236 3245
diff --git a/Documentation/power/pm_qos_interface.txt b/Documentation/power/pm_qos_interface.txt
index 79a2a58425ee..483632087788 100644
--- a/Documentation/power/pm_qos_interface.txt
+++ b/Documentation/power/pm_qos_interface.txt
@@ -7,7 +7,7 @@ one of the parameters.
7Two different PM QoS frameworks are available: 7Two different PM QoS frameworks are available:
81. PM QoS classes for cpu_dma_latency, network_latency, network_throughput. 81. PM QoS classes for cpu_dma_latency, network_latency, network_throughput.
92. the per-device PM QoS framework provides the API to manage the per-device latency 92. the per-device PM QoS framework provides the API to manage the per-device latency
10constraints. 10constraints and PM QoS flags.
11 11
12Each parameters have defined units: 12Each parameters have defined units:
13 * latency: usec 13 * latency: usec
@@ -86,13 +86,17 @@ To remove the user mode request for a target value simply close the device
86node. 86node.
87 87
88 88
892. PM QoS per-device latency framework 892. PM QoS per-device latency and flags framework
90
91For each device, there are two lists of PM QoS requests. One is maintained
92along with the aggregated target of latency value and the other is for PM QoS
93flags. Values are updated in response to changes of the request list.
94
95Target latency value is simply the minimum of the request values held in the
96parameter list elements. The PM QoS flags aggregate value is a gather (bitwise
97OR) of all list elements' values. Two device PM QoS flags are defined currently:
98PM_QOS_FLAG_NO_POWER_OFF and PM_QOS_FLAG_REMOTE_WAKEUP.
90 99
91For each device a list of performance requests is maintained along with
92an aggregated target value. The aggregated target value is updated with
93changes to the request list or elements of the list. Typically the
94aggregated target value is simply the max or min of the request values held
95in the parameter list elements.
96Note: the aggregated target value is implemented as an atomic variable so that 100Note: the aggregated target value is implemented as an atomic variable so that
97reading the aggregated value does not require any locking mechanism. 101reading the aggregated value does not require any locking mechanism.
98 102
@@ -119,6 +123,38 @@ the request.
119s32 dev_pm_qos_read_value(device): 123s32 dev_pm_qos_read_value(device):
120Returns the aggregated value for a given device's constraints list. 124Returns the aggregated value for a given device's constraints list.
121 125
126enum pm_qos_flags_status dev_pm_qos_flags(device, mask)
127Check PM QoS flags of the given device against the given mask of flags.
128The meaning of the return values is as follows:
129 PM_QOS_FLAGS_ALL: All flags from the mask are set
130 PM_QOS_FLAGS_SOME: Some flags from the mask are set
131 PM_QOS_FLAGS_NONE: No flags from the mask are set
132 PM_QOS_FLAGS_UNDEFINED: The device's PM QoS structure has not been
133 initialized or the list of requests is empty.
134
135int dev_pm_qos_add_ancestor_request(dev, handle, value)
136Add a PM QoS request for the first direct ancestor of the given device whose
137power.ignore_children flag is unset.
138
139int dev_pm_qos_expose_latency_limit(device, value)
140Add a request to the device's PM QoS list of latency constraints and create
141a sysfs attribute pm_qos_resume_latency_us under the device's power directory
142allowing user space to manipulate that request.
143
144void dev_pm_qos_hide_latency_limit(device)
145Drop the request added by dev_pm_qos_expose_latency_limit() from the device's
146PM QoS list of latency constraints and remove sysfs attribute pm_qos_resume_latency_us
147from the device's power directory.
148
149int dev_pm_qos_expose_flags(device, value)
150Add a request to the device's PM QoS list of flags and create sysfs attributes
151pm_qos_no_power_off and pm_qos_remote_wakeup under the device's power directory
152allowing user space to change these flags' value.
153
154void dev_pm_qos_hide_flags(device)
155Drop the request added by dev_pm_qos_expose_flags() from the device's PM QoS list
156of flags and remove sysfs attributes pm_qos_no_power_off and pm_qos_remote_wakeup
157under the device's power directory.
122 158
123Notification mechanisms: 159Notification mechanisms:
124The per-device PM QoS framework has 2 different and distinct notification trees: 160The per-device PM QoS framework has 2 different and distinct notification trees:
diff --git a/Documentation/power/runtime_pm.txt b/Documentation/power/runtime_pm.txt
index 6c9f5d9aa115..71d8fe4e75d3 100644
--- a/Documentation/power/runtime_pm.txt
+++ b/Documentation/power/runtime_pm.txt
@@ -144,8 +144,12 @@ The action performed by the idle callback is totally dependent on the subsystem
144(or driver) in question, but the expected and recommended action is to check 144(or driver) in question, but the expected and recommended action is to check
145if the device can be suspended (i.e. if all of the conditions necessary for 145if the device can be suspended (i.e. if all of the conditions necessary for
146suspending the device are satisfied) and to queue up a suspend request for the 146suspending the device are satisfied) and to queue up a suspend request for the
147device in that case. The value returned by this callback is ignored by the PM 147device in that case. If there is no idle callback, or if the callback returns
148core. 1480, then the PM core will attempt to carry out a runtime suspend of the device;
149in essence, it will call pm_runtime_suspend() directly. To prevent this (for
150example, if the callback routine has started a delayed suspend), the routine
151should return a non-zero value. Negative error return codes are ignored by the
152PM core.
149 153
150The helper functions provided by the PM core, described in Section 4, guarantee 154The helper functions provided by the PM core, described in Section 4, guarantee
151that the following constraints are met with respect to runtime PM callbacks for 155that the following constraints are met with respect to runtime PM callbacks for
@@ -301,9 +305,10 @@ drivers/base/power/runtime.c and include/linux/pm_runtime.h:
301 removing the device from device hierarchy 305 removing the device from device hierarchy
302 306
303 int pm_runtime_idle(struct device *dev); 307 int pm_runtime_idle(struct device *dev);
304 - execute the subsystem-level idle callback for the device; returns 0 on 308 - execute the subsystem-level idle callback for the device; returns an
305 success or error code on failure, where -EINPROGRESS means that 309 error code on failure, where -EINPROGRESS means that ->runtime_idle() is
306 ->runtime_idle() is already being executed 310 already being executed; if there is no callback or the callback returns 0
311 then run pm_runtime_suspend(dev) and return its result
307 312
308 int pm_runtime_suspend(struct device *dev); 313 int pm_runtime_suspend(struct device *dev);
309 - execute the subsystem-level suspend callback for the device; returns 0 on 314 - execute the subsystem-level suspend callback for the device; returns 0 on
@@ -660,11 +665,6 @@ Subsystems may wish to conserve code space by using the set of generic power
660management callbacks provided by the PM core, defined in 665management callbacks provided by the PM core, defined in
661driver/base/power/generic_ops.c: 666driver/base/power/generic_ops.c:
662 667
663 int pm_generic_runtime_idle(struct device *dev);
664 - invoke the ->runtime_idle() callback provided by the driver of this
665 device, if defined, and call pm_runtime_suspend() for this device if the
666 return value is 0 or the callback is not defined
667
668 int pm_generic_runtime_suspend(struct device *dev); 668 int pm_generic_runtime_suspend(struct device *dev);
669 - invoke the ->runtime_suspend() callback provided by the driver of this 669 - invoke the ->runtime_suspend() callback provided by the driver of this
670 device and return its result, or return -EINVAL if not defined 670 device and return its result, or return -EINVAL if not defined
diff --git a/Documentation/power/video_extension.txt b/Documentation/power/video_extension.txt
deleted file mode 100644
index b2f9b1598ac2..000000000000
--- a/Documentation/power/video_extension.txt
+++ /dev/null
@@ -1,37 +0,0 @@
1ACPI video extensions
2~~~~~~~~~~~~~~~~~~~~~
3
4This driver implement the ACPI Extensions For Display Adapters for
5integrated graphics devices on motherboard, as specified in ACPI 2.0
6Specification, Appendix B, allowing to perform some basic control like
7defining the video POST device, retrieving EDID information or to
8setup a video output, etc. Note that this is an ref. implementation
9only. It may or may not work for your integrated video device.
10
11Interfaces exposed to userland through /proc/acpi/video:
12
13VGA/info : display the supported video bus device capability like Video ROM, CRT/LCD/TV.
14VGA/ROM : Used to get a copy of the display devices' ROM data (up to 4k).
15VGA/POST_info : Used to determine what options are implemented.
16VGA/POST : Used to get/set POST device.
17VGA/DOS : Used to get/set ownership of output switching:
18 Please refer ACPI spec B.4.1 _DOS
19VGA/CRT : CRT output
20VGA/LCD : LCD output
21VGA/TVO : TV output
22VGA/*/brightness : Used to get/set brightness of output device
23
24Notify event through /proc/acpi/event:
25
26#define ACPI_VIDEO_NOTIFY_SWITCH 0x80
27#define ACPI_VIDEO_NOTIFY_PROBE 0x81
28#define ACPI_VIDEO_NOTIFY_CYCLE 0x82
29#define ACPI_VIDEO_NOTIFY_NEXT_OUTPUT 0x83
30#define ACPI_VIDEO_NOTIFY_PREV_OUTPUT 0x84
31
32#define ACPI_VIDEO_NOTIFY_CYCLE_BRIGHTNESS 0x82
33#define ACPI_VIDEO_NOTIFY_INC_BRIGHTNESS 0x83
34#define ACPI_VIDEO_NOTIFY_DEC_BRIGHTNESS 0x84
35#define ACPI_VIDEO_NOTIFY_ZERO_BRIGHTNESS 0x85
36#define ACPI_VIDEO_NOTIFY_DISPLAY_OFF 0x86
37
diff --git a/Documentation/trace/events-power.txt b/Documentation/trace/events-power.txt
index e1498ff8cf94..3bd33b8dc7c4 100644
--- a/Documentation/trace/events-power.txt
+++ b/Documentation/trace/events-power.txt
@@ -63,3 +63,34 @@ power_domain_target "%s state=%lu cpu_id=%lu"
63The first parameter gives the power domain name (e.g. "mpu_pwrdm"). 63The first parameter gives the power domain name (e.g. "mpu_pwrdm").
64The second parameter is the power domain target state. 64The second parameter is the power domain target state.
65 65
664. PM QoS events
67================
68The PM QoS events are used for QoS add/update/remove request and for
69target/flags update.
70
71pm_qos_add_request "pm_qos_class=%s value=%d"
72pm_qos_update_request "pm_qos_class=%s value=%d"
73pm_qos_remove_request "pm_qos_class=%s value=%d"
74pm_qos_update_request_timeout "pm_qos_class=%s value=%d, timeout_us=%ld"
75
76The first parameter gives the QoS class name (e.g. "CPU_DMA_LATENCY").
77The second parameter is value to be added/updated/removed.
78The third parameter is timeout value in usec.
79
80pm_qos_update_target "action=%s prev_value=%d curr_value=%d"
81pm_qos_update_flags "action=%s prev_value=0x%x curr_value=0x%x"
82
83The first parameter gives the QoS action name (e.g. "ADD_REQ").
84The second parameter is the previous QoS value.
85The third parameter is the current QoS value to update.
86
87And, there are also events used for device PM QoS add/update/remove request.
88
89dev_pm_qos_add_request "device=%s type=%s new_value=%d"
90dev_pm_qos_update_request "device=%s type=%s new_value=%d"
91dev_pm_qos_remove_request "device=%s type=%s new_value=%d"
92
93The first parameter gives the device name which tries to add/update/remove
94QoS requests.
95The second parameter gives the request type (e.g. "DEV_PM_QOS_LATENCY").
96The third parameter is value to be added/updated/removed.