* [PATCH] ASoC: sti: Return irqreturn_t instead of -EPERM in uni_player_irq_handler()
@ 2026-11-19 17:11 Ian Rogers
0 siblings, 0 replies; only message in thread
From: Ian Rogers @ 2026-11-19 17:11 UTC (permalink / raw)
To: Arnaud Pouliquen, Liam Girdwood, Mark Brown, Jaroslav Kysela,
Takashi Iwai
Cc: linux-sound, linux-kernel, llvm, Elkin Cruz, Ian Rogers
When UNIPERIF_ITM_UNDERFLOW_REC_DONE_MASK fires while
player->underflow_enabled is false, uni_player_irq_handler() sets
ret = -EPERM and returns it as irqreturn_t. Returning a negative errno
from a hardirq handler triggers report_bad_irq() in note_interrupt()
and bypasses unhandled-IRQ storm accounting (while also clobbering
IRQ_HANDLED if an earlier status bit was handled in the same call).
Leave ret unchanged (IRQ_NONE by default, or IRQ_HANDLED if an earlier
error bit was handled) instead of overwriting it with -EPERM.
Found via Clang -Wassign-enum on an x86_64 allyesconfig build.
Verified by building sound/soc/sti/uniperif_player.o with LLVM=1 W=1
(-Werror) and -Wassign-enum; not runtime-tested on STi hardware.
Fixes: 76c2145ded6b ("ASoC: sti: Add CPU DAI driver for playback")
Signed-off-by: Ian Rogers <irogers@google.com>
---
sound/soc/sti/uniperif_player.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/sound/soc/sti/uniperif_player.c b/sound/soc/sti/uniperif_player.c
index 844ddcfc421a..63dfe2b4d304 100644
--- a/sound/soc/sti/uniperif_player.c
+++ b/sound/soc/sti/uniperif_player.c
@@ -117,7 +117,6 @@ static irqreturn_t uni_player_irq_handler(int irq, void *dev_id)
if (!player->underflow_enabled) {
dev_err(player->dev,
"unexpected Underflow recovering\n");
- ret = -EPERM;
snd_pcm_stream_unlock(player->substream);
return ret;
}
--
2.56.1.708.g77570a6a1d-goog
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-11-19 17:11 UTC | newest]
Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2026-11-19 17:11 [PATCH] ASoC: sti: Return irqreturn_t instead of -EPERM in uni_player_irq_handler() Ian Rogers
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®