|
Zbigniew Jędrzejewski-Szmek |
930e1b |
From a5fd1d54d63e9e5861113fd30911949a148921e1 Mon Sep 17 00:00:00 2001
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
From: Jan Janssen <medhefgo@web.de>
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
Date: Thu, 31 Oct 2013 17:22:03 +0100
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
Subject: [PATCH] Make hibernation test work for swap files
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
Suspend to disk works for swap files too (even if it is located
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
on an ecrypted file system):
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
https://www.kernel.org/doc/Documentation/power/swsusp-and-swap-files.txt
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
---
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
src/shared/sleep-config.c | 2 +-
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
1 file changed, 1 insertion(+), 1 deletion(-)
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
diff --git a/src/shared/sleep-config.c b/src/shared/sleep-config.c
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
index d068bfc..2bb0493 100644
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
--- a/src/shared/sleep-config.c
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
+++ b/src/shared/sleep-config.c
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
@@ -206,7 +206,7 @@ static int hibernation_partition_size(size_t *size, size_t *used) {
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
if (!d)
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
return -ENOMEM;
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
- if (!streq(type, "partition")) {
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
+ if (!streq(type, "partition") && !streq(type, "file")) {
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
log_debug("Partition %s has type %s, ignoring.", d, type);
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
continue;
|
|
Zbigniew Jędrzejewski-Szmek |
930e1b |
}
|