[Suspend2][ 26/28] [Suspend2] Swapwriter proc entries.

From: Nigel Cunningham
Date: Mon Jun 26 2006 - 18:42:21 EST


Definitions the for the proc entries provided by the swapwriter.

Signed-off-by: Nigel Cunningham <nigel@xxxxxxxxxxxx>

kernel/power/suspend_swap.c | 38 ++++++++++++++++++++++++++++++++++++++
1 files changed, 38 insertions(+), 0 deletions(-)

diff --git a/kernel/power/suspend_swap.c b/kernel/power/suspend_swap.c
index ee7c36b..e210241 100644
--- a/kernel/power/suspend_swap.c
+++ b/kernel/power/suspend_swap.c
@@ -1140,3 +1140,41 @@ static int header_locations_read_proc(ch
return len;
}

+static struct suspend_proc_data swapwriter_proc_data[] = {
+ {
+ .filename = "swapfilename",
+ .permissions = PROC_RW,
+ .type = SUSPEND_PROC_DATA_STRING,
+ .data = {
+ .string = {
+ .variable = swapfilename,
+ .max_length = 255,
+ }
+ }
+ },
+
+ {
+ .filename = "headerlocations",
+ .permissions = PROC_READONLY,
+ .type = SUSPEND_PROC_DATA_CUSTOM,
+ .data = {
+ .special = {
+ .read_proc = header_locations_read_proc,
+ }
+ }
+ },
+
+ { .filename = "disable_swapwriter",
+ .permissions = PROC_RW,
+ .type = SUSPEND_PROC_DATA_INTEGER,
+ .data = {
+ .integer = {
+ .variable = &swapwriterops.disabled,
+ .minimum = 0,
+ .maximum = 1,
+ }
+ },
+ .write_proc = attempt_to_parse_resume_device2,
+ }
+};
+

--
Nigel Cunningham nigel at suspend2 dot net
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/