11da177e4SLinus Torvaldsconfig PM 21da177e4SLinus Torvalds bool "Power Management support" 3eb7b6b32SLen Brown depends on !IA64_HP_SIM 41da177e4SLinus Torvalds ---help--- 51da177e4SLinus Torvalds "Power Management" means that parts of your computer are shut 61da177e4SLinus Torvalds off or put into a power conserving "sleep" mode if they are not 71da177e4SLinus Torvalds being used. There are two competing standards for doing this: APM 81da177e4SLinus Torvalds and ACPI. If you want to use either one, say Y here and then also 91da177e4SLinus Torvalds to the requisite support below. 101da177e4SLinus Torvalds 111da177e4SLinus Torvalds Power Management is most important for battery powered laptop 121da177e4SLinus Torvalds computers; if you have a laptop, check out the Linux Laptop home 131da177e4SLinus Torvalds page on the WWW at <http://www.linux-on-laptops.com/> or 141da177e4SLinus Torvalds Tuxmobil - Linux on Mobile Computers at <http://www.tuxmobil.org/> 151da177e4SLinus Torvalds and the Battery Powered Linux mini-HOWTO, available from 161da177e4SLinus Torvalds <http://www.tldp.org/docs.html#howto>. 171da177e4SLinus Torvalds 181da177e4SLinus Torvalds Note that, even if you say N here, Linux on the x86 architecture 191da177e4SLinus Torvalds will issue the hlt instruction if nothing is to be done, thereby 201da177e4SLinus Torvalds sending the processor to sleep and saving power. 211da177e4SLinus Torvalds 22bca73e4bSJeff Garzikconfig PM_LEGACY 23f89bce3dSDavid Brownell bool "Legacy Power Management API (DEPRECATED)" 24bca73e4bSJeff Garzik depends on PM 25f89bce3dSDavid Brownell default n 26bca73e4bSJeff Garzik ---help--- 27f89bce3dSDavid Brownell Support for pm_register() and friends. This old API is obsoleted 28f89bce3dSDavid Brownell by the driver model. 29bca73e4bSJeff Garzik 30f89bce3dSDavid Brownell If unsure, say N. 31bca73e4bSJeff Garzik 321da177e4SLinus Torvaldsconfig PM_DEBUG 331da177e4SLinus Torvalds bool "Power Management Debug Support" 341da177e4SLinus Torvalds depends on PM 351da177e4SLinus Torvalds ---help--- 36a0349828SBen Collins This option enables various debugging support in the Power Management 37a0349828SBen Collins code. This is helpful when debugging and reporting PM bugs, like 38a0349828SBen Collins suspend support. 39a0349828SBen Collins 40a0349828SBen Collinsconfig PM_VERBOSE 41a0349828SBen Collins bool "Verbose Power Management debugging" 42a0349828SBen Collins depends on PM_DEBUG 43a0349828SBen Collins default n 44a0349828SBen Collins ---help--- 45a0349828SBen Collins This option enables verbose messages from the Power Management code. 461da177e4SLinus Torvalds 47*90dda1cbSJohannes Bergconfig CAN_PM_TRACE 48*90dda1cbSJohannes Berg def_bool y 49*90dda1cbSJohannes Berg depends on PM_DEBUG && PM_SLEEP && EXPERIMENTAL 50*90dda1cbSJohannes Berg 51eb71c87aSLinus Torvaldsconfig PM_TRACE 52*90dda1cbSJohannes Berg bool 53*90dda1cbSJohannes Berg help 54*90dda1cbSJohannes Berg This enables code to save the last PM event point across 55*90dda1cbSJohannes Berg reboot. The architecture needs to support this, x86 for 56*90dda1cbSJohannes Berg example does by saving things in the RTC, see below. 57*90dda1cbSJohannes Berg 58*90dda1cbSJohannes Berg The architecture specific code must provide the extern 59*90dda1cbSJohannes Berg functions from <linux/resume-trace.h> as well as the 60*90dda1cbSJohannes Berg <asm/resume-trace.h> header with a TRACE_RESUME() macro. 61*90dda1cbSJohannes Berg 62*90dda1cbSJohannes Berg The way the information is presented is architecture- 63*90dda1cbSJohannes Berg dependent, x86 will print the information during a 64*90dda1cbSJohannes Berg late_initcall. 65*90dda1cbSJohannes Berg 66*90dda1cbSJohannes Bergconfig PM_TRACE_RTC 67eb71c87aSLinus Torvalds bool "Suspend/resume event tracing" 68*90dda1cbSJohannes Berg depends on CAN_PM_TRACE 69*90dda1cbSJohannes Berg depends on X86 70*90dda1cbSJohannes Berg select PM_TRACE 715c31f273SAndrew Morton default n 72eb71c87aSLinus Torvalds ---help--- 73eb71c87aSLinus Torvalds This enables some cheesy code to save the last PM event point in the 74eb71c87aSLinus Torvalds RTC across reboots, so that you can debug a machine that just hangs 75eb71c87aSLinus Torvalds during suspend (or more commonly, during resume). 76eb71c87aSLinus Torvalds 775c31f273SAndrew Morton To use this debugging feature you should attempt to suspend the machine, 785c31f273SAndrew Morton then reboot it, then run 795c31f273SAndrew Morton 805c31f273SAndrew Morton dmesg -s 1000000 | grep 'hash matches' 815c31f273SAndrew Morton 825c31f273SAndrew Morton CAUTION: this option will cause your machine's real-time clock to be 835c31f273SAndrew Morton set to an invalid time after a resume. 845c31f273SAndrew Morton 85f3de4be9SRafael J. Wysockiconfig PM_SLEEP_SMP 86296699deSRafael J. Wysocki bool 87f3de4be9SRafael J. Wysocki depends on SUSPEND_SMP_POSSIBLE || HIBERNATION_SMP_POSSIBLE 88f3de4be9SRafael J. Wysocki depends on PM_SLEEP 89296699deSRafael J. Wysocki select HOTPLUG_CPU 90296699deSRafael J. Wysocki default y 91296699deSRafael J. Wysocki 92296699deSRafael J. Wysockiconfig PM_SLEEP 93296699deSRafael J. Wysocki bool 94296699deSRafael J. Wysocki depends on SUSPEND || HIBERNATION 95296699deSRafael J. Wysocki default y 96296699deSRafael J. Wysocki 97f3de4be9SRafael J. Wysockiconfig SUSPEND_UP_POSSIBLE 98f3de4be9SRafael J. Wysocki bool 99f3de4be9SRafael J. Wysocki depends on (X86 && !X86_VOYAGER) || PPC || ARM || BLACKFIN || MIPS \ 100f3de4be9SRafael J. Wysocki || SUPERH || FRV 101f3de4be9SRafael J. Wysocki depends on !SMP 102f3de4be9SRafael J. Wysocki default y 103f3de4be9SRafael J. Wysocki 104f3de4be9SRafael J. Wysockiconfig SUSPEND_SMP_POSSIBLE 105f3de4be9SRafael J. Wysocki bool 106f3de4be9SRafael J. Wysocki depends on (X86 && !X86_VOYAGER) \ 107f3de4be9SRafael J. Wysocki || (PPC && (PPC_PSERIES || PPC_PMAC)) || ARM 108f3de4be9SRafael J. Wysocki depends on SMP 109f3de4be9SRafael J. Wysocki default y 110f3de4be9SRafael J. Wysocki 111296699deSRafael J. Wysockiconfig SUSPEND 112296699deSRafael J. Wysocki bool "Suspend to RAM and standby" 113296699deSRafael J. Wysocki depends on PM 114f3de4be9SRafael J. Wysocki depends on SUSPEND_UP_POSSIBLE || SUSPEND_SMP_POSSIBLE 115296699deSRafael J. Wysocki default y 116296699deSRafael J. Wysocki ---help--- 117296699deSRafael J. Wysocki Allow the system to enter sleep states in which main memory is 118296699deSRafael J. Wysocki powered and thus its contents are preserved, such as the 119296699deSRafael J. Wysocki suspend-to-RAM state (i.e. the ACPI S3 state). 120296699deSRafael J. Wysocki 121f3de4be9SRafael J. Wysockiconfig HIBERNATION_UP_POSSIBLE 122f3de4be9SRafael J. Wysocki bool 123459685c7SAl Viro depends on X86 || PPC64_SWSUSP || PPC32 124f3de4be9SRafael J. Wysocki depends on !SMP 125f3de4be9SRafael J. Wysocki default y 126f3de4be9SRafael J. Wysocki 127f3de4be9SRafael J. Wysockiconfig HIBERNATION_SMP_POSSIBLE 128f3de4be9SRafael J. Wysocki bool 129f3de4be9SRafael J. Wysocki depends on (X86 && !X86_VOYAGER) || PPC64_SWSUSP 130f3de4be9SRafael J. Wysocki depends on SMP 131f3de4be9SRafael J. Wysocki default y 132f3de4be9SRafael J. Wysocki 133b0cb1a19SRafael J. Wysockiconfig HIBERNATION 134296699deSRafael J. Wysocki bool "Hibernation (aka 'suspend to disk')" 135296699deSRafael J. Wysocki depends on PM && SWAP 136f3de4be9SRafael J. Wysocki depends on HIBERNATION_UP_POSSIBLE || HIBERNATION_SMP_POSSIBLE 1371da177e4SLinus Torvalds ---help--- 138a7ee2e5fSDavid Brownell Enable the suspend to disk (STD) functionality, which is usually 139a7ee2e5fSDavid Brownell called "hibernation" in user interfaces. STD checkpoints the 140a7ee2e5fSDavid Brownell system and powers it off; and restores that checkpoint on reboot. 1411da177e4SLinus Torvalds 142c7276fdeSRafael J. Wysocki You can suspend your machine with 'echo disk > /sys/power/state'. 143c7276fdeSRafael J. Wysocki Alternatively, you can use the additional userland tools available 144c7276fdeSRafael J. Wysocki from <http://suspend.sf.net>. 145c7276fdeSRafael J. Wysocki 146c7276fdeSRafael J. Wysocki In principle it does not require ACPI or APM, although for example 147a7ee2e5fSDavid Brownell ACPI will be used for the final steps when it is available. One 148a7ee2e5fSDavid Brownell of the reasons to use software suspend is that the firmware hooks 149a7ee2e5fSDavid Brownell for suspend states like suspend-to-RAM (STR) often don't work very 150a7ee2e5fSDavid Brownell well with Linux. 151c7276fdeSRafael J. Wysocki 152c7276fdeSRafael J. Wysocki It creates an image which is saved in your active swap. Upon the next 1531da177e4SLinus Torvalds boot, pass the 'resume=/dev/swappartition' argument to the kernel to 1541da177e4SLinus Torvalds have it detect the saved image, restore memory state from it, and 1551da177e4SLinus Torvalds continue to run as before. If you do not want the previous state to 156c7276fdeSRafael J. Wysocki be reloaded, then use the 'noresume' kernel command line argument. 157c7276fdeSRafael J. Wysocki Note, however, that fsck will be run on your filesystems and you will 158c7276fdeSRafael J. Wysocki need to run mkswap against the swap partition used for the suspend. 1591da177e4SLinus Torvalds 160c7276fdeSRafael J. Wysocki It also works with swap files to a limited extent (for details see 161c7276fdeSRafael J. Wysocki <file:Documentation/power/swsusp-and-swap-files.txt>). 162c7276fdeSRafael J. Wysocki 163c7276fdeSRafael J. Wysocki Right now you may boot without resuming and resume later but in the 164c7276fdeSRafael J. Wysocki meantime you cannot use the swap partition(s)/file(s) involved in 165c7276fdeSRafael J. Wysocki suspending. Also in this case you must not use the filesystems 166c7276fdeSRafael J. Wysocki that were mounted before the suspend. In particular, you MUST NOT 167c7276fdeSRafael J. Wysocki MOUNT any journaled filesystems mounted before the suspend or they 168c7276fdeSRafael J. Wysocki will get corrupted in a nasty way. 1691da177e4SLinus Torvalds 1701da177e4SLinus Torvalds For more information take a look at <file:Documentation/power/swsusp.txt>. 1711da177e4SLinus Torvalds 1721da177e4SLinus Torvaldsconfig PM_STD_PARTITION 1731da177e4SLinus Torvalds string "Default resume partition" 174b0cb1a19SRafael J. Wysocki depends on HIBERNATION 1751da177e4SLinus Torvalds default "" 1761da177e4SLinus Torvalds ---help--- 1771da177e4SLinus Torvalds The default resume partition is the partition that the suspend- 1781da177e4SLinus Torvalds to-disk implementation will look for a suspended disk image. 1791da177e4SLinus Torvalds 1801da177e4SLinus Torvalds The partition specified here will be different for almost every user. 1811da177e4SLinus Torvalds It should be a valid swap partition (at least for now) that is turned 1821da177e4SLinus Torvalds on before suspending. 1831da177e4SLinus Torvalds 1841da177e4SLinus Torvalds The partition specified can be overridden by specifying: 1851da177e4SLinus Torvalds 1861da177e4SLinus Torvalds resume=/dev/<other device> 1871da177e4SLinus Torvalds 1881da177e4SLinus Torvalds which will set the resume partition to the device specified. 1891da177e4SLinus Torvalds 1901da177e4SLinus Torvalds Note there is currently not a way to specify which device to save the 1911da177e4SLinus Torvalds suspended image to. It will simply pick the first available swap 1921da177e4SLinus Torvalds device. 1931da177e4SLinus Torvalds 1947726942fSRalf Baechleconfig APM_EMULATION 1957726942fSRalf Baechle tristate "Advanced Power Management Emulation" 1967726942fSRalf Baechle depends on PM && SYS_SUPPORTS_APM_EMULATION 1977726942fSRalf Baechle help 1987726942fSRalf Baechle APM is a BIOS specification for saving power using several different 1997726942fSRalf Baechle techniques. This is mostly useful for battery powered laptops with 2007726942fSRalf Baechle APM compliant BIOSes. If you say Y here, the system time will be 2017726942fSRalf Baechle reset after a RESUME operation, the /proc/apm device will provide 2027726942fSRalf Baechle battery status information, and user-space programs will receive 2037726942fSRalf Baechle notification of APM "events" (e.g. battery status change). 2047726942fSRalf Baechle 2057726942fSRalf Baechle In order to use APM, you will need supporting software. For location 2067726942fSRalf Baechle and more information, read <file:Documentation/pm.txt> and the 2077726942fSRalf Baechle Battery Powered Linux mini-HOWTO, available from 2087726942fSRalf Baechle <http://www.tldp.org/docs.html#howto>. 2097726942fSRalf Baechle 2107726942fSRalf Baechle This driver does not spin down disk drives (see the hdparm(8) 2117726942fSRalf Baechle manpage ("man 8 hdparm") for that), and it doesn't turn off 2127726942fSRalf Baechle VESA-compliant "green" monitors. 2137726942fSRalf Baechle 2147726942fSRalf Baechle Generally, if you don't have a battery in your machine, there isn't 2157726942fSRalf Baechle much point in using this driver and you should say N. If you get 2167726942fSRalf Baechle random kernel OOPSes or reboots that don't seem to be related to 2177726942fSRalf Baechle anything, try disabling/enabling this option (or disabling/enabling 2187726942fSRalf Baechle APM in your BIOS). 219