Merge branch 'master' into for-next
[safe/jmp/linux-2.6] / lib / Kconfig.debug
index 77e0d8b..43173c4 100644 (file)
@@ -340,8 +340,6 @@ config DEBUG_KMEMLEAK
        bool "Kernel memory leak detector"
        depends on DEBUG_KERNEL && EXPERIMENTAL && (X86 || ARM) && \
                !MEMORY_HOTPLUG
-       select DEBUG_SLAB if SLAB
-       select SLUB_DEBUG if SLUB
        select DEBUG_FS if SYSFS
        select STACKTRACE if STACKTRACE_SUPPORT
        select KALLSYMS
@@ -355,9 +353,24 @@ config DEBUG_KMEMLEAK
          allocations. See Documentation/kmemleak.txt for more
          details.
 
+         Enabling DEBUG_SLAB or SLUB_DEBUG may increase the chances
+         of finding leaks due to the slab objects poisoning.
+
          In order to access the kmemleak file, debugfs needs to be
          mounted (usually at /sys/kernel/debug).
 
+config DEBUG_KMEMLEAK_EARLY_LOG_SIZE
+       int "Maximum kmemleak early log entries"
+       depends on DEBUG_KMEMLEAK
+       range 200 2000
+       default 400
+       help
+         Kmemleak must track all the memory allocations to avoid
+         reporting false positives. Since memory may be allocated or
+         freed before kmemleak is initialised, an early log buffer is
+         used to store these actions. If kmemleak reports "early log
+         buffer exceeded", please increase this value.
+
 config DEBUG_KMEMLEAK_TEST
        tristate "Simple test for the kernel memory leak detector"
        depends on DEBUG_KMEMLEAK