[RFC PATCH 0/1] dmaengine: apple-admac: should manual unbind be disabled?
Fan Wu <[email protected]> Sun, 26 Jul 2026 05:29:49 +0000
| Newsgroups | dev.linux.lists.asahi,org.infradead.lists.linux-arm-kernel,org.kernel.vger.dmaengine,org.kernel.vger.linux-kernel |
|---|---|
| Message-ID | <[email protected]> |
This RFC asks whether manual unbind of the apple-admac DMA controller should be disabled. apple-admac stores its dma_device and channels in devm-managed memory and does not implement dma_device.device_release. At registration, the DMAengine core emits a diagnostic that the driver is not safe to unbind while in use, and on channel unregister it emits WARN_ONCE if a channel still has clients. admac_data is released by devres after admac_remove() returns, so if a client still holds a channel at that point it may reference the freed dma_chan and admac_data. As the controller is a fixed SoC resource, the patch removes the standard driver-core sysfs bind/unbind controls. It also opts the driver out of CONFIG_DEBUG_TEST_DRIVER_REMOVE. This RFC does not define behavior for other removal paths, such as device or DT-overlay removal. Guidance is requested on whether this restriction is appropriate, or whether the driver should retain manual bind/unbind support. This issue was found by an in-house static analysis tool. Fan Wu (1): dmaengine: apple-admac: suppress bind/unbind sysfs attributes drivers/dma/apple-admac.c | 1 + 1 file changed, 1 insertion(+) -- 2.34.1