mpt3sas: suppress a warning in debug kernel
Subsystems (2)
PATCH 1/1 mpt3sas: suppress a warning in debug kernel
The mpt3sas_ctl_exit should be called after communication with the controller stops but in the current place it may cause false warnings about memory not released.
Fix it by moving the call right after mpt3sas_base_detach.
Signed-off-by Tomas Henzl <[email protected]>
--- drivers/scsi/mpt3sas/mpt3sas_scsih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
drivers/scsi/mpt3sas/mpt3sas_scsih.c +1 -2
@@ -11350,6 +11350,7 @@ static void scsih_remove(struct pci_dev *pdev) }mpt3sas_base_detach (ioc); +mpt3sas_ctl_exit (hbas_to_enumerate);spin_lock (&gioc_lock);list_del (&ioc->list);spin_unlock (&gioc_lock);
@@ -12931,8 +12932,6 @@ _mpt3sas_exit(void)pci_unregister_driver (&mpt3sas_driver); -mpt3sas_ctl_exit (hbas_to_enumerate); -scsih_exit (); }
Signature · 1 line
2.41.0
There might be an issue related to this patch, I shall post a modified V2.
Please drop this patch.
Quoted 31 lines · Tomas Henzl
The
mpt3sas_ctl_exitshould be called after communication with the controller stops but in the current place it may cause false warnings about memory not released.
Fix it by moving the call right aftermpt3sas_base_detach.Signed-off-by Tomas Henzl <[email protected]>--- drivers/scsi/mpt3sas/mpt3sas_scsih.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)drivers/scsi/mpt3sas/mpt3sas_scsih.c +1
-2@@ -11350,6 +11350,7 @@ static void scsih_remove(struct pci_dev *pdev) }mpt3sas_base_detach (ioc); +mpt3sas_ctl_exit (hbas_to_enumerate);spin_lock (&gioc_lock);list_del (&ioc->list);spin_unlock (&gioc_lock);@@ -12931,8 +12932,6 @@ _mpt3sas_exit(void)pci_unregister_driver (&mpt3sas_driver); -mpt3sas_ctl_exit (hbas_to_enumerate); -scsih_exit (); }