dmaengine: fix memleak in dma_async_device_unregister
PATCH 1/1 dmaengine: fix memleak in dma_async_device_unregister
While debugging a dma driver I noticed a memleak after unloading the driver module.
Caught by kmemleak.
Signed-off-by Anatolij Gustschin <[email protected]>
Cc Maciej Sosnowski <[email protected]>
Cc Dan Williams <[email protected]>
--- drivers/dma/dmaengine.c | 1 + 1 files changed, 1 insertions(+), 0 deletions(-)
drivers/dma/dmaengine.c +1 -0
@@ -826,6 +826,7 @@ void dma_async_device_unregister(struct dma_device *device) chan->dev->chan =NULL ;mutex_unlock (&dma_list_mutex);device_unregister (&chan->dev->device); +free_percpu (chan->local); } }EXPORT_SYMBOL (dma_async_device_unregister);
Signature · 1 line
1.6.2.5