Commit 0b76f512 authored by Daniel Baluta's avatar Daniel Baluta Committed by Mark Brown

ASoC: SOF: Remove call to snd_sof_dsp_mailbox_init

This is reserved for some historical reason, we didn't enable memory
windows for byt/bdw at the beginning, to make it compatible, we get
those mailbox offsets from fw_ready struct firstly, and then update them
if they existed in the following memory windows, to make sure the
mailbox still can be used if no memory windows are created.

With this change all platforms have the same implementation for
xxx_fw_ready function so that we can refactor it in a common file.
Suggested-by: default avatarKeyon Jie <yang.jie@linux.intel.com>
Signed-off-by: default avatarDaniel Baluta <daniel.baluta@nxp.com>
Signed-off-by: default avatarPierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
Link: https://lore.kernel.org/r/20190807150203.26359-2-pierre-louis.bossart@linux.intel.comSigned-off-by: default avatarMark Brown <broonie@kernel.org>
parent 0fd70e22
...@@ -455,11 +455,6 @@ static int bdw_fw_ready(struct snd_sof_dev *sdev, u32 msg_id) ...@@ -455,11 +455,6 @@ static int bdw_fw_ready(struct snd_sof_dev *sdev, u32 msg_id)
sof_block_read(sdev, sdev->mmio_bar, offset, fw_ready, sof_block_read(sdev, sdev->mmio_bar, offset, fw_ready,
sizeof(*fw_ready)); sizeof(*fw_ready));
snd_sof_dsp_mailbox_init(sdev, fw_ready->dspbox_offset,
fw_ready->dspbox_size,
fw_ready->hostbox_offset,
fw_ready->hostbox_size);
/* make sure ABI version is compatible */ /* make sure ABI version is compatible */
ret = snd_sof_ipc_valid(sdev); ret = snd_sof_ipc_valid(sdev);
if (ret < 0) if (ret < 0)
......
...@@ -237,11 +237,6 @@ static int byt_fw_ready(struct snd_sof_dev *sdev, u32 msg_id) ...@@ -237,11 +237,6 @@ static int byt_fw_ready(struct snd_sof_dev *sdev, u32 msg_id)
sof_block_read(sdev, sdev->mmio_bar, offset, fw_ready, sof_block_read(sdev, sdev->mmio_bar, offset, fw_ready,
sizeof(*fw_ready)); sizeof(*fw_ready));
snd_sof_dsp_mailbox_init(sdev, fw_ready->dspbox_offset,
fw_ready->dspbox_size,
fw_ready->hostbox_offset,
fw_ready->hostbox_size);
/* make sure ABI version is compatible */ /* make sure ABI version is compatible */
ret = snd_sof_ipc_valid(sdev); ret = snd_sof_ipc_valid(sdev);
if (ret < 0) if (ret < 0)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment