aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
authorCatalin Marinas <catalin.marinas@arm.com>2009-06-29 12:13:57 -0400
committerCatalin Marinas <catalin.marinas@arm.com>2009-06-29 12:14:14 -0400
commitb6e687221eb840bacd4d4a991e5f8e7ed3ae910a (patch)
tree0990d2d2b044ffa0210807e4fe251a4be9306629 /mm
parent17bb9e0d906b625f86e9d31740bb1c35bc0f63d7 (diff)
kmemleak: Do not warn if an unknown object is freed
vmap'ed memory blocks are not tracked by kmemleak (yet) but they may be released with vfree() which is tracked. The corresponding kmemleak warning is only enabled in debug mode. Future patch will add support for ioremap and vmap. Signed-off-by: Catalin Marinas <catalin.marinas@arm.com>
Diffstat (limited to 'mm')
-rw-r--r--mm/kmemleak.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/mm/kmemleak.c b/mm/kmemleak.c
index e094c4dbdf5..eeece2deace 100644
--- a/mm/kmemleak.c
+++ b/mm/kmemleak.c
@@ -531,8 +531,10 @@ static void delete_object(unsigned long ptr)
531 write_lock_irqsave(&kmemleak_lock, flags); 531 write_lock_irqsave(&kmemleak_lock, flags);
532 object = lookup_object(ptr, 0); 532 object = lookup_object(ptr, 0);
533 if (!object) { 533 if (!object) {
534#ifdef DEBUG
534 kmemleak_warn("Freeing unknown object at 0x%08lx\n", 535 kmemleak_warn("Freeing unknown object at 0x%08lx\n",
535 ptr); 536 ptr);
537#endif
536 write_unlock_irqrestore(&kmemleak_lock, flags); 538 write_unlock_irqrestore(&kmemleak_lock, flags);
537 return; 539 return;
538 } 540 }