dmaengine: Call module_put() after device_free_chan_resources()
The module reference is taken to ensure the callbacks still exist when they are called. If the channel holds the last reference to the module, the module can disappear before device_free_chan_resources() is called and would cause a call into free'd memory. Signed-off-by: Logan Gunthorpe <logang@deltatee.com> Link: https://lore.kernel.org/r/20191216190120.21374-3-logang@deltatee.comSigned-off-by: Vinod Koul <vkoul@kernel.org>
Showing
Please register or sign in to comment