diff --git a/sound/soc/codecs/wm_adsp.c b/sound/soc/codecs/wm_adsp.c index 36417866f1c0..7afa398ac5a0 100644 --- a/sound/soc/codecs/wm_adsp.c +++ b/sound/soc/codecs/wm_adsp.c @@ -2705,7 +2705,7 @@ static int wm_adsp_load_coeff(struct wm_adsp *dsp) const char *region_name; int ret, pos, blocks, type, offset, reg; char *file; - struct wm_adsp_buf *buf; + unsigned int burst_multiple; if (dsp->firmwares[dsp->fw].binfile && !(strcmp(dsp->firmwares[dsp->fw].binfile, "None"))) @@ -2780,6 +2780,7 @@ static int wm_adsp_load_coeff(struct wm_adsp *dsp) file, blocks, le32_to_cpu(blk->len), offset, type); reg = 0; + burst_multiple = 4; region_name = "Unknown"; switch (type) { case (WMFW_NAME_TEXT << 8): @@ -2853,20 +2854,14 @@ static int wm_adsp_load_coeff(struct wm_adsp *dsp) goto out_fw; } - buf = wm_adsp_buf_alloc(blk->data, - le32_to_cpu(blk->len), - &buf_list); - if (!buf) { - adsp_err(dsp, "Out of memory\n"); - ret = -ENOMEM; - goto out_fw; - } - adsp_dbg(dsp, "%s.%d: Writing %d bytes at %x\n", file, blocks, le32_to_cpu(blk->len), reg); - ret = regmap_raw_write_async(regmap, reg, buf->buf, - le32_to_cpu(blk->len)); + + ret = wm_adsp_write_blocks(dsp, blk->data, + le32_to_cpu(blk->len), + reg, &buf_list, + burst_multiple); if (ret != 0) { adsp_err(dsp, "%s.%d: Failed to write to %x in %s: %d\n",