Commit e40c04ad authored by Tomas Henzl's avatar Tomas Henzl Committed by Martin K. Petersen

scsi: mpt3sas: Fix in error path

The driver should be deregistered as misc driver after PCI registration
failure.
Signed-off-by: default avatarTomas Henzl <thenzl@redhat.com>
Link: https://lore.kernel.org/r/20231015114529.10725-1-thenzl@redhat.comSigned-off-by: default avatarMartin K. Petersen <martin.petersen@oracle.com>
parent a20c4350
......@@ -12913,8 +12913,10 @@ _mpt3sas_init(void)
mpt3sas_ctl_init(hbas_to_enumerate);
error = pci_register_driver(&mpt3sas_driver);
if (error)
if (error) {
mpt3sas_ctl_exit(hbas_to_enumerate);
scsih_exit();
}
return error;
}
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment