]> git.ipfire.org Git - thirdparty/systemd.git/blame - src/shared/reboot-util.h
hwdb: Add mapping for Xiaomi Mipad 2 bottom bezel capacitive buttons
[thirdparty/systemd.git] / src / shared / reboot-util.h
CommitLineData
db9ecf05 1/* SPDX-License-Identifier: LGPL-2.1-or-later */
e3631d1c
LP
2#pragma once
3
b7ad4778 4bool reboot_parameter_is_valid(const char *parameter);
77defcf5 5int update_reboot_parameter_and_warn(const char *parameter, bool keep);
c01dcddf
LP
6
7typedef enum RebootFlags {
ef31828d
LP
8 REBOOT_LOG = 1 << 0, /* log about what we are going to do and all errors */
9 REBOOT_DRY_RUN = 1 << 1, /* return 0 right before actually doing the reboot */
2aed63f4 10 REBOOT_FALLBACK = 1 << 2, /* fall back to plain reboot() if argument-based reboot doesn't work, isn't configured or doesn't apply otherwise */
c01dcddf
LP
11} RebootFlags;
12
428b296a 13int read_reboot_parameter(char **parameter);
c01dcddf 14int reboot_with_parameter(RebootFlags flags);
2bfa8466 15
022a19c9 16bool shall_restore_state(void);
ede5a78f
ST
17
18bool kexec_loaded(void);