All of lore.kernel.org
 help / color / mirror / Atom feed
From: Vinod Koul <vinod.koul@intel.com>
To: alsa-devel@alsa-project.org
Cc: liam.r.girdwood@linux.intel.com, patches.audio@intel.com,
	broonie@kernel.org, Ramesh Babu <ramesh.babu@intel.com>,
	Vinod Koul <vinod.koul@intel.com>
Subject: [PATCH 4/7] ASoC: Intel: Skylake: Strip manifest for Broxton platform
Date: Mon, 30 May 2016 17:42:58 +0530	[thread overview]
Message-ID: <1464610381-19416-5-git-send-email-vinod.koul@intel.com> (raw)
In-Reply-To: <1464610381-19416-1-git-send-email-vinod.koul@intel.com>

Broxton firmrware comes with extended manifest so invoke
skl_dsp_strip_extended_manifest() to check and strip

Signed-off-by: Ramesh Babu <ramesh.babu@intel.com>
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
---
 sound/soc/intel/skylake/bxt-sst.c | 14 ++++++++++++--
 1 file changed, 12 insertions(+), 2 deletions(-)

diff --git a/sound/soc/intel/skylake/bxt-sst.c b/sound/soc/intel/skylake/bxt-sst.c
index dd86232eea05..0dd921349663 100644
--- a/sound/soc/intel/skylake/bxt-sst.c
+++ b/sound/soc/intel/skylake/bxt-sst.c
@@ -132,6 +132,7 @@ static int sst_transfer_fw_host_dma(struct sst_dsp *ctx)
 
 static int bxt_load_base_firmware(struct sst_dsp *ctx)
 {
+	struct firmware stripped_fw;
 	struct skl_sst *skl = ctx->thread_context;
 	int ret;
 
@@ -141,10 +142,19 @@ static int bxt_load_base_firmware(struct sst_dsp *ctx)
 		goto sst_load_base_firmware_failed;
 	}
 
-	ret = sst_bxt_prepare_fw(ctx, ctx->fw->data, ctx->fw->size);
+	/* check for extended manifest */
+	if (ctx->fw == NULL)
+		goto sst_load_base_firmware_failed;
+
+
+	stripped_fw.data = ctx->fw->data;
+	stripped_fw.size = ctx->fw->size;
+	skl_dsp_strip_extended_manifest(&stripped_fw);
+
+	ret = sst_bxt_prepare_fw(ctx, stripped_fw.data, stripped_fw.size);
 	/* Retry Enabling core and ROM load. Retry seemed to help */
 	if (ret < 0) {
-		ret = sst_bxt_prepare_fw(ctx, ctx->fw->data, ctx->fw->size);
+		ret = sst_bxt_prepare_fw(ctx, stripped_fw.data, stripped_fw.size);
 		if (ret < 0) {
 			dev_err(ctx->dev, "Core En/ROM load fail:%d\n", ret);
 			goto sst_load_base_firmware_failed;
-- 
1.9.1

  parent reply	other threads:[~2016-05-30 12:06 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2016-05-30 12:12 [PATCH 0/7] ASoC: Intel: Skylake: Manifest parsing support Vinod Koul
2016-05-30 12:12 ` [PATCH 1/7] ASoC: Intel: Skylake: Add strip extended manifest utility Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Add strip extended manifest utility" to the asoc tree Mark Brown
2016-05-30 12:12 ` [PATCH 2/7] ASoC: Intel: Skylake: Don't use local pointer for firmware Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Don't use local pointer for firmware" to the asoc tree Mark Brown
2016-05-30 12:12 ` [PATCH 3/7] ASoC: Intel: Skylake: Strip manifest for Skylake platform Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Strip manifest for Skylake platform" to the asoc tree Mark Brown
2016-05-30 12:12 ` Vinod Koul [this message]
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Strip manifest for Broxton " Mark Brown
2016-05-30 12:12 ` [PATCH 5/7] ASoC: Intel: Skylake: Add DSP firmware manifest parsing Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Add DSP firmware manifest parsing" to the asoc tree Mark Brown
2016-05-30 12:13 ` [PATCH 6/7] ASoC: Intel: Skylake: Find uuids for Skylake Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Find uuids for Skylake" to the asoc tree Mark Brown
2016-05-30 12:13 ` [PATCH 7/7] ASoC: Intel: Skylake: Find uuids for Broxton Vinod Koul
2016-05-30 17:39   ` Applied "ASoC: Intel: Skylake: Find uuids for Broxton" to the asoc tree Mark Brown

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1464610381-19416-5-git-send-email-vinod.koul@intel.com \
    --to=vinod.koul@intel.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=broonie@kernel.org \
    --cc=liam.r.girdwood@linux.intel.com \
    --cc=patches.audio@intel.com \
    --cc=ramesh.babu@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.