wlan: Runtime memory debug configuration support
Provide runtime configuration support for memory leak
debug feature using ini flag.
Change-Id: Ibca73e4d2c027ec68ab1ddd6de7c169deed0965a
CRs-Fixed: 583700
diff --git a/CORE/HDD/src/wlan_hdd_main.c b/CORE/HDD/src/wlan_hdd_main.c
index a352272..9438c87 100644
--- a/CORE/HDD/src/wlan_hdd_main.c
+++ b/CORE/HDD/src/wlan_hdd_main.c
@@ -7615,6 +7615,13 @@
__func__, WLAN_INI_FILE);
goto err_config;
}
+#ifdef MEMORY_DEBUG
+ if (pHddCtx->cfg_ini->IsMemoryDebugSupportEnabled)
+ vos_mem_init();
+
+ hddLog(VOS_TRACE_LEVEL_INFO, "%s: gEnableMemoryDebug=%d",
+ __func__, pHddCtx->cfg_ini->IsMemoryDebugSupportEnabled);
+#endif
/* INI has been read, initialise the configuredMcastBcastFilter with
* INI value as this will serve as the default value
@@ -8347,10 +8354,6 @@
break;
}
-#ifdef MEMORY_DEBUG
- vos_mem_init();
-#endif
-
#ifdef TIMER_MANAGER
vos_timer_manager_init();
#endif