aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi
diff options
context:
space:
mode:
authorJames Smart <James.Smart@Emulex.Com>2006-12-02 13:34:16 -0500
committerJames Bottomley <jejb@mulgrave.il.steeleye.com>2006-12-03 10:29:18 -0500
commita4bc3379fbc368597024104727fdf14ced483c14 (patch)
treeed16c3eb403754d7fb9e8928ecc5a286f10a12d3 /drivers/scsi
parent2fb9bd8b9cbe9a8d70bf5f43a9ee6a4fa565ed5a (diff)
[SCSI] lpfc 8.1.11 : Fix lpfc_multi_ring_support
It was not accounted for in the fast/slow rings. Genericize the implementation and control it via sysfs Signed-off-by: James Smart <James.Smart@emulex.com> Signed-off-by: James Bottomley <James.Bottomley@SteelEye.com>
Diffstat (limited to 'drivers/scsi')
-rw-r--r--drivers/scsi/lpfc/lpfc.h2
-rw-r--r--drivers/scsi/lpfc/lpfc_attr.c21
-rw-r--r--drivers/scsi/lpfc/lpfc_els.c6
-rw-r--r--drivers/scsi/lpfc/lpfc_hbadisc.c12
-rw-r--r--drivers/scsi/lpfc/lpfc_hw.h6
-rw-r--r--drivers/scsi/lpfc/lpfc_init.c4
-rw-r--r--drivers/scsi/lpfc/lpfc_sli.c35
-rw-r--r--drivers/scsi/lpfc/lpfc_sli.h2
8 files changed, 67 insertions, 21 deletions
diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h
index 3f7f5f8abd75..e94190e83fc3 100644
--- a/drivers/scsi/lpfc/lpfc.h
+++ b/drivers/scsi/lpfc/lpfc.h
@@ -296,6 +296,8 @@ struct lpfc_hba {
296 uint32_t cfg_cr_delay; 296 uint32_t cfg_cr_delay;
297 uint32_t cfg_cr_count; 297 uint32_t cfg_cr_count;
298 uint32_t cfg_multi_ring_support; 298 uint32_t cfg_multi_ring_support;
299 uint32_t cfg_multi_ring_rctl;
300 uint32_t cfg_multi_ring_type;
299 uint32_t cfg_fdmi_on; 301 uint32_t cfg_fdmi_on;
300 uint32_t cfg_discovery_threads; 302 uint32_t cfg_discovery_threads;
301 uint32_t cfg_max_luns; 303 uint32_t cfg_max_luns;
diff --git a/drivers/scsi/lpfc/lpfc_attr.c b/drivers/scsi/lpfc/lpfc_attr.c
index 2a4e02e7a392..f05ef3011307 100644
--- a/drivers/scsi/lpfc/lpfc_attr.c
+++ b/drivers/scsi/lpfc/lpfc_attr.c
@@ -802,7 +802,6 @@ static CLASS_DEVICE_ATTR(lpfc_devloss_tmo, S_IRUGO | S_IWUSR,
802# LOG_MBOX 0x4 Mailbox events 802# LOG_MBOX 0x4 Mailbox events
803# LOG_INIT 0x8 Initialization events 803# LOG_INIT 0x8 Initialization events
804# LOG_LINK_EVENT 0x10 Link events 804# LOG_LINK_EVENT 0x10 Link events
805# LOG_IP 0x20 IP traffic history
806# LOG_FCP 0x40 FCP traffic history 805# LOG_FCP 0x40 FCP traffic history
807# LOG_NODE 0x80 Node table events 806# LOG_NODE 0x80 Node table events
808# LOG_MISC 0x400 Miscellaneous events 807# LOG_MISC 0x400 Miscellaneous events
@@ -916,6 +915,22 @@ LPFC_ATTR_R(multi_ring_support, 1, 1, 2, "Determines number of primary "
916 "SLI rings to spread IOCB entries across"); 915 "SLI rings to spread IOCB entries across");
917 916
918/* 917/*
918# lpfc_multi_ring_rctl: If lpfc_multi_ring_support is enabled, this
919# identifies what rctl value to configure the additional ring for.
920# Value range is [1,0xff]. Default value is 4 (Unsolicated Data).
921*/
922LPFC_ATTR_R(multi_ring_rctl, FC_UNSOL_DATA, 1,
923 255, "Identifies RCTL for additional ring configuration");
924
925/*
926# lpfc_multi_ring_type: If lpfc_multi_ring_support is enabled, this
927# identifies what type value to configure the additional ring for.
928# Value range is [1,0xff]. Default value is 5 (LLC/SNAP).
929*/
930LPFC_ATTR_R(multi_ring_type, FC_LLC_SNAP, 1,
931 255, "Identifies TYPE for additional ring configuration");
932
933/*
919# lpfc_fdmi_on: controls FDMI support. 934# lpfc_fdmi_on: controls FDMI support.
920# 0 = no FDMI support 935# 0 = no FDMI support
921# 1 = support FDMI without attribute of hostname 936# 1 = support FDMI without attribute of hostname
@@ -974,6 +989,8 @@ struct class_device_attribute *lpfc_host_attrs[] = {
974 &class_device_attr_lpfc_cr_delay, 989 &class_device_attr_lpfc_cr_delay,
975 &class_device_attr_lpfc_cr_count, 990 &class_device_attr_lpfc_cr_count,
976 &class_device_attr_lpfc_multi_ring_support, 991 &class_device_attr_lpfc_multi_ring_support,
992 &class_device_attr_lpfc_multi_ring_rctl,
993 &class_device_attr_lpfc_multi_ring_type,
977 &class_device_attr_lpfc_fdmi_on, 994 &class_device_attr_lpfc_fdmi_on,
978 &class_device_attr_lpfc_max_luns, 995 &class_device_attr_lpfc_max_luns,
979 &class_device_attr_nport_evt_cnt, 996 &class_device_attr_nport_evt_cnt,
@@ -1771,6 +1788,8 @@ lpfc_get_cfgparam(struct lpfc_hba *phba)
1771 lpfc_cr_delay_init(phba, lpfc_cr_delay); 1788 lpfc_cr_delay_init(phba, lpfc_cr_delay);
1772 lpfc_cr_count_init(phba, lpfc_cr_count); 1789 lpfc_cr_count_init(phba, lpfc_cr_count);
1773 lpfc_multi_ring_support_init(phba, lpfc_multi_ring_support); 1790 lpfc_multi_ring_support_init(phba, lpfc_multi_ring_support);
1791 lpfc_multi_ring_rctl_init(phba, lpfc_multi_ring_rctl);
1792 lpfc_multi_ring_type_init(phba, lpfc_multi_ring_type);
1774 lpfc_lun_queue_depth_init(phba, lpfc_lun_queue_depth); 1793 lpfc_lun_queue_depth_init(phba, lpfc_lun_queue_depth);
1775 lpfc_fcp_class_init(phba, lpfc_fcp_class); 1794 lpfc_fcp_class_init(phba, lpfc_fcp_class);
1776 lpfc_use_adisc_init(phba, lpfc_use_adisc); 1795 lpfc_use_adisc_init(phba, lpfc_use_adisc);
diff --git a/drivers/scsi/lpfc/lpfc_els.c b/drivers/scsi/lpfc/lpfc_els.c
index 60af1c60fe9b..a47e5ab1ec4d 100644
--- a/drivers/scsi/lpfc/lpfc_els.c
+++ b/drivers/scsi/lpfc/lpfc_els.c
@@ -1128,7 +1128,7 @@ lpfc_cmpl_els_adisc(struct lpfc_hba * phba, struct lpfc_iocbq * cmdiocb,
1128 mempool_free(mbox, 1128 mempool_free(mbox,
1129 phba->mbox_mem_pool); 1129 phba->mbox_mem_pool);
1130 lpfc_disc_flush_list(phba); 1130 lpfc_disc_flush_list(phba);
1131 psli->ring[(psli->ip_ring)]. 1131 psli->ring[(psli->extra_ring)].
1132 flag &= 1132 flag &=
1133 ~LPFC_STOP_IOCB_EVENT; 1133 ~LPFC_STOP_IOCB_EVENT;
1134 psli->ring[(psli->fcp_ring)]. 1134 psli->ring[(psli->fcp_ring)].
@@ -3046,7 +3046,7 @@ lpfc_els_rcv_farp(struct lpfc_hba * phba,
3046 /* FARP-REQ received from DID <did> */ 3046 /* FARP-REQ received from DID <did> */
3047 lpfc_printf_log(phba, 3047 lpfc_printf_log(phba,
3048 KERN_INFO, 3048 KERN_INFO,
3049 LOG_IP, 3049 LOG_ELS,
3050 "%d:0601 FARP-REQ received from DID x%x\n", 3050 "%d:0601 FARP-REQ received from DID x%x\n",
3051 phba->brd_no, did); 3051 phba->brd_no, did);
3052 3052
@@ -3108,7 +3108,7 @@ lpfc_els_rcv_farpr(struct lpfc_hba * phba,
3108 /* FARP-RSP received from DID <did> */ 3108 /* FARP-RSP received from DID <did> */
3109 lpfc_printf_log(phba, 3109 lpfc_printf_log(phba,
3110 KERN_INFO, 3110 KERN_INFO,
3111 LOG_IP, 3111 LOG_ELS,
3112 "%d:0600 FARP-RSP received from DID x%x\n", 3112 "%d:0600 FARP-RSP received from DID x%x\n",
3113 phba->brd_no, did); 3113 phba->brd_no, did);
3114 3114
diff --git a/drivers/scsi/lpfc/lpfc_hbadisc.c b/drivers/scsi/lpfc/lpfc_hbadisc.c
index 983faadec5f3..7c28184ad56d 100644
--- a/drivers/scsi/lpfc/lpfc_hbadisc.c
+++ b/drivers/scsi/lpfc/lpfc_hbadisc.c
@@ -525,7 +525,7 @@ lpfc_mbx_cmpl_clear_la(struct lpfc_hba * phba, LPFC_MBOXQ_t * pmb)
525 psli = &phba->sli; 525 psli = &phba->sli;
526 mb = &pmb->mb; 526 mb = &pmb->mb;
527 /* Since we don't do discovery right now, turn these off here */ 527 /* Since we don't do discovery right now, turn these off here */
528 psli->ring[psli->ip_ring].flag &= ~LPFC_STOP_IOCB_EVENT; 528 psli->ring[psli->extra_ring].flag &= ~LPFC_STOP_IOCB_EVENT;
529 psli->ring[psli->fcp_ring].flag &= ~LPFC_STOP_IOCB_EVENT; 529 psli->ring[psli->fcp_ring].flag &= ~LPFC_STOP_IOCB_EVENT;
530 psli->ring[psli->next_ring].flag &= ~LPFC_STOP_IOCB_EVENT; 530 psli->ring[psli->next_ring].flag &= ~LPFC_STOP_IOCB_EVENT;
531 531
@@ -641,7 +641,7 @@ out:
641 if (rc == MBX_NOT_FINISHED) { 641 if (rc == MBX_NOT_FINISHED) {
642 mempool_free(pmb, phba->mbox_mem_pool); 642 mempool_free(pmb, phba->mbox_mem_pool);
643 lpfc_disc_flush_list(phba); 643 lpfc_disc_flush_list(phba);
644 psli->ring[(psli->ip_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 644 psli->ring[(psli->extra_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
645 psli->ring[(psli->fcp_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 645 psli->ring[(psli->fcp_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
646 psli->ring[(psli->next_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 646 psli->ring[(psli->next_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
647 phba->hba_state = LPFC_HBA_READY; 647 phba->hba_state = LPFC_HBA_READY;
@@ -696,7 +696,7 @@ out:
696 == MBX_NOT_FINISHED) { 696 == MBX_NOT_FINISHED) {
697 mempool_free( pmb, phba->mbox_mem_pool); 697 mempool_free( pmb, phba->mbox_mem_pool);
698 lpfc_disc_flush_list(phba); 698 lpfc_disc_flush_list(phba);
699 psli->ring[(psli->ip_ring)].flag &= 699 psli->ring[(psli->extra_ring)].flag &=
700 ~LPFC_STOP_IOCB_EVENT; 700 ~LPFC_STOP_IOCB_EVENT;
701 psli->ring[(psli->fcp_ring)].flag &= 701 psli->ring[(psli->fcp_ring)].flag &=
702 ~LPFC_STOP_IOCB_EVENT; 702 ~LPFC_STOP_IOCB_EVENT;
@@ -1424,7 +1424,7 @@ lpfc_check_sli_ndlp(struct lpfc_hba * phba,
1424 if (iocb->context1 == (uint8_t *) ndlp) 1424 if (iocb->context1 == (uint8_t *) ndlp)
1425 return 1; 1425 return 1;
1426 } 1426 }
1427 } else if (pring->ringno == psli->ip_ring) { 1427 } else if (pring->ringno == psli->extra_ring) {
1428 1428
1429 } else if (pring->ringno == psli->fcp_ring) { 1429 } else if (pring->ringno == psli->fcp_ring) {
1430 /* Skip match check if waiting to relogin to FCP target */ 1430 /* Skip match check if waiting to relogin to FCP target */
@@ -1889,7 +1889,7 @@ lpfc_disc_start(struct lpfc_hba * phba)
1889 if (rc == MBX_NOT_FINISHED) { 1889 if (rc == MBX_NOT_FINISHED) {
1890 mempool_free( mbox, phba->mbox_mem_pool); 1890 mempool_free( mbox, phba->mbox_mem_pool);
1891 lpfc_disc_flush_list(phba); 1891 lpfc_disc_flush_list(phba);
1892 psli->ring[(psli->ip_ring)].flag &= 1892 psli->ring[(psli->extra_ring)].flag &=
1893 ~LPFC_STOP_IOCB_EVENT; 1893 ~LPFC_STOP_IOCB_EVENT;
1894 psli->ring[(psli->fcp_ring)].flag &= 1894 psli->ring[(psli->fcp_ring)].flag &=
1895 ~LPFC_STOP_IOCB_EVENT; 1895 ~LPFC_STOP_IOCB_EVENT;
@@ -2268,7 +2268,7 @@ lpfc_disc_timeout_handler(struct lpfc_hba *phba)
2268 2268
2269 if (clrlaerr) { 2269 if (clrlaerr) {
2270 lpfc_disc_flush_list(phba); 2270 lpfc_disc_flush_list(phba);
2271 psli->ring[(psli->ip_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 2271 psli->ring[(psli->extra_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
2272 psli->ring[(psli->fcp_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 2272 psli->ring[(psli->fcp_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
2273 psli->ring[(psli->next_ring)].flag &= ~LPFC_STOP_IOCB_EVENT; 2273 psli->ring[(psli->next_ring)].flag &= ~LPFC_STOP_IOCB_EVENT;
2274 phba->hba_state = LPFC_HBA_READY; 2274 phba->hba_state = LPFC_HBA_READY;
diff --git a/drivers/scsi/lpfc/lpfc_hw.h b/drivers/scsi/lpfc/lpfc_hw.h
index d7306679f1f9..0d08a50ca41e 100644
--- a/drivers/scsi/lpfc/lpfc_hw.h
+++ b/drivers/scsi/lpfc/lpfc_hw.h
@@ -42,14 +42,14 @@
42#define FCELSSIZE 1024 /* maximum ELS transfer size */ 42#define FCELSSIZE 1024 /* maximum ELS transfer size */
43 43
44#define LPFC_FCP_RING 0 /* ring 0 for FCP initiator commands */ 44#define LPFC_FCP_RING 0 /* ring 0 for FCP initiator commands */
45#define LPFC_IP_RING 1 /* ring 1 for IP commands */ 45#define LPFC_EXTRA_RING 1 /* ring 1 for other protocols */
46#define LPFC_ELS_RING 2 /* ring 2 for ELS commands */ 46#define LPFC_ELS_RING 2 /* ring 2 for ELS commands */
47#define LPFC_FCP_NEXT_RING 3 47#define LPFC_FCP_NEXT_RING 3
48 48
49#define SLI2_IOCB_CMD_R0_ENTRIES 172 /* SLI-2 FCP command ring entries */ 49#define SLI2_IOCB_CMD_R0_ENTRIES 172 /* SLI-2 FCP command ring entries */
50#define SLI2_IOCB_RSP_R0_ENTRIES 134 /* SLI-2 FCP response ring entries */ 50#define SLI2_IOCB_RSP_R0_ENTRIES 134 /* SLI-2 FCP response ring entries */
51#define SLI2_IOCB_CMD_R1_ENTRIES 4 /* SLI-2 IP command ring entries */ 51#define SLI2_IOCB_CMD_R1_ENTRIES 4 /* SLI-2 extra command ring entries */
52#define SLI2_IOCB_RSP_R1_ENTRIES 4 /* SLI-2 IP response ring entries */ 52#define SLI2_IOCB_RSP_R1_ENTRIES 4 /* SLI-2 extra response ring entries */
53#define SLI2_IOCB_CMD_R1XTRA_ENTRIES 36 /* SLI-2 extra FCP cmd ring entries */ 53#define SLI2_IOCB_CMD_R1XTRA_ENTRIES 36 /* SLI-2 extra FCP cmd ring entries */
54#define SLI2_IOCB_RSP_R1XTRA_ENTRIES 52 /* SLI-2 extra FCP rsp ring entries */ 54#define SLI2_IOCB_RSP_R1XTRA_ENTRIES 52 /* SLI-2 extra FCP rsp ring entries */
55#define SLI2_IOCB_CMD_R2_ENTRIES 20 /* SLI-2 ELS command ring entries */ 55#define SLI2_IOCB_CMD_R2_ENTRIES 20 /* SLI-2 ELS command ring entries */
diff --git a/drivers/scsi/lpfc/lpfc_init.c b/drivers/scsi/lpfc/lpfc_init.c
index a5723ad0a099..fd734b0fe95f 100644
--- a/drivers/scsi/lpfc/lpfc_init.c
+++ b/drivers/scsi/lpfc/lpfc_init.c
@@ -349,8 +349,8 @@ lpfc_config_port_post(struct lpfc_hba * phba)
349 phba->hba_state = LPFC_LINK_DOWN; 349 phba->hba_state = LPFC_LINK_DOWN;
350 350
351 /* Only process IOCBs on ring 0 till hba_state is READY */ 351 /* Only process IOCBs on ring 0 till hba_state is READY */
352 if (psli->ring[psli->ip_ring].cmdringaddr) 352 if (psli->ring[psli->extra_ring].cmdringaddr)
353 psli->ring[psli->ip_ring].flag |= LPFC_STOP_IOCB_EVENT; 353 psli->ring[psli->extra_ring].flag |= LPFC_STOP_IOCB_EVENT;
354 if (psli->ring[psli->fcp_ring].cmdringaddr) 354 if (psli->ring[psli->fcp_ring].cmdringaddr)
355 psli->ring[psli->fcp_ring].flag |= LPFC_STOP_IOCB_EVENT; 355 psli->ring[psli->fcp_ring].flag |= LPFC_STOP_IOCB_EVENT;
356 if (psli->ring[psli->next_ring].cmdringaddr) 356 if (psli->ring[psli->next_ring].cmdringaddr)
diff --git a/drivers/scsi/lpfc/lpfc_sli.c b/drivers/scsi/lpfc/lpfc_sli.c
index 582f5ea4e84e..120af3db635a 100644
--- a/drivers/scsi/lpfc/lpfc_sli.c
+++ b/drivers/scsi/lpfc/lpfc_sli.c
@@ -1098,6 +1098,7 @@ lpfc_sli_handle_fast_ring_event(struct lpfc_hba * phba,
1098 lpfc_sli_pcimem_bcopy((uint32_t *) entry, 1098 lpfc_sli_pcimem_bcopy((uint32_t *) entry,
1099 (uint32_t *) &rspiocbq.iocb, 1099 (uint32_t *) &rspiocbq.iocb,
1100 sizeof (IOCB_t)); 1100 sizeof (IOCB_t));
1101 INIT_LIST_HEAD(&(rspiocbq.list));
1101 irsp = &rspiocbq.iocb; 1102 irsp = &rspiocbq.iocb;
1102 1103
1103 type = lpfc_sli_iocb_cmd_type(irsp->ulpCommand & CMD_IOCB_MASK); 1104 type = lpfc_sli_iocb_cmd_type(irsp->ulpCommand & CMD_IOCB_MASK);
@@ -1149,6 +1150,11 @@ lpfc_sli_handle_fast_ring_event(struct lpfc_hba * phba,
1149 } 1150 }
1150 } 1151 }
1151 break; 1152 break;
1153 case LPFC_UNSOL_IOCB:
1154 spin_unlock_irqrestore(phba->host->host_lock, iflag);
1155 lpfc_sli_process_unsol_iocb(phba, pring, &rspiocbq);
1156 spin_lock_irqsave(phba->host->host_lock, iflag);
1157 break;
1152 default: 1158 default:
1153 if (irsp->ulpCommand == CMD_ADAPTER_MSG) { 1159 if (irsp->ulpCommand == CMD_ADAPTER_MSG) {
1154 char adaptermsg[LPFC_MAX_ADPTMSG]; 1160 char adaptermsg[LPFC_MAX_ADPTMSG];
@@ -2472,13 +2478,17 @@ lpfc_extra_ring_setup( struct lpfc_hba *phba)
2472 psli = &phba->sli; 2478 psli = &phba->sli;
2473 2479
2474 /* Adjust cmd/rsp ring iocb entries more evenly */ 2480 /* Adjust cmd/rsp ring iocb entries more evenly */
2481
2482 /* Take some away from the FCP ring */
2475 pring = &psli->ring[psli->fcp_ring]; 2483 pring = &psli->ring[psli->fcp_ring];
2476 pring->numCiocb -= SLI2_IOCB_CMD_R1XTRA_ENTRIES; 2484 pring->numCiocb -= SLI2_IOCB_CMD_R1XTRA_ENTRIES;
2477 pring->numRiocb -= SLI2_IOCB_RSP_R1XTRA_ENTRIES; 2485 pring->numRiocb -= SLI2_IOCB_RSP_R1XTRA_ENTRIES;
2478 pring->numCiocb -= SLI2_IOCB_CMD_R3XTRA_ENTRIES; 2486 pring->numCiocb -= SLI2_IOCB_CMD_R3XTRA_ENTRIES;
2479 pring->numRiocb -= SLI2_IOCB_RSP_R3XTRA_ENTRIES; 2487 pring->numRiocb -= SLI2_IOCB_RSP_R3XTRA_ENTRIES;
2480 2488
2481 pring = &psli->ring[1]; 2489 /* and give them to the extra ring */
2490 pring = &psli->ring[psli->extra_ring];
2491
2482 pring->numCiocb += SLI2_IOCB_CMD_R1XTRA_ENTRIES; 2492 pring->numCiocb += SLI2_IOCB_CMD_R1XTRA_ENTRIES;
2483 pring->numRiocb += SLI2_IOCB_RSP_R1XTRA_ENTRIES; 2493 pring->numRiocb += SLI2_IOCB_RSP_R1XTRA_ENTRIES;
2484 pring->numCiocb += SLI2_IOCB_CMD_R3XTRA_ENTRIES; 2494 pring->numCiocb += SLI2_IOCB_CMD_R3XTRA_ENTRIES;
@@ -2488,8 +2498,8 @@ lpfc_extra_ring_setup( struct lpfc_hba *phba)
2488 pring->iotag_max = 4096; 2498 pring->iotag_max = 4096;
2489 pring->num_mask = 1; 2499 pring->num_mask = 1;
2490 pring->prt[0].profile = 0; /* Mask 0 */ 2500 pring->prt[0].profile = 0; /* Mask 0 */
2491 pring->prt[0].rctl = FC_UNSOL_DATA; 2501 pring->prt[0].rctl = phba->cfg_multi_ring_rctl;
2492 pring->prt[0].type = 5; 2502 pring->prt[0].type = phba->cfg_multi_ring_type;
2493 pring->prt[0].lpfc_sli_rcv_unsol_event = NULL; 2503 pring->prt[0].lpfc_sli_rcv_unsol_event = NULL;
2494 return 0; 2504 return 0;
2495} 2505}
@@ -2505,7 +2515,7 @@ lpfc_sli_setup(struct lpfc_hba *phba)
2505 psli->sli_flag = 0; 2515 psli->sli_flag = 0;
2506 psli->fcp_ring = LPFC_FCP_RING; 2516 psli->fcp_ring = LPFC_FCP_RING;
2507 psli->next_ring = LPFC_FCP_NEXT_RING; 2517 psli->next_ring = LPFC_FCP_NEXT_RING;
2508 psli->ip_ring = LPFC_IP_RING; 2518 psli->extra_ring = LPFC_EXTRA_RING;
2509 2519
2510 psli->iocbq_lookup = NULL; 2520 psli->iocbq_lookup = NULL;
2511 psli->iocbq_lookup_len = 0; 2521 psli->iocbq_lookup_len = 0;
@@ -2528,7 +2538,7 @@ lpfc_sli_setup(struct lpfc_hba *phba)
2528 pring->fast_iotag = pring->iotag_max; 2538 pring->fast_iotag = pring->iotag_max;
2529 pring->num_mask = 0; 2539 pring->num_mask = 0;
2530 break; 2540 break;
2531 case LPFC_IP_RING: /* ring 1 - IP */ 2541 case LPFC_EXTRA_RING: /* ring 1 - EXTRA */
2532 /* numCiocb and numRiocb are used in config_port */ 2542 /* numCiocb and numRiocb are used in config_port */
2533 pring->numCiocb = SLI2_IOCB_CMD_R1_ENTRIES; 2543 pring->numCiocb = SLI2_IOCB_CMD_R1_ENTRIES;
2534 pring->numRiocb = SLI2_IOCB_RSP_R1_ENTRIES; 2544 pring->numRiocb = SLI2_IOCB_RSP_R1_ENTRIES;
@@ -3238,6 +3248,21 @@ lpfc_intr_handler(int irq, void *dev_id)
3238 lpfc_sli_handle_fast_ring_event(phba, 3248 lpfc_sli_handle_fast_ring_event(phba,
3239 &phba->sli.ring[LPFC_FCP_RING], 3249 &phba->sli.ring[LPFC_FCP_RING],
3240 status); 3250 status);
3251
3252 if (phba->cfg_multi_ring_support == 2) {
3253 /*
3254 * Process all events on extra ring. Take the optimized path
3255 * for extra ring IO. Any other IO is slow path and is handled
3256 * by the worker thread.
3257 */
3258 status = (ha_copy & (HA_RXMASK << (4*LPFC_EXTRA_RING)));
3259 status >>= (4*LPFC_EXTRA_RING);
3260 if (status & HA_RXATT) {
3261 lpfc_sli_handle_fast_ring_event(phba,
3262 &phba->sli.ring[LPFC_EXTRA_RING],
3263 status);
3264 }
3265 }
3241 return IRQ_HANDLED; 3266 return IRQ_HANDLED;
3242 3267
3243} /* lpfc_intr_handler */ 3268} /* lpfc_intr_handler */
diff --git a/drivers/scsi/lpfc/lpfc_sli.h b/drivers/scsi/lpfc/lpfc_sli.h
index e26de6809358..a43549959dc7 100644
--- a/drivers/scsi/lpfc/lpfc_sli.h
+++ b/drivers/scsi/lpfc/lpfc_sli.h
@@ -198,7 +198,7 @@ struct lpfc_sli {
198 int fcp_ring; /* ring used for FCP initiator commands */ 198 int fcp_ring; /* ring used for FCP initiator commands */
199 int next_ring; 199 int next_ring;
200 200
201 int ip_ring; /* ring used for IP network drv cmds */ 201 int extra_ring; /* extra ring used for other protocols */
202 202
203 struct lpfc_sli_stat slistat; /* SLI statistical info */ 203 struct lpfc_sli_stat slistat; /* SLI statistical info */
204 struct list_head mboxq; 204 struct list_head mboxq;