Re: [PATCH 2/3] mm: introduce VM_BUG_ON_MM

From: Chris Metcalf
Date: Wed Sep 24 2014 - 13:04:41 EST

On 9/6/2014 3:40 PM, Sasha Levin wrote:
Very similar to VM_BUG_ON_PAGE and VM_BUG_ON_VMA, dump struct_mm
when the bug is hit.

Signed-off-by: Sasha Levin <sasha.levin@xxxxxxxxxx>
include/linux/mmdebug.h | 10 +++++++
mm/debug.c | 69 +++++++++++++++++++++++++++++++++++++++++++++++
2 files changed, 79 insertions(+)

diff --git a/mm/debug.c b/mm/debug.c
index c19af12..8418893 100644
--- a/mm/debug.c
+++ b/mm/debug.c
+ "tlb_flush_pending %d\n",

Putting the comma that separates the format string from the arguments
inside an ifdef means that if you don't build with NUMA_BALANCING or
COMPACTION you get a compile error. Perhaps this instead:

+ "tlb_flush_pending %d\n"
- mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,
+ , mm, mm->mmap, mm->vmacache_seqnum, mm->task_size,

Chris Metcalf, Tilera Corp.
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at
Please read the FAQ at