From patchwork Mon Nov 17 09:34:27 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Lin, Mengdong" X-Patchwork-Id: 5316521 Return-Path: X-Original-To: patchwork-alsa-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork1.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.19.201]) by patchwork1.web.kernel.org (Postfix) with ESMTP id 428CA9F1E1 for ; Mon, 17 Nov 2014 09:28:51 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id 7EE1320122 for ; Mon, 17 Nov 2014 09:28:50 +0000 (UTC) Received: from alsa0.perex.cz (alsa0.perex.cz [77.48.224.243]) by mail.kernel.org (Postfix) with ESMTP id 557D62010F for ; Mon, 17 Nov 2014 09:28:49 +0000 (UTC) Received: by alsa0.perex.cz (Postfix, from userid 1000) id 4B06B2617DF; Mon, 17 Nov 2014 10:28:48 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Spam-Level: X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,NO_DNS_FOR_FROM, RCVD_IN_DNSWL_NONE,UNPARSEABLE_RELAY autolearn=no version=3.3.1 Received: from alsa0.perex.cz (localhost [IPv6:::1]) by alsa0.perex.cz (Postfix) with ESMTP id BD15A26166B; Mon, 17 Nov 2014 10:28:09 +0100 (CET) X-Original-To: alsa-devel@alsa-project.org Delivered-To: alsa-devel@alsa-project.org Received: by alsa0.perex.cz (Postfix, from userid 1000) id 22BE3261564; Mon, 17 Nov 2014 10:28:08 +0100 (CET) Received: from mga11.intel.com (mga11.intel.com [192.55.52.93]) by alsa0.perex.cz (Postfix) with ESMTP id 23175261564 for ; Mon, 17 Nov 2014 10:27:59 +0100 (CET) Received: from fmsmga001.fm.intel.com ([10.253.24.23]) by fmsmga102.fm.intel.com with ESMTP; 17 Nov 2014 01:27:59 -0800 X-ExtLoop1: 1 X-IronPort-AV: E=Sophos;i="5.07,401,1413270000"; d="scan'208";a="623477502" Received: from amanda-hsw-pc.sh.intel.com ([10.239.37.16]) by fmsmga001.fm.intel.com with ESMTP; 17 Nov 2014 01:27:56 -0800 From: mengdong.lin@intel.com To: alsa-devel@alsa-project.org, broonie@kernel.org, vinod.koul@intel.com, subhransu.s.prusty@intel.com, liam.r.girdwood@intel.com Date: Mon, 17 Nov 2014 17:34:27 +0800 Message-Id: <14c8d095785c6a33e60b3a9e03fc1a2d8445a15f.1416216640.git.mengdong.lin@intel.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: References: Cc: Mengdong Lin Subject: [alsa-devel] [PATCH v4 2/2] ASoC: Intel: add support for Cherrytrail and Braswell in SST driver X-BeenThere: alsa-devel@alsa-project.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Alsa-devel mailing list for ALSA developers - http://www.alsa-project.org" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: alsa-devel-bounces@alsa-project.org Sender: alsa-devel-bounces@alsa-project.org X-Virus-Scanned: ClamAV using ClamSMTP From: Mengdong Lin 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 Acked-by: Vinod Koul 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}, { }, };