Re: [PATCH v4 1/4] ASoC: SOF: Intel: Add IRQ chip to distribute the SoundWire IRQ
From: Pierre-Louis Bossart
Date: Tue Nov 24 2026 - 11:50:59 EST
On 11/24/26 17:09, Charles Keepax wrote:
> Add an IRQ chip into the HDA code that can be used to trigger the
> SoundWire IRQ for each link. Currently, only the SoundWire IRQ
> is moved over to this IRQ chip, although in time the other IRQ
> functions could be too.
>
> This will allow refactoring such that the individual links each
> request and free their IRQs locally, rather than having to rely
> on looping over a list of links which is tricky to maintain while
> destroying the devices.
Well, there's no such thing as a per-link SoundWire IRQ...
The hardware is built in such a way that once a global interrupt is
received at the HDAudio controller level, the handler has to check if
this was an IPC, HDA, SoundWire interrupt - in that order. And in the
latter case there's no other way than iterating over each link.
Using an abstraction to make each interrupt source 'self-contained'
would be fine and probably make the code cleaner, but then why stop at
SoundWire? I'd err on the side of 'go big or go home'...
At any rate this would be a significant change on both SOF/HDA and
SoundWire sides that should be handled as a well-tested prerequisite to
the series to allow for communication with the device during remove - it
doesn't seem right as a patch casually added in a v4...