Skip to content

Commit 897df60

Browse files
Mani-Sadhasivammartinkpetersen
authored andcommitted
scsi: ufs: pltfrm: Dellocate HBA during ufshcd_pltfrm_remove()
This will ensure that the scsi host is cleaned up properly using scsi_host_dev_release(). Otherwise, it may lead to memory leaks. Cc: [email protected] # 4.4 Fixes: 03b1781 ("[SCSI] ufs: Add Platform glue driver for ufshcd") Signed-off-by: Manivannan Sadhasivam <[email protected]> Link: https://lore.kernel.org/r/[email protected] Reviewed-by: Peter Wang <[email protected]> Reviewed-by: Bean Huo <[email protected]> Reviewed-by: Bart Van Assche <[email protected]> Signed-off-by: Martin K. Petersen <[email protected]>
1 parent 1745dcd commit 897df60

File tree

1 file changed

+1
-0
lines changed

1 file changed

+1
-0
lines changed

drivers/ufs/host/ufshcd-pltfrm.c

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -534,6 +534,7 @@ void ufshcd_pltfrm_remove(struct platform_device *pdev)
534534

535535
pm_runtime_get_sync(&pdev->dev);
536536
ufshcd_remove(hba);
537+
ufshcd_dealloc_host(hba);
537538
pm_runtime_disable(&pdev->dev);
538539
pm_runtime_put_noidle(&pdev->dev);
539540
}

0 commit comments

Comments
 (0)