[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1285566238-10966-21-git-send-email-nigel@tuxonice.net>
Date: Mon, 27 Sep 2010 15:43:55 +1000
From: Nigel Cunningham <nigel@...onice.net>
To: "Rafael J. Wysocki" <rjw@...k.pl>,
Linux PM <linux-pm@...ts.linux-foundation.org>,
LKML <linux-kernel@...r.kernel.org>,
TuxOnIce-devel <tuxonice-devel@...onice.net>
Subject: [PATCH 20/23] Hibernation: Prepare for handle.cur removal
Prepare for the removal of handle.cur by stopping using
it in get_swap_reader.
Signed-off-by: Nigel Cunningham <nigel@...onice.net>
---
kernel/power/block_io.c | 10 +++++-----
1 files changed, 5 insertions(+), 5 deletions(-)
diff --git a/kernel/power/block_io.c b/kernel/power/block_io.c
index c154a92..4f46878 100644
--- a/kernel/power/block_io.c
+++ b/kernel/power/block_io.c
@@ -276,29 +276,29 @@ int get_swap_reader(unsigned int *flags_p, sector_t first_page)
if (!handle.cur)
return -ENOMEM;
- error = hib_bio_read_page(first_page, handle.cur, 1);
+ error = hib_prepare_buffer();
if (error) {
release_swap_reader();
return error;
}
- error = hib_prepare_buffer();
+ /* Bootstrap reading the extents */
+ error = hib_bio_read_page(first_page, hib_ppio_buffer, 1);
if (error) {
release_swap_reader();
+ hib_free_buffer();
return error;
}
handle.k = 0;
- /* Bootstrap reading the extents */
- memcpy(hib_ppio_buffer, handle.cur, PAGE_SIZE);
error = hib_extents_load(§or_extents, 1);
if (error) {
release_swap_reader();
- return error;
}
+ hib_free_buffer();
return error;
}
--
1.7.0.4
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists