xref: /linux/Documentation/ABI/testing/sysfs-class-reboot-mode-reboot_modes (revision 7c700dcd74640b9f0f5eaafdc6fdc4d5741666e2)
1What:		/sys/class/reboot-mode/<driver>/reboot_modes
2Date:		March 2026(TBD)
3KernelVersion:	TBD
4Contact:	linux-pm@vger.kernel.org
5Description:
6		This interface exposes the reboot-mode arguments
7		registered with the reboot-mode framework. It is
8		a read-only interface and provides a space
9		separated list of reboot-mode arguments supported
10		on the current platform.
11		Example:
12
13		 recovery fastboot bootloader
14
15		The exact sysfs path may vary depending on the
16		name of the driver that registers the arguments.
17		Example::
18
19		 /sys/class/reboot-mode/nvmem-reboot-mode/reboot_modes
20		 /sys/class/reboot-mode/syscon-reboot-mode/reboot_modes
21		 /sys/class/reboot-mode/qcom-pon/reboot_modes
22
23		The supported arguments can be used by userspace to
24		invoke device reset using the standard reboot() system
25		call interface, with the "argument" as string to ``*arg``
26		parameter along with ``LINUX_REBOOT_CMD_RESTART2``.
27
28		A driver can expose the supported arguments by
29		registering them with the reboot-mode framework
30		using the property names that follow the
31		mode-<argument> format.
32		Example:
33
34		 mode-bootloader, mode-recovery
35
36		This attribute is useful for scripts or initramfs
37		logic that need to programmatically determine
38		which reboot-mode arguments are valid before
39		triggering a reboot.
40