Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit bf242d19 authored by Vinod Koul's avatar Vinod Koul Committed by Mark Brown
Browse files

ASoC: Intel: Skylake: Strip manifest for Broxton platform



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

Signed-off-by: default avatarRamesh Babu <ramesh.babu@intel.com>
Signed-off-by: default avatarVinod Koul <vinod.koul@intel.com>
Signed-off-by: default avatarMark Brown <broonie@kernel.org>
parent cd63655e
Loading
Loading
Loading
Loading
+12 −2
Original line number Original line Diff line number Diff line
@@ -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)
static int bxt_load_base_firmware(struct sst_dsp *ctx)
{
{
	struct firmware stripped_fw;
	struct skl_sst *skl = ctx->thread_context;
	struct skl_sst *skl = ctx->thread_context;
	int ret;
	int ret;


@@ -141,10 +142,19 @@ static int bxt_load_base_firmware(struct sst_dsp *ctx)
		goto sst_load_base_firmware_failed;
		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 */
	/* Retry Enabling core and ROM load. Retry seemed to help */
	if (ret < 0) {
	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) {
		if (ret < 0) {
			dev_err(ctx->dev, "Core En/ROM load fail:%d\n", ret);
			dev_err(ctx->dev, "Core En/ROM load fail:%d\n", ret);
			goto sst_load_base_firmware_failed;
			goto sst_load_base_firmware_failed;