В ядре Linux была устранена следующая уязвимость: ASoC: amd: ps: fix snd_acp63_remove() sharedown ordering The ACP IRQ dereference the SoundWire, SoundWire DMA и PDM child platform devices, но snd_acp63_remove() отменяет их, пока прерывание все еще удерживается devres, что освобождает его только после удаления возврата. Перерыв в этом окне — это use-after-free. Маскируйте источники прерываний ACP и вызывайте devm_free_irq() до того, как первое дочернее устройство будет незарегистрировано.
Маскировка проходит через новый коллбек acp_hw_ops->disable_interrupts, сохраняя агностику платформы remove path. Линия прерывания является общей, и acp_hw_deinit () очищает источники только после того, как дети ушли, что оставило бы линию поднятой без обработчика. devm_free_irq() ждет обработчиков в полете, но не для работы, которую уже поставил в очередь hardirq: acp63_irq_handler() расписания amd_sdw_irq_thread на менеджере SoundWire. Удаление этой работы в пути удаления менеджера является изменением на стороне звуковой проводки и следует отдельно.
Эта проблема была обнаружена с помощью внутреннего инструмента статического анализа.
Показать оригинальное описание (EN)
In the Linux kernel, the following vulnerability has been resolved: ASoC: amd: ps: fix snd_acp63_remove() teardown ordering The ACP IRQ handlers dereference the SoundWire, SoundWire DMA, and PDM child platform devices, but snd_acp63_remove() unregisters them while the interrupt is still held by devres, which frees it only after remove returns. An interrupt in this window is a use-after-free. Mask the ACP interrupt sources and call devm_free_irq() before the first child device is unregistered. The masking goes through the new acp_hw_ops->disable_interrupts callback, keeping the remove path platform-agnostic. The interrupt line is shared, and acp_hw_deinit() clears the sources only after the children are gone, which would leave the line raised with no handler left to ack it. The window predates the tagged refactor, which only reshaped the dereferences. devm_free_irq() waits for in-flight handlers, but not for work the hardirq has already queued: acp63_irq_handler() schedules amd_sdw_irq_thread on the SoundWire manager. Draining that work in the manager's remove path is a soundwire-side change and follows separately. This issue was found by an in-house static analysis tool.