diff --git a/mm/kmemleak.c b/mm/kmemleak.c index f63dfacee7ca..8fa409a4f9fb 100644 --- a/mm/kmemleak.c +++ b/mm/kmemleak.c @@ -237,7 +237,8 @@ static struct task_struct *scan_thread; /* used to avoid reporting of recently allocated objects */ static unsigned long jiffies_min_age; /* consecutive scans an object must stay unreferenced before reporting */ -static unsigned int min_unref_scans = 1; +static unsigned int min_unref_scans = + IS_ENABLED(CONFIG_DEBUG_KMEMLEAK_VERBOSE) ? 2 : 1; module_param(min_unref_scans, uint, 0644); static unsigned long jiffies_last_scan; /* delay between automatic memory scannings */