Loading kernel/module.c +7 −1 Original line number Diff line number Diff line Loading @@ -2421,7 +2421,13 @@ static void *module_alloc_update_bounds(unsigned long size) return ret; } #ifdef CONFIG_DEBUG_KMEMLEAK #if defined(CONFIG_DEBUG_KMEMLEAK) && defined(CONFIG_DEBUG_MODULE_SCAN_OFF) static void kmemleak_load_module(const struct module *mod, const struct load_info *info) { kmemleak_no_scan(mod->module_core); } #elif defined(CONFIG_DEBUG_KMEMLEAK) static void kmemleak_load_module(const struct module *mod, const struct load_info *info) { Loading lib/Kconfig.debug +9 −0 Original line number Diff line number Diff line Loading @@ -553,6 +553,15 @@ config DEBUG_TASK_STACK_SCAN_OFF writing to the debugfs entry : echo "stack=on" > /sys/kernel/debug/kmemleak. config DEBUG_MODULE_SCAN_OFF bool "Disable module memory scan for leaks by default" depends on DEBUG_KMEMLEAK help Say Y here to disable scanning kernel modules area list by default for memory leaks. Module scan an potentially run with irq/preemption disabled for considerable amount of time. config DEBUG_PREEMPT bool "Debug preemptible kernel" depends on DEBUG_KERNEL && PREEMPT && TRACE_IRQFLAGS_SUPPORT Loading Loading
kernel/module.c +7 −1 Original line number Diff line number Diff line Loading @@ -2421,7 +2421,13 @@ static void *module_alloc_update_bounds(unsigned long size) return ret; } #ifdef CONFIG_DEBUG_KMEMLEAK #if defined(CONFIG_DEBUG_KMEMLEAK) && defined(CONFIG_DEBUG_MODULE_SCAN_OFF) static void kmemleak_load_module(const struct module *mod, const struct load_info *info) { kmemleak_no_scan(mod->module_core); } #elif defined(CONFIG_DEBUG_KMEMLEAK) static void kmemleak_load_module(const struct module *mod, const struct load_info *info) { Loading
lib/Kconfig.debug +9 −0 Original line number Diff line number Diff line Loading @@ -553,6 +553,15 @@ config DEBUG_TASK_STACK_SCAN_OFF writing to the debugfs entry : echo "stack=on" > /sys/kernel/debug/kmemleak. config DEBUG_MODULE_SCAN_OFF bool "Disable module memory scan for leaks by default" depends on DEBUG_KMEMLEAK help Say Y here to disable scanning kernel modules area list by default for memory leaks. Module scan an potentially run with irq/preemption disabled for considerable amount of time. config DEBUG_PREEMPT bool "Debug preemptible kernel" depends on DEBUG_KERNEL && PREEMPT && TRACE_IRQFLAGS_SUPPORT Loading