Skip to content

Commit

Permalink
95resume: only exclude this module, when swap is netdev
Browse files Browse the repository at this point in the history
Resolves: #2017787
  • Loading branch information
lnykryn committed Feb 15, 2022
1 parent 09f8a2b commit df9bb70
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions modules.d/95resume/module-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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 || [[ "$(cat /sys/power/resume)" == "0:0" ]] && return 255
swap_on_netdevice && return 255
}

return 0
Expand Down

0 comments on commit df9bb70

Please sign in to comment.