Merge pull request #14241 from keszybz/resume-timeout
Bump resume timeout to infinity
This commit is contained in:
@@ -366,7 +366,7 @@ static int create_disk(
|
||||
|
||||
r = generator_write_timeouts(arg_dest, device, name, options, &filtered);
|
||||
if (r < 0)
|
||||
return r;
|
||||
log_warning_errno(r, "Failed to write device timeout drop-in: %m");
|
||||
|
||||
if (filtered) {
|
||||
filtered_escaped = specifier_escape(filtered);
|
||||
@@ -419,11 +419,11 @@ static int create_disk(
|
||||
return r;
|
||||
|
||||
if (!noauto && !nofail) {
|
||||
r = write_drop_in(arg_dest, dmname, 90, "device-timeout",
|
||||
"# Automatically generated by systemd-cryptsetup-generator \n\n"
|
||||
r = write_drop_in(arg_dest, dmname, 40, "device-timeout",
|
||||
"# Automatically generated by systemd-cryptsetup-generator\n\n"
|
||||
"[Unit]\nJobTimeoutSec=0");
|
||||
if (r < 0)
|
||||
return log_error_errno(r, "Failed to write device drop-in: %m");
|
||||
log_warning_errno(r, "Failed to write device timeout drop-in: %m");
|
||||
}
|
||||
|
||||
return 0;
|
||||
@@ -650,7 +650,6 @@ static int add_proc_cmdline_devices(void) {
|
||||
crypto_device *d;
|
||||
|
||||
HASHMAP_FOREACH(d, arg_disks, i) {
|
||||
const char *options;
|
||||
_cleanup_free_ char *device = NULL;
|
||||
|
||||
if (!d->create)
|
||||
@@ -666,14 +665,11 @@ static int add_proc_cmdline_devices(void) {
|
||||
if (!device)
|
||||
return log_oom();
|
||||
|
||||
if (d->options)
|
||||
options = d->options;
|
||||
else if (arg_default_options)
|
||||
options = arg_default_options;
|
||||
else
|
||||
options = "timeout=0";
|
||||
|
||||
r = create_disk(d->name, device, d->keyfile ?: arg_default_keyfile, d->keydev, options);
|
||||
r = create_disk(d->name,
|
||||
device,
|
||||
d->keyfile ?: arg_default_keyfile,
|
||||
d->keydev,
|
||||
d->options ?: arg_default_options);
|
||||
if (r < 0)
|
||||
return r;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user