diff options
Diffstat (limited to 'drivers/scsi/lpfc/lpfc_init.c')
-rw-r--r-- | drivers/scsi/lpfc/lpfc_init.c | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c index 766dac230a6c..db3c2ad4e941 100644 --- a/drivers/scsi/lpfc/lpfc_init.c +++ b/drivers/scsi/lpfc/lpfc_init.c | |||
@@ -370,6 +370,10 @@ lpfc_config_port_post(struct lpfc_hba * phba) | |||
370 | if (psli->num_rings > 3) | 370 | if (psli->num_rings > 3) |
371 | status |= HC_R3INT_ENA; | 371 | status |= HC_R3INT_ENA; |
372 | 372 | ||
373 | if ((phba->cfg_poll & ENABLE_FCP_RING_POLLING) && | ||
374 | (phba->cfg_poll & DISABLE_FCP_RING_INT)) | ||
375 | status &= ~(HC_R0INT_ENA << LPFC_FCP_RING); | ||
376 | |||
373 | writel(status, phba->HCregaddr); | 377 | writel(status, phba->HCregaddr); |
374 | readl(phba->HCregaddr); /* flush */ | 378 | readl(phba->HCregaddr); /* flush */ |
375 | spin_unlock_irq(phba->host->host_lock); | 379 | spin_unlock_irq(phba->host->host_lock); |
@@ -1237,6 +1241,7 @@ lpfc_stop_timer(struct lpfc_hba * phba) | |||
1237 | } | 1241 | } |
1238 | } | 1242 | } |
1239 | 1243 | ||
1244 | del_timer_sync(&phba->fcp_poll_timer); | ||
1240 | del_timer_sync(&phba->fc_estabtmo); | 1245 | del_timer_sync(&phba->fc_estabtmo); |
1241 | del_timer_sync(&phba->fc_disctmo); | 1246 | del_timer_sync(&phba->fc_disctmo); |
1242 | del_timer_sync(&phba->fc_fdmitmo); | 1247 | del_timer_sync(&phba->fc_fdmitmo); |
@@ -1416,6 +1421,10 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1416 | psli->mbox_tmo.function = lpfc_mbox_timeout; | 1421 | psli->mbox_tmo.function = lpfc_mbox_timeout; |
1417 | psli->mbox_tmo.data = (unsigned long)phba; | 1422 | psli->mbox_tmo.data = (unsigned long)phba; |
1418 | 1423 | ||
1424 | init_timer(&phba->fcp_poll_timer); | ||
1425 | phba->fcp_poll_timer.function = lpfc_poll_timeout; | ||
1426 | phba->fcp_poll_timer.data = (unsigned long)phba; | ||
1427 | |||
1419 | /* | 1428 | /* |
1420 | * Get all the module params for configuring this host and then | 1429 | * Get all the module params for configuring this host and then |
1421 | * establish the host parameters. | 1430 | * establish the host parameters. |
@@ -1530,6 +1539,7 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1530 | host->max_cmd_len = 16; | 1539 | host->max_cmd_len = 16; |
1531 | 1540 | ||
1532 | /* Initialize the list of scsi buffers used by driver for scsi IO. */ | 1541 | /* Initialize the list of scsi buffers used by driver for scsi IO. */ |
1542 | spin_lock_init(&phba->scsi_buf_list_lock); | ||
1533 | INIT_LIST_HEAD(&phba->lpfc_scsi_buf_list); | 1543 | INIT_LIST_HEAD(&phba->lpfc_scsi_buf_list); |
1534 | 1544 | ||
1535 | host->transportt = lpfc_transport_template; | 1545 | host->transportt = lpfc_transport_template; |
@@ -1561,6 +1571,12 @@ lpfc_pci_probe_one(struct pci_dev *pdev, const struct pci_device_id *pid) | |||
1561 | if (error) | 1571 | if (error) |
1562 | goto out_free_irq; | 1572 | goto out_free_irq; |
1563 | 1573 | ||
1574 | if (phba->cfg_poll & DISABLE_FCP_RING_INT) { | ||
1575 | spin_lock_irq(phba->host->host_lock); | ||
1576 | lpfc_poll_start_timer(phba); | ||
1577 | spin_unlock_irq(phba->host->host_lock); | ||
1578 | } | ||
1579 | |||
1564 | /* | 1580 | /* |
1565 | * set fixed host attributes | 1581 | * set fixed host attributes |
1566 | * Must done after lpfc_sli_hba_setup() | 1582 | * Must done after lpfc_sli_hba_setup() |