From: Pawel Harlozinski <pawel.harlozinski@linux.intel.com>
To: alsa-devel@alsa-project.org
Cc: cezary.rojewski@intel.com, tiwai@suse.de,
Szymon Mielczarek <szymonx.mielczarek@intel.com>,
lgirdwood@gmail.com, pierre-louis.bossart@linux.intel.com,
broonie@kernel.org,
Pawel Harlozinski <pawel.harlozinski@linux.intel.com>
Subject: [PATCH v2] ASoC: Intel: Skylake: Recover BXT FW on DSP boot timeout error
Date: Mon, 8 Jul 2019 16:02:48 +0200 [thread overview]
Message-ID: <20190708140248.14304-1-pawel.harlozinski@linux.intel.com> (raw)
When DSP boots with timeout error try to reload firmware
to keep best user expeirience.
Signed-off-by: Szymon Mielczarek <szymonx.mielczarek@intel.com>
Signed-off-by: Pawel Harlozinski <pawel.harlozinski@linux.intel.com>
---
sound/soc/intel/skylake/bxt-sst.c | 17 +++++++++++------
1 file changed, 11 insertions(+), 6 deletions(-)
diff --git a/sound/soc/intel/skylake/bxt-sst.c b/sound/soc/intel/skylake/bxt-sst.c
index 440bca7afbf1..dd0260557530 100644
--- a/sound/soc/intel/skylake/bxt-sst.c
+++ b/sound/soc/intel/skylake/bxt-sst.c
@@ -455,13 +455,19 @@ static int bxt_set_dsp_D0(struct sst_dsp *ctx, unsigned int core_id)
/* If core 1 was turned on for booting core 0, turn it off */
skl_dsp_core_power_down(ctx, SKL_DSP_CORE_MASK(1));
if (ret == 0) {
- dev_err(ctx->dev, "%s: DSP boot timeout\n", __func__);
- dev_err(ctx->dev, "Error code=0x%x: FW status=0x%x\n",
+ dev_warn(ctx->dev,
+ "DSP boot timeout: Error code=0x%x: FW status=0x%x\n",
sst_dsp_shim_read(ctx, BXT_ADSP_ERROR_CODE),
sst_dsp_shim_read(ctx, BXT_ADSP_FW_STATUS));
- dev_err(ctx->dev, "Failed to set core0 to D0 state\n");
- ret = -EIO;
- goto err;
+ dev_warn(ctx->dev,"Reloading FW\n");
+
+ ret = bxt_sst_init_fw(skl->dev, skl);
+ if (ret < 0) {
+ dev_err(ctx->dev, "Reload fw failed: %d\n", ret);
+ dev_err(ctx->dev, "Failed to set core0 to D0 state\n");
+ ret = -EIO;
+ goto err;
+ }
}
}
@@ -486,7 +492,6 @@ static int bxt_set_dsp_D0(struct sst_dsp *ctx, unsigned int core_id)
if (core_id == SKL_DSP_CORE0_ID)
core_mask |= SKL_DSP_CORE_MASK(1);
skl_dsp_disable_core(ctx, core_mask);
-
return ret;
}
--
2.17.1
next reply other threads:[~2019-07-08 14:03 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2019-07-08 14:02 Pawel Harlozinski [this message]
2019-07-23 15:14 ` [PATCH v2] ASoC: Intel: Skylake: Recover BXT FW on DSP boot timeout error Cezary Rojewski
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=20190708140248.14304-1-pawel.harlozinski@linux.intel.com \
--to=pawel.harlozinski@linux.intel.com \
--cc=alsa-devel@alsa-project.org \
--cc=broonie@kernel.org \
--cc=cezary.rojewski@intel.com \
--cc=lgirdwood@gmail.com \
--cc=pierre-louis.bossart@linux.intel.com \
--cc=szymonx.mielczarek@intel.com \
--cc=tiwai@suse.de \
/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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox