diff options
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_init.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_init.c | 22 |
1 files changed, 10 insertions, 12 deletions
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c index 66d5d003555d..908d0f27706f 100644 --- a/drivers/scsi/lpfc/lpfc_init.c +++ b/drivers/scsi/lpfc/lpfc_init.c | |||
@@ -294,15 +294,6 @@ lpfc_config_port_post(struct lpfc_hba * phba) | |||
294 | } | 294 | } |
295 | } | 295 | } |
296 | 296 | ||
297 | /* This should turn on DELAYED ABTS for ELS timeouts */ | ||
298 | lpfc_set_slim(phba, pmb, 0x052198, 0x1); | ||
299 | if (lpfc_sli_issue_mbox(phba, pmb, MBX_POLL) != MBX_SUCCESS) { | ||
300 | phba->hba_state = LPFC_HBA_ERROR; | ||
301 | mempool_free( pmb, phba->mbox_mem_pool); | ||
302 | return -EIO; | ||
303 | } | ||
304 | |||
305 | |||
306 | lpfc_read_config(phba, pmb); | 297 | lpfc_read_config(phba, pmb); |
307 | if (lpfc_sli_issue_mbox(phba, pmb, MBX_POLL) != MBX_SUCCESS) { | 298 | if (lpfc_sli_issue_mbox(phba, pmb, MBX_POLL) != MBX_SUCCESS) { |
308 | lpfc_printf_log(phba, | 299 | lpfc_printf_log(phba, |
@@ -804,7 +795,7 @@ lpfc_get_hba_model_desc(struct lpfc_hba * phba, uint8_t * mdp, uint8_t * descp) | |||
804 | int max_speed; | 795 | int max_speed; |
805 | char * ports; | 796 | char * ports; |
806 | char * bus; | 797 | char * bus; |
807 | } m; | 798 | } m = {"<Unknown>", 0, "", ""}; |
808 | 799 | ||
809 | pci_read_config_byte(phba->pcidev, PCI_HEADER_TYPE, &hdrtype); | 800 | pci_read_config_byte(phba->pcidev, PCI_HEADER_TYPE, &hdrtype); |
810 | ports = (hdrtype == 0x80) ? "2-port " : ""; | 801 | ports = (hdrtype == 0x80) ? "2-port " : ""; |
@@ -1627,7 +1618,7 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1627 | 1618 | ||
1628 | error = lpfc_alloc_sysfs_attr(phba); | 1619 | error = lpfc_alloc_sysfs_attr(phba); |
1629 | if (error) | 1620 | if (error) |
1630 | goto out_kthread_stop; | 1621 | goto out_remove_host; |
1631 | 1622 | ||
1632 | error = request_irq(phba->pcidev->irq, lpfc_intr_handler, SA_SHIRQ, | 1623 | error = request_irq(phba->pcidev->irq, lpfc_intr_handler, SA_SHIRQ, |
1633 | LPFC_DRIVER_NAME, phba); | 1624 | LPFC_DRIVER_NAME, phba); |
@@ -1644,8 +1635,10 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1644 | phba->HCregaddr = phba->ctrl_regs_memmap_p + HC_REG_OFFSET; | 1635 | phba->HCregaddr = phba->ctrl_regs_memmap_p + HC_REG_OFFSET; |
1645 | 1636 | ||
1646 | error = lpfc_sli_hba_setup(phba); | 1637 | error = lpfc_sli_hba_setup(phba); |
1647 | if (error) | 1638 | if (error) { |
1639 | error = -ENODEV; | ||
1648 | goto out_free_irq; | 1640 | goto out_free_irq; |
1641 | } | ||
1649 | 1642 | ||
1650 | if (phba->cfg_poll & DISABLE_FCP_RING_INT) { | 1643 | if (phba->cfg_poll & DISABLE_FCP_RING_INT) { |
1651 | spin_lock_irq(phba->host->host_lock); | 1644 | spin_lock_irq(phba->host->host_lock); |
@@ -1700,6 +1693,9 @@ out_free_irq: | |||
1700 | free_irq(phba->pcidev->irq, phba); | 1693 | free_irq(phba->pcidev->irq, phba); |
1701 | out_free_sysfs_attr: | 1694 | out_free_sysfs_attr: |
1702 | lpfc_free_sysfs_attr(phba); | 1695 | lpfc_free_sysfs_attr(phba); |
1696 | out_remove_host: | ||
1697 | fc_remove_host(phba->host); | ||
1698 | scsi_remove_host(phba->host); | ||
1703 | out_kthread_stop: | 1699 | out_kthread_stop: |
1704 | kthread_stop(phba->worker_thread); | 1700 | kthread_stop(phba->worker_thread); |
1705 | out_free_iocbq: | 1701 | out_free_iocbq: |
@@ -1721,12 +1717,14 @@ out_iounmap_slim: | |||
1721 | out_idr_remove: | 1717 | out_idr_remove: |
1722 | idr_remove(&lpfc_hba_index, phba->brd_no); | 1718 | idr_remove(&lpfc_hba_index, phba->brd_no); |
1723 | out_put_host: | 1719 | out_put_host: |
1720 | phba->host = NULL; | ||
1724 | scsi_host_put(host); | 1721 | scsi_host_put(host); |
1725 | out_release_regions: | 1722 | out_release_regions: |
1726 | pci_release_regions(pdev); | 1723 | pci_release_regions(pdev); |
1727 | out_disable_device: | 1724 | out_disable_device: |
1728 | pci_disable_device(pdev); | 1725 | pci_disable_device(pdev); |
1729 | out: | 1726 | out: |
1727 | pci_set_drvdata(pdev, NULL); | ||
1730 | return error; | 1728 | return error; |
1731 | } | 1729 | } |
1732 | 1730 | ||