diff options
Diffstat (limited to 'drivers/scsi/lpfc/lpfc.h')
-rw-r--r-- | drivers/scsi/lpfc/lpfc.h | 26 |
1 files changed, 24 insertions, 2 deletions
diff --git a/drivers/scsi/lpfc/lpfc.h b/drivers/scsi/lpfc/lpfc.h index 196de40b906c..746dd3d7a092 100644 --- a/drivers/scsi/lpfc/lpfc.h +++ b/drivers/scsi/lpfc/lpfc.h | |||
@@ -464,12 +464,29 @@ struct unsol_rcv_ct_ctx { | |||
464 | #define UNSOL_VALID 0x00000001 | 464 | #define UNSOL_VALID 0x00000001 |
465 | }; | 465 | }; |
466 | 466 | ||
467 | #define LPFC_USER_LINK_SPEED_AUTO 0 /* auto select (default)*/ | ||
468 | #define LPFC_USER_LINK_SPEED_1G 1 /* 1 Gigabaud */ | ||
469 | #define LPFC_USER_LINK_SPEED_2G 2 /* 2 Gigabaud */ | ||
470 | #define LPFC_USER_LINK_SPEED_4G 4 /* 4 Gigabaud */ | ||
471 | #define LPFC_USER_LINK_SPEED_8G 8 /* 8 Gigabaud */ | ||
472 | #define LPFC_USER_LINK_SPEED_10G 10 /* 10 Gigabaud */ | ||
473 | #define LPFC_USER_LINK_SPEED_16G 16 /* 16 Gigabaud */ | ||
474 | #define LPFC_USER_LINK_SPEED_MAX LPFC_USER_LINK_SPEED_16G | ||
475 | #define LPFC_USER_LINK_SPEED_BITMAP ((1 << LPFC_USER_LINK_SPEED_16G) | \ | ||
476 | (1 << LPFC_USER_LINK_SPEED_10G) | \ | ||
477 | (1 << LPFC_USER_LINK_SPEED_8G) | \ | ||
478 | (1 << LPFC_USER_LINK_SPEED_4G) | \ | ||
479 | (1 << LPFC_USER_LINK_SPEED_2G) | \ | ||
480 | (1 << LPFC_USER_LINK_SPEED_1G) | \ | ||
481 | (1 << LPFC_USER_LINK_SPEED_AUTO)) | ||
482 | #define LPFC_LINK_SPEED_STRING "0, 1, 2, 4, 8, 10, 16" | ||
483 | |||
467 | struct lpfc_hba { | 484 | struct lpfc_hba { |
468 | /* SCSI interface function jump table entries */ | 485 | /* SCSI interface function jump table entries */ |
469 | int (*lpfc_new_scsi_buf) | 486 | int (*lpfc_new_scsi_buf) |
470 | (struct lpfc_vport *, int); | 487 | (struct lpfc_vport *, int); |
471 | struct lpfc_scsi_buf * (*lpfc_get_scsi_buf) | 488 | struct lpfc_scsi_buf * (*lpfc_get_scsi_buf) |
472 | (struct lpfc_hba *); | 489 | (struct lpfc_hba *, struct lpfc_nodelist *); |
473 | int (*lpfc_scsi_prep_dma_buf) | 490 | int (*lpfc_scsi_prep_dma_buf) |
474 | (struct lpfc_hba *, struct lpfc_scsi_buf *); | 491 | (struct lpfc_hba *, struct lpfc_scsi_buf *); |
475 | void (*lpfc_scsi_unprep_dma_buf) | 492 | void (*lpfc_scsi_unprep_dma_buf) |
@@ -545,7 +562,7 @@ struct lpfc_hba { | |||
545 | uint32_t hba_flag; /* hba generic flags */ | 562 | uint32_t hba_flag; /* hba generic flags */ |
546 | #define HBA_ERATT_HANDLED 0x1 /* This flag is set when eratt handled */ | 563 | #define HBA_ERATT_HANDLED 0x1 /* This flag is set when eratt handled */ |
547 | #define DEFER_ERATT 0x2 /* Deferred error attention in progress */ | 564 | #define DEFER_ERATT 0x2 /* Deferred error attention in progress */ |
548 | #define HBA_FCOE_SUPPORT 0x4 /* HBA function supports FCOE */ | 565 | #define HBA_FCOE_MODE 0x4 /* HBA function in FCoE Mode */ |
549 | #define HBA_SP_QUEUE_EVT 0x8 /* Slow-path qevt posted to worker thread*/ | 566 | #define HBA_SP_QUEUE_EVT 0x8 /* Slow-path qevt posted to worker thread*/ |
550 | #define HBA_POST_RECEIVE_BUFFER 0x10 /* Rcv buffers need to be posted */ | 567 | #define HBA_POST_RECEIVE_BUFFER 0x10 /* Rcv buffers need to be posted */ |
551 | #define FCP_XRI_ABORT_EVENT 0x20 | 568 | #define FCP_XRI_ABORT_EVENT 0x20 |
@@ -557,6 +574,7 @@ struct lpfc_hba { | |||
557 | #define HBA_FIP_SUPPORT 0x800 /* FIP support in HBA */ | 574 | #define HBA_FIP_SUPPORT 0x800 /* FIP support in HBA */ |
558 | #define HBA_AER_ENABLED 0x1000 /* AER enabled with HBA */ | 575 | #define HBA_AER_ENABLED 0x1000 /* AER enabled with HBA */ |
559 | #define HBA_DEVLOSS_TMO 0x2000 /* HBA in devloss timeout */ | 576 | #define HBA_DEVLOSS_TMO 0x2000 /* HBA in devloss timeout */ |
577 | #define HBA_RRQ_ACTIVE 0x4000 /* process the rrq active list */ | ||
560 | uint32_t fcp_ring_in_use; /* When polling test if intr-hndlr active*/ | 578 | uint32_t fcp_ring_in_use; /* When polling test if intr-hndlr active*/ |
561 | struct lpfc_dmabuf slim2p; | 579 | struct lpfc_dmabuf slim2p; |
562 | 580 | ||
@@ -606,6 +624,7 @@ struct lpfc_hba { | |||
606 | /* HBA Config Parameters */ | 624 | /* HBA Config Parameters */ |
607 | uint32_t cfg_ack0; | 625 | uint32_t cfg_ack0; |
608 | uint32_t cfg_enable_npiv; | 626 | uint32_t cfg_enable_npiv; |
627 | uint32_t cfg_enable_rrq; | ||
609 | uint32_t cfg_topology; | 628 | uint32_t cfg_topology; |
610 | uint32_t cfg_link_speed; | 629 | uint32_t cfg_link_speed; |
611 | uint32_t cfg_cr_delay; | 630 | uint32_t cfg_cr_delay; |
@@ -716,6 +735,7 @@ struct lpfc_hba { | |||
716 | uint32_t total_scsi_bufs; | 735 | uint32_t total_scsi_bufs; |
717 | struct list_head lpfc_iocb_list; | 736 | struct list_head lpfc_iocb_list; |
718 | uint32_t total_iocbq_bufs; | 737 | uint32_t total_iocbq_bufs; |
738 | struct list_head active_rrq_list; | ||
719 | spinlock_t hbalock; | 739 | spinlock_t hbalock; |
720 | 740 | ||
721 | /* pci_mem_pools */ | 741 | /* pci_mem_pools */ |
@@ -728,6 +748,7 @@ struct lpfc_hba { | |||
728 | 748 | ||
729 | mempool_t *mbox_mem_pool; | 749 | mempool_t *mbox_mem_pool; |
730 | mempool_t *nlp_mem_pool; | 750 | mempool_t *nlp_mem_pool; |
751 | mempool_t *rrq_pool; | ||
731 | 752 | ||
732 | struct fc_host_statistics link_stats; | 753 | struct fc_host_statistics link_stats; |
733 | enum intr_type_t intr_type; | 754 | enum intr_type_t intr_type; |
@@ -784,6 +805,7 @@ struct lpfc_hba { | |||
784 | unsigned long skipped_hb; | 805 | unsigned long skipped_hb; |
785 | struct timer_list hb_tmofunc; | 806 | struct timer_list hb_tmofunc; |
786 | uint8_t hb_outstanding; | 807 | uint8_t hb_outstanding; |
808 | struct timer_list rrq_tmr; | ||
787 | enum hba_temp_state over_temp_state; | 809 | enum hba_temp_state over_temp_state; |
788 | /* ndlp reference management */ | 810 | /* ndlp reference management */ |
789 | spinlock_t ndlp_lock; | 811 | spinlock_t ndlp_lock; |