diff options
author | Dave Hansen <dave@sr71.net> | 2014-01-23 18:52:49 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-01-23 19:36:50 -0500 |
commit | f0b791a34cb3cffd2bbc3ca4365c9b719fa2c9f3 (patch) | |
tree | c4aa42cd8ecd15eca056a944788f5457e3a370ef /mm/memory_hotplug.c | |
parent | 12ab028be0008640de712ca890dc1a9ae224934d (diff) |
mm: print more details for bad_page()
bad_page() is cool in that it prints out a bunch of data about the page.
But, I can never remember which page flags are good and which are bad,
or whether ->index or ->mapping is required to be NULL.
This patch allows bad/dump_page() callers to specify a string about why
they are dumping the page and adds explanation strings to a number of
places. It also adds a 'bad_flags' argument to bad_page(), which it
then dumps out separately from the flags which are actually set.
This way, the messages will show specifically why the page was bad,
*specifically* which flags it is complaining about, if it was a page
flag combination which was the problem.
[akpm@linux-foundation.org: switch to pr_alert]
Signed-off-by: Dave Hansen <dave.hansen@linux.intel.com>
Reviewed-by: Christoph Lameter <cl@linux.com>
Cc: Andi Kleen <andi@firstfloor.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/memory_hotplug.c')
-rw-r--r-- | mm/memory_hotplug.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/memory_hotplug.c b/mm/memory_hotplug.c index cc2ab37220b7..a512a47241a4 100644 --- a/mm/memory_hotplug.c +++ b/mm/memory_hotplug.c | |||
@@ -1309,7 +1309,7 @@ do_migrate_range(unsigned long start_pfn, unsigned long end_pfn) | |||
1309 | #ifdef CONFIG_DEBUG_VM | 1309 | #ifdef CONFIG_DEBUG_VM |
1310 | printk(KERN_ALERT "removing pfn %lx from LRU failed\n", | 1310 | printk(KERN_ALERT "removing pfn %lx from LRU failed\n", |
1311 | pfn); | 1311 | pfn); |
1312 | dump_page(page); | 1312 | dump_page(page, "failed to remove from LRU"); |
1313 | #endif | 1313 | #endif |
1314 | put_page(page); | 1314 | put_page(page); |
1315 | /* Because we don't have big zone->lock. we should | 1315 | /* Because we don't have big zone->lock. we should |