mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 18:41:58 +09:00
scsi: mpi3mr: Fix config page DMA memory leak
[ Upstream commit7d2b02172b] A fix for: DMA-API: pci 0000:83:00.0: device driver has pending DMA allocations while released from device [count=1] Fixes:32d457d5a2("scsi: mpi3mr: Add framework to issue config requests") Signed-off-by: Tomas Henzl <thenzl@redhat.com> Link: https://lore.kernel.org/r/20230302234336.25456-3-thenzl@redhat.com Acked-by: Sathya Prakash Veerichetty <sathya.prakash@broadcom.com> Signed-off-by: Martin K. Petersen <martin.petersen@oracle.com> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
574cc10eda
commit
dca06ccf13
@@ -4351,7 +4351,11 @@ void mpi3mr_free_mem(struct mpi3mr_ioc *mrioc)
|
||||
mrioc->admin_req_base, mrioc->admin_req_dma);
|
||||
mrioc->admin_req_base = NULL;
|
||||
}
|
||||
|
||||
if (mrioc->cfg_page) {
|
||||
dma_free_coherent(&mrioc->pdev->dev, mrioc->cfg_page_sz,
|
||||
mrioc->cfg_page, mrioc->cfg_page_dma);
|
||||
mrioc->cfg_page = NULL;
|
||||
}
|
||||
if (mrioc->pel_seqnum_virt) {
|
||||
dma_free_coherent(&mrioc->pdev->dev, mrioc->pel_seqnum_sz,
|
||||
mrioc->pel_seqnum_virt, mrioc->pel_seqnum_dma);
|
||||
|
||||
Reference in New Issue
Block a user