2022-06-29 15:00:15 +00:00
|
|
|
From 21b7898d5c3a074203d6cb8a71962010874f87bb Mon Sep 17 00:00:00 2001
|
|
|
|
From: Lukas Nykryn <lnykryn@redhat.com>
|
|
|
|
Date: Tue, 15 Feb 2022 13:47:40 +0100
|
|
|
|
Subject: [PATCH] fix(95resume): only exclude this module, when swap is netdev
|
2021-07-09 10:41:07 +00:00
|
|
|
|
2022-06-29 15:00:15 +00:00
|
|
|
Resolves: #2017787
|
2021-07-09 10:41:07 +00:00
|
|
|
---
|
2022-06-29 15:00:15 +00:00
|
|
|
modules.d/95resume/module-setup.sh | 5 ++---
|
|
|
|
1 file changed, 2 insertions(+), 3 deletions(-)
|
2021-08-12 11:50:44 +00:00
|
|
|
|
2022-06-29 15:00:15 +00:00
|
|
|
diff --git a/modules.d/95resume/module-setup.sh b/modules.d/95resume/module-setup.sh
|
|
|
|
index 5e891048..4b8d8422 100755
|
|
|
|
--- a/modules.d/95resume/module-setup.sh
|
|
|
|
+++ b/modules.d/95resume/module-setup.sh
|
|
|
|
@@ -10,10 +10,9 @@ check() {
|
|
|
|
return 1
|
|
|
|
}
|
|
|
|
|
|
|
|
- # Only support resume if hibernation is currently on
|
|
|
|
- # and no swap is mounted on a net device
|
|
|
|
+ # Only support resume if no swap is mounted on a net device
|
|
|
|
[[ $hostonly ]] || [[ $mount_needs ]] && {
|
|
|
|
- swap_on_netdevice || [[ -f /sys/power/resume && "$(cat /sys/power/resume)" == "0:0" ]] && return 255
|
|
|
|
+ swap_on_netdevice && return 255
|
|
|
|
}
|
|
|
|
|
|
|
|
return 0
|