xref: /linux-6.15/kernel/power/Kconfig (revision c2ff18f4)
11da177e4SLinus Torvaldsconfig PM
21da177e4SLinus Torvalds	bool "Power Management support"
31da177e4SLinus Torvalds	---help---
41da177e4SLinus Torvalds	  "Power Management" means that parts of your computer are shut
51da177e4SLinus Torvalds	  off or put into a power conserving "sleep" mode if they are not
61da177e4SLinus Torvalds	  being used.  There are two competing standards for doing this: APM
71da177e4SLinus Torvalds	  and ACPI.  If you want to use either one, say Y here and then also
81da177e4SLinus Torvalds	  to the requisite support below.
91da177e4SLinus Torvalds
101da177e4SLinus Torvalds	  Power Management is most important for battery powered laptop
111da177e4SLinus Torvalds	  computers; if you have a laptop, check out the Linux Laptop home
121da177e4SLinus Torvalds	  page on the WWW at <http://www.linux-on-laptops.com/> or
131da177e4SLinus Torvalds	  Tuxmobil - Linux on Mobile Computers at <http://www.tuxmobil.org/>
141da177e4SLinus Torvalds	  and the Battery Powered Linux mini-HOWTO, available from
151da177e4SLinus Torvalds	  <http://www.tldp.org/docs.html#howto>.
161da177e4SLinus Torvalds
171da177e4SLinus Torvalds	  Note that, even if you say N here, Linux on the x86 architecture
181da177e4SLinus Torvalds	  will issue the hlt instruction if nothing is to be done, thereby
191da177e4SLinus Torvalds	  sending the processor to sleep and saving power.
201da177e4SLinus Torvalds
211da177e4SLinus Torvaldsconfig PM_DEBUG
221da177e4SLinus Torvalds	bool "Power Management Debug Support"
231da177e4SLinus Torvalds	depends on PM
241da177e4SLinus Torvalds	---help---
251da177e4SLinus Torvalds	This option enables verbose debugging support in the Power Management
261da177e4SLinus Torvalds	code. This is helpful when debugging and reporting various PM bugs,
271da177e4SLinus Torvalds	like suspend support.
281da177e4SLinus Torvalds
291da177e4SLinus Torvaldsconfig SOFTWARE_SUSPEND
3019c32439SPavel Machek	bool "Software Suspend"
3119c32439SPavel Machek	depends on EXPERIMENTAL && PM && SWAP && ((X86 && SMP) || ((FVR || PPC32 || X86) && !SMP))
321da177e4SLinus Torvalds	---help---
331da177e4SLinus Torvalds	  Enable the possibility of suspending the machine.
341da177e4SLinus Torvalds	  It doesn't need APM.
351da177e4SLinus Torvalds	  You may suspend your machine by 'swsusp' or 'shutdown -z <time>'
361da177e4SLinus Torvalds	  (patch for sysvinit needed).
371da177e4SLinus Torvalds
381da177e4SLinus Torvalds	  It creates an image which is saved in your active swap. Upon next
391da177e4SLinus Torvalds	  boot, pass the 'resume=/dev/swappartition' argument to the kernel to
401da177e4SLinus Torvalds	  have it detect the saved image, restore memory state from it, and
411da177e4SLinus Torvalds	  continue to run as before. If you do not want the previous state to
421da177e4SLinus Torvalds	  be reloaded, then use the 'noresume' kernel argument. However, note
431da177e4SLinus Torvalds	  that your partitions will be fsck'd and you must re-mkswap your swap
441da177e4SLinus Torvalds	  partitions. It does not work with swap files.
451da177e4SLinus Torvalds
461da177e4SLinus Torvalds	  Right now you may boot without resuming and then later resume but
471da177e4SLinus Torvalds	  in meantime you cannot use those swap partitions/files which were
481da177e4SLinus Torvalds	  involved in suspending. Also in this case there is a risk that buffers
491da177e4SLinus Torvalds	  on disk won't match with saved ones.
501da177e4SLinus Torvalds
511da177e4SLinus Torvalds	  For more information take a look at <file:Documentation/power/swsusp.txt>.
521da177e4SLinus Torvalds
531da177e4SLinus Torvaldsconfig PM_STD_PARTITION
541da177e4SLinus Torvalds	string "Default resume partition"
551da177e4SLinus Torvalds	depends on SOFTWARE_SUSPEND
561da177e4SLinus Torvalds	default ""
571da177e4SLinus Torvalds	---help---
581da177e4SLinus Torvalds	  The default resume partition is the partition that the suspend-
591da177e4SLinus Torvalds	  to-disk implementation will look for a suspended disk image.
601da177e4SLinus Torvalds
611da177e4SLinus Torvalds	  The partition specified here will be different for almost every user.
621da177e4SLinus Torvalds	  It should be a valid swap partition (at least for now) that is turned
631da177e4SLinus Torvalds	  on before suspending.
641da177e4SLinus Torvalds
651da177e4SLinus Torvalds	  The partition specified can be overridden by specifying:
661da177e4SLinus Torvalds
671da177e4SLinus Torvalds		resume=/dev/<other device>
681da177e4SLinus Torvalds
691da177e4SLinus Torvalds	  which will set the resume partition to the device specified.
701da177e4SLinus Torvalds
711da177e4SLinus Torvalds	  Note there is currently not a way to specify which device to save the
721da177e4SLinus Torvalds	  suspended image to. It will simply pick the first available swap
731da177e4SLinus Torvalds	  device.
741da177e4SLinus Torvalds
75*c2ff18f4SAndreas Steinmetzconfig SWSUSP_ENCRYPT
76*c2ff18f4SAndreas Steinmetz	bool "Encrypt suspend image"
77*c2ff18f4SAndreas Steinmetz	depends on SOFTWARE_SUSPEND && CRYPTO=y && (CRYPTO_AES=y || CRYPTO_AES_586=y || CRYPTO_AES_X86_64=y)
78*c2ff18f4SAndreas Steinmetz	default ""
79*c2ff18f4SAndreas Steinmetz	---help---
80*c2ff18f4SAndreas Steinmetz	  To prevent data gathering from swap after resume you can encrypt
81*c2ff18f4SAndreas Steinmetz	  the suspend image with a temporary key that is deleted on
82*c2ff18f4SAndreas Steinmetz	  resume.
83*c2ff18f4SAndreas Steinmetz
84*c2ff18f4SAndreas Steinmetz	  Note that the temporary key is stored unencrypted on disk while the
85*c2ff18f4SAndreas Steinmetz	  system is suspended.
86*c2ff18f4SAndreas Steinmetz
875a72e04dSLi Shaohuaconfig SUSPEND_SMP
885a72e04dSLi Shaohua	bool
895a72e04dSLi Shaohua	depends on HOTPLUG_CPU && X86 && PM
905a72e04dSLi Shaohua	default y
91