Skip to content

Commit 5a1fa00

Browse files
IulianOlaru249broonie
authored andcommitted
ASoC: SOF: sof-of-dev: Add .arch_ops field
Add .arch_ops field in the sof_imx8x_ops structure. The inclusion of this field will allow the usage of functions from sof/core.c in order to print debug information such as the registers and a stack dump in case of a firmware ops. The SND_SOC_SOF_XTENSA is added in the imx/Kconfig file so the compilation is successful. Signed-off-by: Iulian Olaru <iulianolaru249@yahoo.com> Reviewed-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Reviewed-by: Daniel Baluta <daniel.baluta@gmail.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com> Link: https://lore.kernel.org/r/20200825235040.1586478-8-ranjani.sridharan@linux.intel.com Signed-off-by: Mark Brown <broonie@kernel.org>
1 parent 17b3f99 commit 5a1fa00

3 files changed

Lines changed: 13 additions & 0 deletions

File tree

‎sound/soc/sof/imx/Kconfig‎

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -30,6 +30,7 @@ config SND_SOC_SOF_IMX8_SUPPORT
3030

3131
config SND_SOC_SOF_IMX8
3232
tristate
33+
select SND_SOC_SOF_XTENSA
3334
help
3435
This option is not user-selectable but automagically handled by
3536
'select' statements at a higher level
@@ -44,6 +45,7 @@ config SND_SOC_SOF_IMX8M_SUPPORT
4445

4546
config SND_SOC_SOF_IMX8M
4647
tristate
48+
select SND_SOC_SOF_XTENSA
4749
help
4850
This option is not user-selectable but automagically handled by
4951
'select' statements at a higher level

‎sound/soc/sof/imx/imx8.c‎

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -424,6 +424,9 @@ struct snd_sof_dsp_ops sof_imx8_ops = {
424424
/* firmware loading */
425425
.load_firmware = snd_sof_load_firmware_memcpy,
426426

427+
/* Firmware ops */
428+
.arch_ops = &sof_xtensa_arch_ops,
429+
427430
/* DAI drivers */
428431
.drv = imx8_dai,
429432
.num_drv = ARRAY_SIZE(imx8_dai),
@@ -464,6 +467,9 @@ struct snd_sof_dsp_ops sof_imx8x_ops = {
464467
/* firmware loading */
465468
.load_firmware = snd_sof_load_firmware_memcpy,
466469

470+
/* Firmware ops */
471+
.arch_ops = &sof_xtensa_arch_ops,
472+
467473
/* DAI drivers */
468474
.drv = imx8_dai,
469475
.num_drv = ARRAY_SIZE(imx8_dai),
@@ -477,4 +483,5 @@ struct snd_sof_dsp_ops sof_imx8x_ops = {
477483
};
478484
EXPORT_SYMBOL(sof_imx8x_ops);
479485

486+
MODULE_IMPORT_NS(SND_SOC_SOF_XTENSA);
480487
MODULE_LICENSE("Dual BSD/GPL");

‎sound/soc/sof/imx/imx8m.c‎

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -277,6 +277,9 @@ struct snd_sof_dsp_ops sof_imx8m_ops = {
277277
/* firmware loading */
278278
.load_firmware = snd_sof_load_firmware_memcpy,
279279

280+
/* Firmware ops */
281+
.arch_ops = &sof_xtensa_arch_ops,
282+
280283
/* DAI drivers */
281284
.drv = imx8m_dai,
282285
.num_drv = ARRAY_SIZE(imx8m_dai),
@@ -289,4 +292,5 @@ struct snd_sof_dsp_ops sof_imx8m_ops = {
289292
};
290293
EXPORT_SYMBOL(sof_imx8m_ops);
291294

295+
MODULE_IMPORT_NS(SND_SOC_SOF_XTENSA);
292296
MODULE_LICENSE("Dual BSD/GPL");

0 commit comments

Comments
 (0)