msm: Build the memory topology by parsing smem.
The kernel needs a view of system memory topology for memory
hotplug. Add support to parse this information available in
shared memory to determine the memory banks and their sizes.
Signed-off-by: Naveen Ramaraj <nramaraj@codeaurora.org>
diff --git a/arch/arm/mach-msm/board-msm8960.c b/arch/arm/mach-msm/board-msm8960.c
index 9de3143..172d1f4 100644
--- a/arch/arm/mach-msm/board-msm8960.c
+++ b/arch/arm/mach-msm/board-msm8960.c
@@ -82,6 +82,7 @@
#include "mpm.h"
#include "acpuclock.h"
#include "rpm_log.h"
+#include "smd_private.h"
static struct platform_device msm_fm_platform_init = {
.name = "iris_fm",
@@ -4054,6 +4055,9 @@
if (socinfo_init() < 0)
pr_err("socinfo_init() failed!\n");
+ if (meminfo_init(SYS_MEMORY, SZ_256M) < 0)
+ pr_err("meminfo_init() failed!\n");
+
BUG_ON(msm_rpm_init(&msm_rpm_data));
BUG_ON(msm_rpmrs_levels_init(msm_rpmrs_levels,
ARRAY_SIZE(msm_rpmrs_levels)));