Skip to contentSkip to conversation

ASoC: airoha: fix objtool warning with memif probe loop

PATCH In review Christian Marangi 2 participants 2 messages Nov 24 – Nov 26

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 ASoC: airoha: fix objtool warning with memif probe loop

Objtool produce a warning when clang is used as compiler. This was caused by the memif probe loop when assigning the irq to the memif.

The warning is:

Quoted 1 line
Quoted 1 line

sound/soc/mediatek/an7581/snd-soc-an7581-afe.o: warning: objtool: an7581_afe_pcm_dev_probe(): unexpected end of section .text.an7581_afe_pcm_dev_probe

Fix this by giving a fixed upper bound for the loop for the memif as it seems there are some problem with detecting the runtime value is hardcoded.

Fixes 4974ffa0d6c2 ("ASoC: airoha: Add AFE driver for Airoha AN7581")
---
 sound/soc/mediatek/an7581/an7581-afe-pcm.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
sound/soc/mediatek/an7581/an7581-afe-pcm.c +1 -1
index d47edb630452..b17d58f25d9e 100644
@@ -447,7 +447,7 @@ static int an7581_afe_pcm_dev_probe(struct platform_device *pdev)
 		return irq_id;
 
 	/* init memif */
-	for (i = 0; i < afe->memif_size; i++) {
+	for (i = 0; i < AN7581_MEMIF_NUM; i++) {
 		int sel_irq = an7581_memif_irq_descs[i].irq;
 
 		afe->memif[i].data = &memif_data[i];
Signature · 1 line
2.55.0
maintainer
#1 lore raw
Quoted 1 line · Christian Marangi

ASoC: airoha: fix objtool warning with memif probe loop

Applied to

https://git.kernel.org/pub/scm/linux/kernel/git/broonie/sound.git for-7.5

Thanks!

[1/1] ASoC: airoha: fix objtool warning with memif probe loop

      https://git.kernel.org/broonie/sound/c/61914cb2002a

All being well this means that it will be integrated into the linux-next tree (usually sometime in the next 24 hours) and sent to Linus during the next merge window (or sooner if it is a bug fix), however if problems are discovered then the patch may be dropped or reverted.

You may get further e-mails resulting from automated or manual testing and review of the tree, please engage with people reporting problems and send followup patches addressing any issues that are reported if needed.

If any updates are required or you are submitting further changes they should be sent as incremental updates against current git, existing patches will not be replaced.

Please add any relevant lists and maintainers to the CCs when replying to this mail.

Thanks,
Mark