diff options
Diffstat (limited to 'drivers/scsi/mpt2sas/mpt2sas_base.h')
-rw-r--r-- | drivers/scsi/mpt2sas/mpt2sas_base.h | 77 |
1 files changed, 69 insertions, 8 deletions
diff --git a/drivers/scsi/mpt2sas/mpt2sas_base.h b/drivers/scsi/mpt2sas/mpt2sas_base.h index dcc289c25459..8d5be2120c63 100644 --- a/drivers/scsi/mpt2sas/mpt2sas_base.h +++ b/drivers/scsi/mpt2sas/mpt2sas_base.h | |||
@@ -69,11 +69,11 @@ | |||
69 | #define MPT2SAS_DRIVER_NAME "mpt2sas" | 69 | #define MPT2SAS_DRIVER_NAME "mpt2sas" |
70 | #define MPT2SAS_AUTHOR "LSI Corporation <DL-MPTFusionLinux@lsi.com>" | 70 | #define MPT2SAS_AUTHOR "LSI Corporation <DL-MPTFusionLinux@lsi.com>" |
71 | #define MPT2SAS_DESCRIPTION "LSI MPT Fusion SAS 2.0 Device Driver" | 71 | #define MPT2SAS_DESCRIPTION "LSI MPT Fusion SAS 2.0 Device Driver" |
72 | #define MPT2SAS_DRIVER_VERSION "08.100.00.02" | 72 | #define MPT2SAS_DRIVER_VERSION "09.100.00.00" |
73 | #define MPT2SAS_MAJOR_VERSION 08 | 73 | #define MPT2SAS_MAJOR_VERSION 09 |
74 | #define MPT2SAS_MINOR_VERSION 100 | 74 | #define MPT2SAS_MINOR_VERSION 100 |
75 | #define MPT2SAS_BUILD_VERSION 00 | 75 | #define MPT2SAS_BUILD_VERSION 00 |
76 | #define MPT2SAS_RELEASE_VERSION 02 | 76 | #define MPT2SAS_RELEASE_VERSION 00 |
77 | 77 | ||
78 | /* | 78 | /* |
79 | * Set MPT2SAS_SG_DEPTH value based on user input. | 79 | * Set MPT2SAS_SG_DEPTH value based on user input. |
@@ -161,12 +161,15 @@ | |||
161 | "Intel Integrated RAID Module RMS2LL080" | 161 | "Intel Integrated RAID Module RMS2LL080" |
162 | #define MPT2SAS_INTEL_RMS2LL040_BRANDING \ | 162 | #define MPT2SAS_INTEL_RMS2LL040_BRANDING \ |
163 | "Intel Integrated RAID Module RMS2LL040" | 163 | "Intel Integrated RAID Module RMS2LL040" |
164 | #define MPT2SAS_INTEL_RS25GB008_BRANDING \ | ||
165 | "Intel(R) RAID Controller RS25GB008" | ||
164 | 166 | ||
165 | /* | 167 | /* |
166 | * Intel HBA SSDIDs | 168 | * Intel HBA SSDIDs |
167 | */ | 169 | */ |
168 | #define MPT2SAS_INTEL_RMS2LL080_SSDID 0x350E | 170 | #define MPT2SAS_INTEL_RMS2LL080_SSDID 0x350E |
169 | #define MPT2SAS_INTEL_RMS2LL040_SSDID 0x350F | 171 | #define MPT2SAS_INTEL_RMS2LL040_SSDID 0x350F |
172 | #define MPT2SAS_INTEL_RS25GB008_SSDID 0x3000 | ||
170 | 173 | ||
171 | 174 | ||
172 | /* | 175 | /* |
@@ -541,6 +544,63 @@ struct _tr_list { | |||
541 | 544 | ||
542 | typedef void (*MPT_ADD_SGE)(void *paddr, u32 flags_length, dma_addr_t dma_addr); | 545 | typedef void (*MPT_ADD_SGE)(void *paddr, u32 flags_length, dma_addr_t dma_addr); |
543 | 546 | ||
547 | /* IOC Facts and Port Facts converted from little endian to cpu */ | ||
548 | union mpi2_version_union { | ||
549 | MPI2_VERSION_STRUCT Struct; | ||
550 | u32 Word; | ||
551 | }; | ||
552 | |||
553 | struct mpt2sas_facts { | ||
554 | u16 MsgVersion; | ||
555 | u16 HeaderVersion; | ||
556 | u8 IOCNumber; | ||
557 | u8 VP_ID; | ||
558 | u8 VF_ID; | ||
559 | u16 IOCExceptions; | ||
560 | u16 IOCStatus; | ||
561 | u32 IOCLogInfo; | ||
562 | u8 MaxChainDepth; | ||
563 | u8 WhoInit; | ||
564 | u8 NumberOfPorts; | ||
565 | u8 MaxMSIxVectors; | ||
566 | u16 RequestCredit; | ||
567 | u16 ProductID; | ||
568 | u32 IOCCapabilities; | ||
569 | union mpi2_version_union FWVersion; | ||
570 | u16 IOCRequestFrameSize; | ||
571 | u16 Reserved3; | ||
572 | u16 MaxInitiators; | ||
573 | u16 MaxTargets; | ||
574 | u16 MaxSasExpanders; | ||
575 | u16 MaxEnclosures; | ||
576 | u16 ProtocolFlags; | ||
577 | u16 HighPriorityCredit; | ||
578 | u16 MaxReplyDescriptorPostQueueDepth; | ||
579 | u8 ReplyFrameSize; | ||
580 | u8 MaxVolumes; | ||
581 | u16 MaxDevHandle; | ||
582 | u16 MaxPersistentEntries; | ||
583 | u16 MinDevHandle; | ||
584 | }; | ||
585 | |||
586 | struct mpt2sas_port_facts { | ||
587 | u8 PortNumber; | ||
588 | u8 VP_ID; | ||
589 | u8 VF_ID; | ||
590 | u8 PortType; | ||
591 | u16 MaxPostedCmdBuffers; | ||
592 | }; | ||
593 | |||
594 | /** | ||
595 | * enum mutex_type - task management mutex type | ||
596 | * @TM_MUTEX_OFF: mutex is not required becuase calling function is acquiring it | ||
597 | * @TM_MUTEX_ON: mutex is required | ||
598 | */ | ||
599 | enum mutex_type { | ||
600 | TM_MUTEX_OFF = 0, | ||
601 | TM_MUTEX_ON = 1, | ||
602 | }; | ||
603 | |||
544 | /** | 604 | /** |
545 | * struct MPT2SAS_ADAPTER - per adapter struct | 605 | * struct MPT2SAS_ADAPTER - per adapter struct |
546 | * @list: ioc_list | 606 | * @list: ioc_list |
@@ -703,6 +763,7 @@ struct MPT2SAS_ADAPTER { | |||
703 | /* misc flags */ | 763 | /* misc flags */ |
704 | int aen_event_read_flag; | 764 | int aen_event_read_flag; |
705 | u8 broadcast_aen_busy; | 765 | u8 broadcast_aen_busy; |
766 | u16 broadcast_aen_pending; | ||
706 | u8 shost_recovery; | 767 | u8 shost_recovery; |
707 | 768 | ||
708 | struct mutex reset_in_progress_mutex; | 769 | struct mutex reset_in_progress_mutex; |
@@ -749,8 +810,8 @@ struct MPT2SAS_ADAPTER { | |||
749 | u32 event_masks[MPI2_EVENT_NOTIFY_EVENTMASK_WORDS]; | 810 | u32 event_masks[MPI2_EVENT_NOTIFY_EVENTMASK_WORDS]; |
750 | 811 | ||
751 | /* static config pages */ | 812 | /* static config pages */ |
752 | Mpi2IOCFactsReply_t facts; | 813 | struct mpt2sas_facts facts; |
753 | Mpi2PortFactsReply_t *pfacts; | 814 | struct mpt2sas_port_facts *pfacts; |
754 | Mpi2ManufacturingPage0_t manu_pg0; | 815 | Mpi2ManufacturingPage0_t manu_pg0; |
755 | Mpi2BiosPage2_t bios_pg2; | 816 | Mpi2BiosPage2_t bios_pg2; |
756 | Mpi2BiosPage3_t bios_pg3; | 817 | Mpi2BiosPage3_t bios_pg3; |
@@ -840,7 +901,7 @@ struct MPT2SAS_ADAPTER { | |||
840 | 901 | ||
841 | /* reply free queue */ | 902 | /* reply free queue */ |
842 | u16 reply_free_queue_depth; | 903 | u16 reply_free_queue_depth; |
843 | u32 *reply_free; | 904 | __le32 *reply_free; |
844 | dma_addr_t reply_free_dma; | 905 | dma_addr_t reply_free_dma; |
845 | struct dma_pool *reply_free_dma_pool; | 906 | struct dma_pool *reply_free_dma_pool; |
846 | u32 reply_free_host_index; | 907 | u32 reply_free_host_index; |
@@ -932,8 +993,8 @@ void mpt2sas_halt_firmware(struct MPT2SAS_ADAPTER *ioc); | |||
932 | u8 mpt2sas_scsih_event_callback(struct MPT2SAS_ADAPTER *ioc, u8 msix_index, | 993 | u8 mpt2sas_scsih_event_callback(struct MPT2SAS_ADAPTER *ioc, u8 msix_index, |
933 | u32 reply); | 994 | u32 reply); |
934 | int mpt2sas_scsih_issue_tm(struct MPT2SAS_ADAPTER *ioc, u16 handle, | 995 | int mpt2sas_scsih_issue_tm(struct MPT2SAS_ADAPTER *ioc, u16 handle, |
935 | uint channel, uint id, uint lun, u8 type, u16 smid_task, | 996 | uint channel, uint id, uint lun, u8 type, u16 smid_task, |
936 | ulong timeout, struct scsi_cmnd *scmd); | 997 | ulong timeout, unsigned long serial_number, enum mutex_type m_type); |
937 | void mpt2sas_scsih_set_tm_flag(struct MPT2SAS_ADAPTER *ioc, u16 handle); | 998 | void mpt2sas_scsih_set_tm_flag(struct MPT2SAS_ADAPTER *ioc, u16 handle); |
938 | void mpt2sas_scsih_clear_tm_flag(struct MPT2SAS_ADAPTER *ioc, u16 handle); | 999 | void mpt2sas_scsih_clear_tm_flag(struct MPT2SAS_ADAPTER *ioc, u16 handle); |
939 | void mpt2sas_expander_remove(struct MPT2SAS_ADAPTER *ioc, u64 sas_address); | 1000 | void mpt2sas_expander_remove(struct MPT2SAS_ADAPTER *ioc, u64 sas_address); |