summaryrefslogtreecommitdiff
path: root/sound/soc/sof/intel/apl.c
diff options
context:
space:
mode:
authorRanjani Sridharan <ranjani.sridharan@linux.intel.com>2022-05-11 20:16:44 +0300
committerMark Brown <broonie@kernel.org>2022-05-12 13:41:25 +0300
commite3105c0ccc3e706584030159b6fde54cab2f8aef (patch)
tree4d84183e4c722fe68cb0602301adc6c8cd8ee018 /sound/soc/sof/intel/apl.c
parent8b7a4075a5b5cc8d58a09c558d7c95e7befe77ee (diff)
downloadlinux-e3105c0ccc3e706584030159b6fde54cab2f8aef.tar.xz
ASoC: SOF: Intel: HDA: Set IPC4-specific DSP ops for CaVS platforms
Add implementation of low level, platform dependent IPC4 message handling and set the DSP ops for IPC4 for APL, CNL and TGL platforms. Co-developed-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Rander Wang <rander.wang@intel.com> Reviewed-by: Bard Liao <yung-chuan.liao@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20220511171648.1622993-2-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
Diffstat (limited to 'sound/soc/sof/intel/apl.c')
-rw-r--r--sound/soc/sof/intel/apl.c17
1 files changed, 13 insertions, 4 deletions
diff --git a/sound/soc/sof/intel/apl.c b/sound/soc/sof/intel/apl.c
index b7839fd04dfb..4c67110a073e 100644
--- a/sound/soc/sof/intel/apl.c
+++ b/sound/soc/sof/intel/apl.c
@@ -37,11 +37,20 @@ int sof_apl_ops_init(struct snd_sof_dev *sdev)
/* probe/remove/shutdown */
sof_apl_ops.shutdown = hda_dsp_shutdown;
- /* doorbell */
- sof_apl_ops.irq_thread = hda_dsp_ipc_irq_thread;
+ if (sdev->pdata->ipc_type == SOF_IPC) {
+ /* doorbell */
+ sof_apl_ops.irq_thread = hda_dsp_ipc_irq_thread;
- /* ipc */
- sof_apl_ops.send_msg = hda_dsp_ipc_send_msg;
+ /* ipc */
+ sof_apl_ops.send_msg = hda_dsp_ipc_send_msg;
+ }
+
+ if (sdev->pdata->ipc_type == SOF_INTEL_IPC4) {
+ sof_apl_ops.irq_thread = hda_dsp_ipc4_irq_thread;
+
+ /* ipc */
+ sof_apl_ops.send_msg = hda_dsp_ipc4_send_msg;
+ }
/* set DAI driver ops */
hda_set_dai_drv_ops(sdev, &sof_apl_ops);