diff mbox

[v4,2/2] ASoC: Intel: add support for Cherrytrail and Braswell in SST driver

Message ID 14c8d095785c6a33e60b3a9e03fc1a2d8445a15f.1416216640.git.mengdong.lin@intel.com (mailing list archive)
State Accepted
Commit bd01fdc3aa63b7ba0b035f9196d80551ad03f5d4
Headers show

Commit Message

Lin, Mengdong Nov. 17, 2014, 9:34 a.m. UTC
From: Mengdong Lin <mengdong.lin@intel.com>

This patch add ACPI device ID and platform data for two Cherryview-based
platforms, Cherrytrail and Braswell. Also reuse mfld driver ops in sst driver.

Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>

Comments

Vinod Koul Nov. 17, 2014, 3:36 p.m. UTC | #1
On Mon, Nov 17, 2014 at 05:34:27PM +0800, mengdong.lin@intel.com wrote:
> From: Mengdong Lin <mengdong.lin@intel.com>
> 
> This patch add ACPI device ID and platform data for two Cherryview-based
> platforms, Cherrytrail and Braswell. Also reuse mfld driver ops in sst driver.
> 
> Signed-off-by: Mengdong Lin <mengdong.lin@intel.com>
Acked-by: Vinod Koul <vinod.koul@intel.com>
diff mbox

Patch

diff --git a/sound/soc/intel/sst/sst.c b/sound/soc/intel/sst/sst.c
index b2b5604..2be4f3f 100644
--- a/sound/soc/intel/sst/sst.c
+++ b/sound/soc/intel/sst/sst.c
@@ -183,6 +183,7 @@  int sst_driver_ops(struct intel_sst_drv *sst)
 	switch (sst->dev_id) {
 	case SST_MRFLD_PCI_ID:
 	case SST_BYT_ACPI_ID:
+	case SST_CHV_ACPI_ID:
 		sst->tstamp = SST_TIME_STAMP_MRFLD;
 		sst->ops = &mrfld_ops;
 		return 0;
diff --git a/sound/soc/intel/sst/sst.h b/sound/soc/intel/sst/sst.h
index 683dc71..7f4bbfc 100644
--- a/sound/soc/intel/sst/sst.h
+++ b/sound/soc/intel/sst/sst.h
@@ -30,6 +30,7 @@ 
 #define SST_DRV_NAME "intel_sst_driver"
 #define SST_MRFLD_PCI_ID 0x119A
 #define SST_BYT_ACPI_ID	0x80860F28
+#define SST_CHV_ACPI_ID	0x808622A8
 
 #define SST_SUSPEND_DELAY 2000
 #define FW_CONTEXT_MEM (64*1024)
diff --git a/sound/soc/intel/sst/sst_acpi.c b/sound/soc/intel/sst/sst_acpi.c
index b261821..c2e5edf 100644
--- a/sound/soc/intel/sst/sst_acpi.c
+++ b/sound/soc/intel/sst/sst_acpi.c
@@ -129,6 +129,17 @@  struct sst_platform_info byt_rvp_platform_data = {
 	.platform = "sst-mfld-platform",
 };
 
+/* Cherryview (Cherrytrail and Braswell) uses same mrfld dpcm fw as Baytrail,
+ * so pdata is same as Baytrail.
+ */
+struct sst_platform_info chv_platform_data = {
+	.probe_data = &byt_fwparse_info,
+	.ipc_info = &byt_ipc_info,
+	.lib_info = &byt_lib_dnld_info,
+	.res_info = &byt_rvp_res_info,
+	.platform = "sst-mfld-platform",
+};
+
 static int sst_platform_get_resources(struct intel_sst_drv *ctx)
 {
 	struct resource *rsrc;
@@ -337,8 +348,16 @@  static struct sst_machines sst_acpi_bytcr[] = {
 	{},
 };
 
+/* Cherryview-based platforms: CherryTrail and Braswell */
+static struct sst_machines sst_acpi_chv[] = {
+	{"10EC5670", "cht-bsw", "cht-bsw-rt5672", NULL, "fw_sst_22a8.bin",
+						&chv_platform_data },
+	{},
+};
+
 static const struct acpi_device_id sst_acpi_ids[] = {
 	{ "80860F28", (unsigned long)&sst_acpi_bytcr},
+	{ "808622A8", (unsigned long) &sst_acpi_chv},
 	{ },
 };