Gitweb: http://git.kernel.org/git/?p=linux/kernel/git/torvalds/linux-2.6.git;a=commit;h=c5a69adff920ddf138c3ea9886574b195d9e3d52 Commit: c5a69adff920ddf138c3ea9886574b195d9e3d52 Parent: a75de1b3799f8933d6d2b64bdf31194368ec98ab Author: Rafael J. Wysocki <[EMAIL PROTECTED]> AuthorDate: Fri Aug 10 13:00:57 2007 -0700 Committer: Linus Torvalds <[EMAIL PROTECTED]> CommitDate: Sat Aug 11 15:47:40 2007 -0700
Hibernation: do not try to mark invalid PFNs as nosave On some systems some PFNs reported by the early initialization code as 'nosave' may be invalid. If we try to set the corresponding bits in the hibernation bitmap, BUG_ON() in memory_bm_find_bit() will be triggered and the system won't be able to boot (cf. https://bugzilla.novell.com/show_bug.cgi?id=296242). Prevent this from happening by verifying if the 'nosave' PFNs are valid in mark_nosave_pages(). Signed-off-by: Rafael J. Wysocki <[EMAIL PROTECTED]> Acked-by: Pavel Machek <[EMAIL PROTECTED]> Signed-off-by: Andrew Morton <[EMAIL PROTECTED]> Signed-off-by: Linus Torvalds <[EMAIL PROTECTED]> --- kernel/power/snapshot.c | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/kernel/power/snapshot.c b/kernel/power/snapshot.c index a3b7854..a686590 100644 --- a/kernel/power/snapshot.c +++ b/kernel/power/snapshot.c @@ -709,7 +709,8 @@ static void mark_nosave_pages(struct memory_bitmap *bm) region->end_pfn << PAGE_SHIFT); for (pfn = region->start_pfn; pfn < region->end_pfn; pfn++) - memory_bm_set_bit(bm, pfn); + if (pfn_valid(pfn)) + memory_bm_set_bit(bm, pfn); } } - To unsubscribe from this list: send the line "unsubscribe git-commits-head" in the body of a message to [EMAIL PROTECTED] More majordomo info at http://vger.kernel.org/majordomo-info.html