diff options
author | Vinod Koul <vinod.koul@intel.com> | 2016-05-30 15:12:56 +0300 |
---|---|---|
committer | Mark Brown <broonie@kernel.org> | 2016-05-30 20:24:41 +0300 |
commit | fdfa82ee1435dc8ff6b4c82640bd142f2d15edb1 (patch) | |
tree | b9c66109cbd854ba3ccf681d9c45e9c8b598cf0f /sound/soc/intel/skylake/bxt-sst.c | |
parent | 6eee87261f69e366bfe9b908ae3b441efb8e28ea (diff) | |
download | linux-fdfa82ee1435dc8ff6b4c82640bd142f2d15edb1.tar.xz |
ASoC: Intel: Skylake: Don't use local pointer for firmware
We have firmware pointer is driver context, so use that instead
of local pointer.
Signed-off-by: Vinod Koul <vinod.koul@intel.com>
Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/intel/skylake/bxt-sst.c')
-rw-r--r-- | sound/soc/intel/skylake/bxt-sst.c | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/sound/soc/intel/skylake/bxt-sst.c b/sound/soc/intel/skylake/bxt-sst.c index 965ce40ce752..dd86232eea05 100644 --- a/sound/soc/intel/skylake/bxt-sst.c +++ b/sound/soc/intel/skylake/bxt-sst.c @@ -132,20 +132,19 @@ static int sst_transfer_fw_host_dma(struct sst_dsp *ctx) static int bxt_load_base_firmware(struct sst_dsp *ctx) { - const struct firmware *fw = NULL; struct skl_sst *skl = ctx->thread_context; int ret; - ret = request_firmware(&fw, ctx->fw_name, ctx->dev); + ret = request_firmware(&ctx->fw, ctx->fw_name, ctx->dev); if (ret < 0) { dev_err(ctx->dev, "Request firmware failed %d\n", ret); goto sst_load_base_firmware_failed; } - ret = sst_bxt_prepare_fw(ctx, fw->data, fw->size); + ret = sst_bxt_prepare_fw(ctx, ctx->fw->data, ctx->fw->size); /* Retry Enabling core and ROM load. Retry seemed to help */ if (ret < 0) { - ret = sst_bxt_prepare_fw(ctx, fw->data, fw->size); + ret = sst_bxt_prepare_fw(ctx, ctx->fw->data, ctx->fw->size); if (ret < 0) { dev_err(ctx->dev, "Core En/ROM load fail:%d\n", ret); goto sst_load_base_firmware_failed; @@ -175,7 +174,7 @@ static int bxt_load_base_firmware(struct sst_dsp *ctx) } sst_load_base_firmware_failed: - release_firmware(fw); + release_firmware(ctx->fw); return ret; } |