[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <1275481160-31150-20-git-send-email-nigel@tuxonice.net>
Date: Wed, 2 Jun 2010 22:19:18 +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 19/21] 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 c71c7c3..dd71ef2 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