pub/scm/linux/kernel/git/rafael/suspend-utils.git  about / heads / tags
Suspend and hibernation utilities - s2ram, s2disk, s2both
$ git log --pretty=format:'%h %s (%cs)%d'
668c5f7 config_parser: parse_line() must not return EINVAL for unknown strings (2012-09-15)
	(HEAD -> master)
f599326 s2disk: Format strings in printf (2012-09-15)
d03e448 manpages: Manpages added (2012-09-15)
00ded77 README: README file updated with new options (2012-09-15)
f58e334 s2ram: Added command line option -? (revert 1a6e6d9) (2012-09-15)
a9383c1 s2ram: New argument -K to check kernel KMS support (2012-09-15)
ce965ec s2ram: Code clean in s2ram-main.c (2012-09-15)
fbb09c9 s2ram / s2both: Warning removed unused label (2012-02-27)
f63b384 s2ram: Support quirks from configuration file (2012-02-27)
2cbc54e suspend.c: Remove verbose warning for deprecated ioctls (2012-02-27)
...

$ git cat-file blob HEAD:README
Userland support for suspend
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Copyright (C) 2005 Rafael J. Wysocki <rjw@sisk.pl>
Copyright (C) 2006 Pavel Machek <pavel@suse.cz>

This package contains some userland tools allowing you to suspend a Linux
system either to disk or to RAM.  These tools provide some capabilities
that are not available in the vanilla Linux kernel.

The suspend to disk can be carried out with the help of s2disk and resume
utilities which use the software suspend userland interface available in
the Linux kernel 2.6.17 or above.  Among other things, they provide the
following features:

- suspend image checksumming
- suspend image compression
- suspend image encryption
- (limited) support for splash screens and graphical progress meters

that are not provided by the in-kernel software suspend code (swsusp).
Please refer to the HOWTO document in this package for more information about
these utilities and installation instructions.

The s2ram tool allows you to suspend the system to RAM and restore the state
of the graphics adapter after the resume automatically.  For this purpose it
uses the code out of vbetool and radeontool utilities, needed for handling
quite a lot of graphics cards after the resume from RAM. The s2ram tool uses
three different methods to suspend the machine:

- KMS: s2ram try first suspend the machine using KMS (Kernel Mode Set) if the
  kernel supports it. With this method s2ram don't need extra parameters
  (quirks).
- Whitelist: s2ram has a whitelist of machines that are known to work with it.
  This whitelist includes the quirks to suspend known machines. The whitelist
  was used prior to suspend-utils version 1.0, and now the whitelist is not
  updated. The database is used because has a lot of machines included and
  many users are using it. Please refer to the document README.s2ram-whitelist
  in this package for more information about the s2ram whitelist.
- Configuration file: s2ram can use the configuration file to read the extra
  parameters (quirks). This option is useful if the kernel don't support KMS
  (for example, kernel compiled without support), if the machine is not
  included in the whitelist (for example, new machines) or if the user wants
  to override the quirks of the whitelist file.

The flow of options is:

1. If the kernel supports KMS, then use it. This option can be overriding
   using the argument "-k" in s2ram (s2ram -k).
2. If the kernel don't support KMS, or the user override it, then s2ram
   checks if the configuration file has the parameters. If the parameters
   are included, s2ram use them, else, the whitelist is used.

You need libx86 installed to build s2ram, the HOWTO document explains how to
install it.

The s2both tool combines the functionalities of s2disk and s2ram.  With the
help of it the system may be suspended to RAM after the suspend-to-disk
image has been created instead of being powered off.  Then, if there's enough
battery power, you can resume from RAM and discard the saved image, or you
can resume the system from disk using the resume tool otherwise  However, this
is only possible if your box is present in the s2ram whitelist.

To build the s2ram and s2both tools you will need the pciutils-devel
(pciutils-dev) package and the libx86-dev package (which you can get from 
http://www.codon.org.uk/~mjg59/libx86/downloads/). They are necessary to 
compile the vbetool code (the vbetool code is based on vbetool-1.0 from 
http://www.codon.org.uk/~mjg59/vbetool/). With newer pciutils (2.2.4 and
above) you also have to install the zlib development package (zlib-devel on
SUSE, zlib1g-dev on Debian).

For debugging, see http://suspend.sf.net/s2ram-support.html.

acpi-support package from Ubuntu has *very* long whitelist of machines: 
http://packages.ubuntu.org.cn/dapper/admin/acpi-support that are likely to
work with s2ram.

To compile this beast from CVS, do:

./autogen.sh
./configure
make

# heads (aka `branches'):
$ git for-each-ref --sort=-creatordate refs/heads \
	--format='%(HEAD) %(refname:short) %(subject) (%(creatordate:short))'
* master       config_parser: parse_line() must not return EINVAL for unknown strings (2012-09-15)

# tags:
$ git for-each-ref --sort=-creatordate refs/tags \
	--format='%(refname:short) %(subject) (%(creatordate:short))'
# no tags, yet...

# associated public inboxes:
# (number on the left is used for dev purposes)
         11 lkml
          5 kvm
          4 linux-nfs
          4 linux-fsdevel
          4 dpdk-dev
          4 linuxppc-dev
          3 linux-mm
          3 buildroot
          2 linux-xfs
          2 bpf
          2 linux-efi
          2 linux-acpi
          2 linux-integrity
          2 linux-cifs
          2 linux-devicetree
          2 netdev
          2 linux-pm
          2 linux-input
          2 linux-btrfs
          2 linux-arm-kernel
          2 linux-ext4
          2 linux-api
          2 lttng-dev
          2 ceph-devel
          2 platform-driver-x86
          2 linux-s390
          2 linux-coco
          2 u-boot
          1 linux-samsung-soc
          1 linux-fscrypt
          1 linux-wireless
          1 linux-mtd
          1 cocci
          1 linux-block
          1 linux-riscv
          1 linux-nvme
          1 live-patching
          1 qemu-devel
          1 linux-mediatek
          1 linux-crypto
          1 netfilter-devel
          1 linux-edac
          1 linux-arm-msm
          1 linux-amlogic
          1 linux-erofs
          1 linux-nvdimm
          1 linux-iommu
          1 linux-media
          1 xen-devel
          1 stable
          1 linux-snps-arc
          1 linux-mips
          1 fstests
          1 linux-hwmon
          1 linux-rtc
          1 alsa-devel
          1 linux-scsi
          1 kvmarm
          1 driverdev-devel
          1 linux-usb
          1 linux-renesas-soc
          1 linux-kselftest
          1 selinux
          1 kernel-hardening
          1 linux-clk
          1 linux-iio
          1 linux-gpio
          1 dmaengine
          1 linux-rdma
          1 linux-next
          1 linux-parisc
          1 linux-leds
          1 linux-security-module
          1 linux-pci
          1 linux-f2fs-devel
          1 linux-modules
          1 kernelnewbies
          1 linux-rt-users
          1 linux-bluetooth
          1 linux-sgx
          1 linux-ide
          1 linux-serial
          1 linux-watchdog
          1 linux-trace-devel
          1 linux-hyperv
          1 workflows
          1 rcu
          1 linux-m68k
          1 linux-i3c
          1 util-linux
          1 linux-spdx
          1 linux-wpan
          1 ksummit-discuss
          1 wireguard
          1 backports
          1 io-uring
          1 linux-kernel-mentees
          1 linux-doc
          1 git
          1 linux-csky
          1 linux-man
          1 linux-mmc
          1 amd-gfx
          1 dri-devel
          1 intel-gfx
          1 tpmdd-devel
          1 linux-unionfs
          1 linux-firmware
          1 cip-dev
          1 linux-omap
          1 linux-audit
          1 linux-spi
          1 linux-i2c
          1 linux-remoteproc
          1 linux-dash
          1 linux-bcache
          1 linux-sparse
          1 mm-commits
          1 linux-pwm
          1 linux-tegra
          1 virtualization
          1 linux-kbuild
          1 linux-fpga
          1 linux-arch
          1 linux-can
          1 containers
          1 linux-rockchip
          1 linux-raid
          1 xdp-newbies
          1 phone-devel
          1 openbmc
          1 linux-hardening
          1 dash
          1 dm-devel
          1 keyrings
          1 linux-fbdev
          1 linux-sctp
          1 linux-cxl
          1 linux-perf-users
          1 target-devel
          1 lustre-devel
          1 linux-sh
          1 soc
          1 ocfs2-devel
          1 rust-for-linux
          1 ath10k
          1 ath11k
          1 nouveau
          1 linux-phy
          1 kernel-janitors
          1 sparclinux
          1 linux-staging
          1 linux-sunxi
          1 mptcp
          1 regressions
          1 ksummit
          1 b43-dev
          1 nvdimm
          1 linux-nfc
          1 linux-bcachefs
          1 ath9k-devel
          1 ntfs3
          1 llvm
          1 fio
          1 iwd
          1 ell
          1 ofono
          1 ltp
          1 yocto
          1 yocto-meta-freescale
          1 openembedded-core
          1 yocto-toaster
          1 yocto-meta-arm
          1 yocto-docs
          1 openembedded-devel
          1 bitbake-devel
          1 linux-patches
          1 yocto-meta-virtualization
          1 chrome-platform
          1 ntb
          1 yocto-meta-ti
          1 yocto-meta-arago
          1 outreachy
          1 xenomai
          1 damon
          1 asahi
          1 openrisc
          1 intel-wired-lan
          1 kexec
          1 loongarch
          1 imx
          1 ath12k
          1 b4-sent
          1 linux-trace-kernel
          1 oe-linux-nfc
          1 oe-kbuild-all
          1 oe-chipsec
          1 batman
          1 intel-xe
          1 linux-um
          1 virtio-dev
          1 virtio-comment
          1 v9fs
          1 ecryptfs
          1 poky
          1 qemu-riscv
          1 linux-ia64
          1 cluster-devel
          1 grub-devel
          1 kbd
          1 autofs
          1 cpufreq
          1 dccp
          1 cgroups
          1 devicetree-spec
          1 devicetree-compiler
          1 initramfs
          1 kvm-ppc
          1 hail-devel
          1 kvm-ia64
          1 linux-8086
          1 kernel-testers
          1 linux-alpha
          1 linux-btrace
          1 linux-embedded
          1 linux-hams
          1 linux-hexagon
          1 linux-hotplug
          1 linux-laptop
          1 linux-sound
          1 trinity
          1 reiserfs-devel
          1 linux-metag
          1 linux-x25
          1 linux-nilfs
          1 lvs-devel
          1 netfilter
          1 linux-oxnas
          1 u-boot-amlogic
          1 lm-sensors
          1 lvm-devel
          1 acpica-devel
          1 perfbook
          1 virtio-fs
          1 smatch
          1 ../../../../../../../fuego
          1 ../../../../../../../wireless-regdb
          1 ../../../../../../../igt-dev
          1 ../../../../../../../powertop

git clone https://80x24.org/lore/pub/scm/linux/kernel/git/rafael/suspend-utils.git