msm: board-8930: Add support for MSM8627 devices

Add machine records and build support for MSM8627 CDP and
MTP devices. Fix up the board file to take the new machines
into account.

Change-Id: Ia79670b944fedc636995a4f454bb738347c867ad
Signed-off-by: Stepan Moskovchenko <stepanm@codeaurora.org>
diff --git a/arch/arm/mach-msm/Kconfig b/arch/arm/mach-msm/Kconfig
index fc27feb..1b836c4 100644
--- a/arch/arm/mach-msm/Kconfig
+++ b/arch/arm/mach-msm/Kconfig
@@ -604,6 +604,18 @@
 	help
 	  Support for the Qualcomm MSM8930 FLUID device.
 
+config MACH_MSM8627_CDP
+	depends on ARCH_MSM8930
+	bool "MSM8627 CDP"
+	help
+	  Support for the Qualcomm MSM8627 CDP device.
+
+config MACH_MSM8627_MTP
+	depends on ARCH_MSM8930
+	bool "MSM8627 MTP"
+	help
+	  Support for the Qualcomm MSM8627 MTP device.
+
 config MACH_MSM9615_CDP
 	depends on ARCH_MSM9615
 	bool "MSM9615 CDP"
diff --git a/arch/arm/mach-msm/board-msm8930.c b/arch/arm/mach-msm/board-msm8930.c
index dfb7908..d61296c 100644
--- a/arch/arm/mach-msm/board-msm8930.c
+++ b/arch/arm/mach-msm/board-msm8930.c
@@ -2446,11 +2446,11 @@
 	int i;
 
 	/* Build the matching 'supported_machs' bitmask */
-	if (machine_is_msm8930_cdp())
+	if (machine_is_msm8930_cdp() || machine_is_msm8627_cdp())
 		mach_mask = I2C_SURF;
 	else if (machine_is_msm8930_fluid())
 		mach_mask = I2C_FLUID;
-	else if (machine_is_msm8930_mtp())
+	else if (machine_is_msm8930_mtp() || machine_is_msm8627_mtp())
 		mach_mask = I2C_FFA;
 	else
 		pr_err("unmatched machine ID in register_i2c_devices\n");
@@ -2546,3 +2546,23 @@
 	.init_early = msm8930_allocate_memory_regions,
 	.init_very_early = msm8930_early_memory,
 MACHINE_END
+
+MACHINE_START(MSM8627_CDP, "QCT MSM8627 CDP")
+	.map_io = msm8930_map_io,
+	.reserve = msm8930_reserve,
+	.init_irq = msm8930_init_irq,
+	.timer = &msm_timer,
+	.init_machine = msm8930_cdp_init,
+	.init_early = msm8930_allocate_memory_regions,
+	.init_very_early = msm8930_early_memory,
+MACHINE_END
+
+MACHINE_START(MSM8627_MTP, "QCT MSM8627 MTP")
+	.map_io = msm8930_map_io,
+	.reserve = msm8930_reserve,
+	.init_irq = msm8930_init_irq,
+	.timer = &msm_timer,
+	.init_machine = msm8930_cdp_init,
+	.init_early = msm8930_allocate_memory_regions,
+	.init_very_early = msm8930_early_memory,
+MACHINE_END