]>
Commit | Line | Data |
---|---|---|
db9ecf05 | 1 | /* SPDX-License-Identifier: LGPL-2.1-or-later */ |
e3631d1c LP |
2 | #pragma once |
3 | ||
b7ad4778 | 4 | bool reboot_parameter_is_valid(const char *parameter); |
77defcf5 | 5 | int update_reboot_parameter_and_warn(const char *parameter, bool keep); |
c01dcddf LP |
6 | |
7 | typedef 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 | 13 | int read_reboot_parameter(char **parameter); |
c01dcddf | 14 | int reboot_with_parameter(RebootFlags flags); |
2bfa8466 | 15 | |
022a19c9 | 16 | bool shall_restore_state(void); |
ede5a78f ST |
17 | |
18 | bool kexec_loaded(void); |