]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm: print more details for bad_page()
authorDave Hansen <dave@sr71.net>
Fri, 3 Jan 2014 03:10:02 +0000 (14:10 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Fri, 3 Jan 2014 03:10:02 +0000 (14:10 +1100)
commit6b784d93b2199c5fe1669fa72cf40a35fe363d83
treed20790843d3fa7c4f99b647103eda0c5fb3e867a
parentd3dcf9c10dac4cf59bc87f11902c8bfc73345d66
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.

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>
include/linux/mm.h
mm/balloon_compaction.c
mm/memory.c
mm/memory_hotplug.c
mm/page_alloc.c