aboutsummaryrefslogtreecommitdiffstats
path: root/Documentation
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2011-05-19 19:46:07 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2011-05-19 19:46:07 -0400
commit51509a283a908d73b20371addc67ee3ae7189934 (patch)
treebb920f09799cc47d496f26f7deb78a315351150d /Documentation
parent75f5076b12924f53340209d2cde73b98ed3b3095 (diff)
parent6538df80194e305f1b78cafb556f4bb442f808b3 (diff)
Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6
* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/rafael/suspend-2.6: (34 commits) PM: Introduce generic prepare and complete callbacks for subsystems PM: Allow drivers to allocate memory from .prepare() callbacks safely PM: Remove CONFIG_PM_VERBOSE Revert "PM / Hibernate: Reduce autotuned default image size" PM / Hibernate: Add sysfs knob to control size of memory for drivers PM / Wakeup: Remove useless synchronize_rcu() call kmod: always provide usermodehelper_disable() PM / ACPI: Remove acpi_sleep=s4_nonvs PM / Wakeup: Fix build warning related to the "wakeup" sysfs file PM: Print a warning if firmware is requested when tasks are frozen PM / Runtime: Rework runtime PM handling during driver removal Freezer: Use SMP barriers PM / Suspend: Do not ignore error codes returned by suspend_enter() PM: Fix build issue in clock_ops.c for CONFIG_PM_RUNTIME unset PM: Revert "driver core: platform_bus: allow runtime override of dev_pm_ops" OMAP1 / PM: Use generic clock manipulation routines for runtime PM PM: Remove sysdev suspend, resume and shutdown operations PM / PowerPC: Use struct syscore_ops instead of sysdevs for PM PM / UNICORE32: Use struct syscore_ops instead of sysdevs for PM PM / AVR32: Use struct syscore_ops instead of sysdevs for PM ...
Diffstat (limited to 'Documentation')
-rw-r--r--Documentation/ABI/testing/sysfs-power14
-rw-r--r--Documentation/feature-removal-schedule.txt8
-rw-r--r--Documentation/kernel-parameters.txt2
-rw-r--r--Documentation/power/devices.txt14
-rw-r--r--Documentation/power/notifiers.txt51
5 files changed, 47 insertions, 42 deletions
diff --git a/Documentation/ABI/testing/sysfs-power b/Documentation/ABI/testing/sysfs-power
index 194ca446ac28..b464d12761ba 100644
--- a/Documentation/ABI/testing/sysfs-power
+++ b/Documentation/ABI/testing/sysfs-power
@@ -158,3 +158,17 @@ Description:
158 successful, will make the kernel abort a subsequent transition 158 successful, will make the kernel abort a subsequent transition
159 to a sleep state if any wakeup events are reported after the 159 to a sleep state if any wakeup events are reported after the
160 write has returned. 160 write has returned.
161
162What: /sys/power/reserved_size
163Date: May 2011
164Contact: Rafael J. Wysocki <rjw@sisk.pl>
165Description:
166 The /sys/power/reserved_size file allows user space to control
167 the amount of memory reserved for allocations made by device
168 drivers during the "device freeze" stage of hibernation. It can
169 be written a string representing a non-negative integer that
170 will be used as the amount of memory to reserve for allocations
171 made by device drivers' "freeze" callbacks, in bytes.
172
173 Reading from this file will display the current value, which is
174 set to 1 MB by default.
diff --git a/Documentation/feature-removal-schedule.txt b/Documentation/feature-removal-schedule.txt
index 492e81df2968..f6a24e8aa11e 100644
--- a/Documentation/feature-removal-schedule.txt
+++ b/Documentation/feature-removal-schedule.txt
@@ -460,14 +460,6 @@ Who: Thomas Gleixner <tglx@linutronix.de>
460 460
461---------------------------- 461----------------------------
462 462
463What: The acpi_sleep=s4_nonvs command line option
464When: 2.6.37
465Files: arch/x86/kernel/acpi/sleep.c
466Why: superseded by acpi_sleep=nonvs
467Who: Rafael J. Wysocki <rjw@sisk.pl>
468
469----------------------------
470
471What: PCI DMA unmap state API 463What: PCI DMA unmap state API
472When: August 2012 464When: August 2012
473Why: PCI DMA unmap state API (include/linux/pci-dma.h) was replaced 465Why: PCI DMA unmap state API (include/linux/pci-dma.h) was replaced
diff --git a/Documentation/kernel-parameters.txt b/Documentation/kernel-parameters.txt
index cc85a9278190..259037b873b7 100644
--- a/Documentation/kernel-parameters.txt
+++ b/Documentation/kernel-parameters.txt
@@ -245,7 +245,7 @@ bytes respectively. Such letter suffixes can also be entirely omitted.
245 245
246 acpi_sleep= [HW,ACPI] Sleep options 246 acpi_sleep= [HW,ACPI] Sleep options
247 Format: { s3_bios, s3_mode, s3_beep, s4_nohwsig, 247 Format: { s3_bios, s3_mode, s3_beep, s4_nohwsig,
248 old_ordering, s4_nonvs, sci_force_enable } 248 old_ordering, nonvs, sci_force_enable }
249 See Documentation/power/video.txt for information on 249 See Documentation/power/video.txt for information on
250 s3_bios and s3_mode. 250 s3_bios and s3_mode.
251 s3_beep is for debugging; it makes the PC's speaker beep 251 s3_beep is for debugging; it makes the PC's speaker beep
diff --git a/Documentation/power/devices.txt b/Documentation/power/devices.txt
index 1971bcf48a60..88880839ece4 100644
--- a/Documentation/power/devices.txt
+++ b/Documentation/power/devices.txt
@@ -279,11 +279,15 @@ When the system goes into the standby or memory sleep state, the phases are:
279 time.) Unlike the other suspend-related phases, during the prepare 279 time.) Unlike the other suspend-related phases, during the prepare
280 phase the device tree is traversed top-down. 280 phase the device tree is traversed top-down.
281 281
282 The prepare phase uses only a bus callback. After the callback method 282 In addition to that, if device drivers need to allocate additional
283 returns, no new children may be registered below the device. The method 283 memory to be able to hadle device suspend correctly, that should be
284 may also prepare the device or driver in some way for the upcoming 284 done in the prepare phase.
285 system power transition, but it should not put the device into a 285
286 low-power state. 286 After the prepare callback method returns, no new children may be
287 registered below the device. The method may also prepare the device or
288 driver in some way for the upcoming system power transition (for
289 example, by allocating additional memory required for this purpose), but
290 it should not put the device into a low-power state.
287 291
288 2. The suspend methods should quiesce the device to stop it from performing 292 2. The suspend methods should quiesce the device to stop it from performing
289 I/O. They also may save the device registers and put it into the 293 I/O. They also may save the device registers and put it into the
diff --git a/Documentation/power/notifiers.txt b/Documentation/power/notifiers.txt
index cf980709122a..c2a4a346c0d9 100644
--- a/Documentation/power/notifiers.txt
+++ b/Documentation/power/notifiers.txt
@@ -1,46 +1,41 @@
1Suspend notifiers 1Suspend notifiers
2 (C) 2007 Rafael J. Wysocki <rjw@sisk.pl>, GPL 2 (C) 2007-2011 Rafael J. Wysocki <rjw@sisk.pl>, GPL
3 3
4There are some operations that device drivers may want to carry out in their 4There are some operations that subsystems or drivers may want to carry out
5.suspend() routines, but shouldn't, because they can cause the hibernation or 5before hibernation/suspend or after restore/resume, but they require the system
6suspend to fail. For example, a driver may want to allocate a substantial amount 6to be fully functional, so the drivers' and subsystems' .suspend() and .resume()
7of memory (like 50 MB) in .suspend(), but that shouldn't be done after the 7or even .prepare() and .complete() callbacks are not suitable for this purpose.
8swsusp's memory shrinker has run. 8For example, device drivers may want to upload firmware to their devices after
9 9resume/restore, but they cannot do it by calling request_firmware() from their
10Also, there may be some operations, that subsystems want to carry out before a 10.resume() or .complete() routines (user land processes are frozen at these
11hibernation/suspend or after a restore/resume, requiring the system to be fully 11points). The solution may be to load the firmware into memory before processes
12functional, so the drivers' .suspend() and .resume() routines are not suitable 12are frozen and upload it from there in the .resume() routine.
13for this purpose. For example, device drivers may want to upload firmware to 13A suspend/hibernation notifier may be used for this purpose.
14their devices after a restore from a hibernation image, but they cannot do it by 14
15calling request_firmware() from their .resume() routines (user land processes 15The subsystems or drivers having such needs can register suspend notifiers that
16are frozen at this point). The solution may be to load the firmware into 16will be called upon the following events by the PM core:
17memory before processes are frozen and upload it from there in the .resume()
18routine. Of course, a hibernation notifier may be used for this purpose.
19
20The subsystems that have such needs can register suspend notifiers that will be
21called upon the following events by the suspend core:
22 17
23PM_HIBERNATION_PREPARE The system is going to hibernate or suspend, tasks will 18PM_HIBERNATION_PREPARE The system is going to hibernate or suspend, tasks will
24 be frozen immediately. 19 be frozen immediately.
25 20
26PM_POST_HIBERNATION The system memory state has been restored from a 21PM_POST_HIBERNATION The system memory state has been restored from a
27 hibernation image or an error occurred during the 22 hibernation image or an error occurred during
28 hibernation. Device drivers' .resume() callbacks have 23 hibernation. Device drivers' restore callbacks have
29 been executed and tasks have been thawed. 24 been executed and tasks have been thawed.
30 25
31PM_RESTORE_PREPARE The system is going to restore a hibernation image. 26PM_RESTORE_PREPARE The system is going to restore a hibernation image.
32 If all goes well the restored kernel will issue a 27 If all goes well, the restored kernel will issue a
33 PM_POST_HIBERNATION notification. 28 PM_POST_HIBERNATION notification.
34 29
35PM_POST_RESTORE An error occurred during the hibernation restore. 30PM_POST_RESTORE An error occurred during restore from hibernation.
36 Device drivers' .resume() callbacks have been executed 31 Device drivers' restore callbacks have been executed
37 and tasks have been thawed. 32 and tasks have been thawed.
38 33
39PM_SUSPEND_PREPARE The system is preparing for a suspend. 34PM_SUSPEND_PREPARE The system is preparing for suspend.
40 35
41PM_POST_SUSPEND The system has just resumed or an error occurred during 36PM_POST_SUSPEND The system has just resumed or an error occurred during
42 the suspend. Device drivers' .resume() callbacks have 37 suspend. Device drivers' resume callbacks have been
43 been executed and tasks have been thawed. 38 executed and tasks have been thawed.
44 39
45It is generally assumed that whatever the notifiers do for 40It is generally assumed that whatever the notifiers do for
46PM_HIBERNATION_PREPARE, should be undone for PM_POST_HIBERNATION. Analogously, 41PM_HIBERNATION_PREPARE, should be undone for PM_POST_HIBERNATION. Analogously,