diff options
Diffstat (limited to 'drivers')
-rw-r--r-- | drivers/scsi/mpt2sas/mpt2sas_base.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/scsi/mpt2sas/mpt2sas_base.c b/drivers/scsi/mpt2sas/mpt2sas_base.c index c29c4f9851b9..35a13867495e 100644 --- a/drivers/scsi/mpt2sas/mpt2sas_base.c +++ b/drivers/scsi/mpt2sas/mpt2sas_base.c | |||
@@ -1171,7 +1171,6 @@ mpt2sas_base_map_resources(struct MPT2SAS_ADAPTER *ioc) | |||
1171 | } | 1171 | } |
1172 | } | 1172 | } |
1173 | 1173 | ||
1174 | pci_set_drvdata(pdev, ioc->shost); | ||
1175 | _base_mask_interrupts(ioc); | 1174 | _base_mask_interrupts(ioc); |
1176 | r = _base_enable_msix(ioc); | 1175 | r = _base_enable_msix(ioc); |
1177 | if (r) | 1176 | if (r) |
@@ -1194,7 +1193,6 @@ mpt2sas_base_map_resources(struct MPT2SAS_ADAPTER *ioc) | |||
1194 | ioc->pci_irq = -1; | 1193 | ioc->pci_irq = -1; |
1195 | pci_release_selected_regions(ioc->pdev, ioc->bars); | 1194 | pci_release_selected_regions(ioc->pdev, ioc->bars); |
1196 | pci_disable_device(pdev); | 1195 | pci_disable_device(pdev); |
1197 | pci_set_drvdata(pdev, NULL); | ||
1198 | return r; | 1196 | return r; |
1199 | } | 1197 | } |
1200 | 1198 | ||
@@ -3253,7 +3251,6 @@ mpt2sas_base_free_resources(struct MPT2SAS_ADAPTER *ioc) | |||
3253 | ioc->chip_phys = 0; | 3251 | ioc->chip_phys = 0; |
3254 | pci_release_selected_regions(ioc->pdev, ioc->bars); | 3252 | pci_release_selected_regions(ioc->pdev, ioc->bars); |
3255 | pci_disable_device(pdev); | 3253 | pci_disable_device(pdev); |
3256 | pci_set_drvdata(pdev, NULL); | ||
3257 | return; | 3254 | return; |
3258 | } | 3255 | } |
3259 | 3256 | ||
@@ -3275,6 +3272,7 @@ mpt2sas_base_attach(struct MPT2SAS_ADAPTER *ioc) | |||
3275 | if (r) | 3272 | if (r) |
3276 | return r; | 3273 | return r; |
3277 | 3274 | ||
3275 | pci_set_drvdata(ioc->pdev, ioc->shost); | ||
3278 | r = _base_make_ioc_ready(ioc, CAN_SLEEP, SOFT_RESET); | 3276 | r = _base_make_ioc_ready(ioc, CAN_SLEEP, SOFT_RESET); |
3279 | if (r) | 3277 | if (r) |
3280 | goto out_free_resources; | 3278 | goto out_free_resources; |
@@ -3357,6 +3355,7 @@ mpt2sas_base_attach(struct MPT2SAS_ADAPTER *ioc) | |||
3357 | ioc->remove_host = 1; | 3355 | ioc->remove_host = 1; |
3358 | mpt2sas_base_free_resources(ioc); | 3356 | mpt2sas_base_free_resources(ioc); |
3359 | _base_release_memory_pools(ioc); | 3357 | _base_release_memory_pools(ioc); |
3358 | pci_set_drvdata(ioc->pdev, NULL); | ||
3360 | kfree(ioc->tm_cmds.reply); | 3359 | kfree(ioc->tm_cmds.reply); |
3361 | kfree(ioc->transport_cmds.reply); | 3360 | kfree(ioc->transport_cmds.reply); |
3362 | kfree(ioc->config_cmds.reply); | 3361 | kfree(ioc->config_cmds.reply); |
@@ -3389,6 +3388,7 @@ mpt2sas_base_detach(struct MPT2SAS_ADAPTER *ioc) | |||
3389 | mpt2sas_base_stop_watchdog(ioc); | 3388 | mpt2sas_base_stop_watchdog(ioc); |
3390 | mpt2sas_base_free_resources(ioc); | 3389 | mpt2sas_base_free_resources(ioc); |
3391 | _base_release_memory_pools(ioc); | 3390 | _base_release_memory_pools(ioc); |
3391 | pci_set_drvdata(ioc->pdev, NULL); | ||
3392 | kfree(ioc->pfacts); | 3392 | kfree(ioc->pfacts); |
3393 | kfree(ioc->ctl_cmds.reply); | 3393 | kfree(ioc->ctl_cmds.reply); |
3394 | kfree(ioc->base_cmds.reply); | 3394 | kfree(ioc->base_cmds.reply); |