1098ca2bdSWarner Losh /*- 2*7282444bSPedro F. Giffuni * SPDX-License-Identifier: BSD-3-Clause 3*7282444bSPedro F. Giffuni * 412af29abSMarius Strobl * Copyright (c) 2000-2010, LSI Logic Corporation and its contributors. 5b0a2fdeeSScott Long * All rights reserved. 6d3ecac66SMatt Jacob * 7d3ecac66SMatt Jacob * Redistribution and use in source and binary forms, with or without 8b0a2fdeeSScott Long * modification, are permitted provided that the following conditions are 9b0a2fdeeSScott Long * met: 10d3ecac66SMatt Jacob * 1. Redistributions of source code must retain the above copyright 11b0a2fdeeSScott Long * notice, this list of conditions and the following disclaimer. 12b0a2fdeeSScott Long * 2. Redistributions in binary form must reproduce at minimum a disclaimer 13b0a2fdeeSScott Long * substantially similar to the "NO WARRANTY" disclaimer below 14b0a2fdeeSScott Long * ("Disclaimer") and any redistribution must be conditioned upon including 15b0a2fdeeSScott Long * a substantially similar Disclaimer requirement for further binary 16b0a2fdeeSScott Long * redistribution. 17b0a2fdeeSScott Long * 3. Neither the name of the LSI Logic Corporation nor the names of its 18b0a2fdeeSScott Long * contributors may be used to endorse or promote products derived from 19b0a2fdeeSScott Long * this software without specific prior written permission. 20d3ecac66SMatt Jacob * 21b0a2fdeeSScott Long * THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS" 22b0a2fdeeSScott Long * AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE 23d3ecac66SMatt Jacob * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE 24b0a2fdeeSScott Long * ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE 25b0a2fdeeSScott Long * LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR 26b0a2fdeeSScott Long * CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF 27b0a2fdeeSScott Long * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS 28b0a2fdeeSScott Long * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN 29b0a2fdeeSScott Long * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) 30b0a2fdeeSScott Long * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF THE COPYRIGHT 31b0a2fdeeSScott Long * OWNER OR CONTRIBUTOR IS ADVISED OF THE POSSIBILITY OF SUCH DAMAGE. 329b631363SMatt Jacob * 339de3c85cSMatt Jacob * Name: mpi_init.h 349b631363SMatt Jacob * Title: MPI initiator mode messages and structures 359b631363SMatt Jacob * Creation Date: June 8, 2000 369b631363SMatt Jacob * 3762ae194dSScott Long * mpi_init.h Version: 01.05.09 389b631363SMatt Jacob * 399b631363SMatt Jacob * Version History 409b631363SMatt Jacob * --------------- 419b631363SMatt Jacob * 429b631363SMatt Jacob * Date Version Description 439b631363SMatt Jacob * -------- -------- ------------------------------------------------------ 449b631363SMatt Jacob * 05-08-00 00.10.01 Original release for 0.10 spec dated 4/26/2000. 459b631363SMatt Jacob * 05-24-00 00.10.02 Added SenseBufferLength to _MSG_SCSI_IO_REPLY. 469b631363SMatt Jacob * 06-06-00 01.00.01 Update version number for 1.0 release. 479b631363SMatt Jacob * 06-08-00 01.00.02 Added MPI_SCSI_RSP_INFO_ definitions. 489b631363SMatt Jacob * 11-02-00 01.01.01 Original release for post 1.0 work. 499b631363SMatt Jacob * 12-04-00 01.01.02 Added MPI_SCSIIO_CONTROL_NO_DISCONNECT. 509b631363SMatt Jacob * 02-20-01 01.01.03 Started using MPI_POINTER. 519b631363SMatt Jacob * 03-27-01 01.01.04 Added structure offset comments. 529b631363SMatt Jacob * 04-10-01 01.01.05 Added new MsgFlag for MSG_SCSI_TASK_MGMT. 539b631363SMatt Jacob * 08-08-01 01.02.01 Original release for v1.2 work. 549b631363SMatt Jacob * 08-29-01 01.02.02 Added MPI_SCSITASKMGMT_TASKTYPE_LOGICAL_UNIT_RESET. 559b631363SMatt Jacob * Added MPI_SCSI_STATE_QUEUE_TAG_REJECTED for 569b631363SMatt Jacob * MSG_SCSI_IO_REPLY. 579b631363SMatt Jacob * 09-28-01 01.02.03 Added structures and defines for SCSI Enclosure 589b631363SMatt Jacob * Processor messages. 599b631363SMatt Jacob * 10-04-01 01.02.04 Added defines for SEP request Action field. 607fed69eeSMatt Jacob * 05-31-02 01.02.05 Added MPI_SCSIIO_MSGFLGS_CMD_DETERMINES_DATA_DIR define 617fed69eeSMatt Jacob * for SCSI IO requests. 627fed69eeSMatt Jacob * 11-15-02 01.02.06 Added special extended SCSI Status defines for FCP. 63b0a2fdeeSScott Long * 06-26-03 01.02.07 Added MPI_SCSI_STATUS_FCPEXT_UNASSIGNED define. 649de3c85cSMatt Jacob * 05-11-04 01.03.01 Original release for MPI v1.3. 659de3c85cSMatt Jacob * 08-19-04 01.05.01 Added MsgFlags defines for EEDP to SCSI IO request. 669de3c85cSMatt Jacob * Added new word to MSG_SCSI_IO_REPLY to add TaskTag field 679de3c85cSMatt Jacob * and a reserved U16. 689de3c85cSMatt Jacob * Added new MSG_SCSI_IO32_REQUEST structure. 699de3c85cSMatt Jacob * Added a TaskType of Clear Task Set to SCSI 709de3c85cSMatt Jacob * Task Management request. 719de3c85cSMatt Jacob * 12-07-04 01.05.02 Added support for Task Management Query Task. 729de3c85cSMatt Jacob * 01-15-05 01.05.03 Modified SCSI Enclosure Processor Request to support 739de3c85cSMatt Jacob * WWID addressing. 749de3c85cSMatt Jacob * 03-11-05 01.05.04 Removed EEDP flags from SCSI IO Request. 759de3c85cSMatt Jacob * Removed SCSI IO 32 Request. 769de3c85cSMatt Jacob * Modified SCSI Enclosure Processor Request and Reply to 779de3c85cSMatt Jacob * support Enclosure/Slot addressing rather than WWID 789de3c85cSMatt Jacob * addressing. 799de3c85cSMatt Jacob * 06-24-05 01.05.05 Added SCSI IO 32 structures and defines. 809de3c85cSMatt Jacob * Added four new defines for SEP SlotStatus. 819de3c85cSMatt Jacob * 08-03-05 01.05.06 Fixed some MPI_SCSIIO32_MSGFLGS_ defines to make them 829de3c85cSMatt Jacob * unique in the first 32 characters. 8362ae194dSScott Long * 03-27-06 01.05.07 Added Task Management type of Clear ACA. 8462ae194dSScott Long * 10-11-06 01.05.08 Shortened define for Task Management type of Clear ACA. 8562ae194dSScott Long * 02-28-07 01.05.09 Defined two new MsgFlags bits for SCSI Task Management 8662ae194dSScott Long * Request: Do Not Send Task IU and Soft Reset Option. 879b631363SMatt Jacob * -------------------------------------------------------------------------- 889b631363SMatt Jacob */ 899b631363SMatt Jacob 909b631363SMatt Jacob #ifndef MPI_INIT_H 919b631363SMatt Jacob #define MPI_INIT_H 929b631363SMatt Jacob 939b631363SMatt Jacob /***************************************************************************** 949b631363SMatt Jacob * 959b631363SMatt Jacob * S C S I I n i t i a t o r M e s s a g e s 969b631363SMatt Jacob * 979b631363SMatt Jacob *****************************************************************************/ 989b631363SMatt Jacob 999b631363SMatt Jacob /****************************************************************************/ 1009de3c85cSMatt Jacob /* SCSI IO messages and associated structures */ 1019b631363SMatt Jacob /****************************************************************************/ 1029b631363SMatt Jacob 1039b631363SMatt Jacob typedef struct _MSG_SCSI_IO_REQUEST 1049b631363SMatt Jacob { 1059b631363SMatt Jacob U8 TargetID; /* 00h */ 1069b631363SMatt Jacob U8 Bus; /* 01h */ 1079b631363SMatt Jacob U8 ChainOffset; /* 02h */ 1089b631363SMatt Jacob U8 Function; /* 03h */ 1099b631363SMatt Jacob U8 CDBLength; /* 04h */ 1109b631363SMatt Jacob U8 SenseBufferLength; /* 05h */ 1119b631363SMatt Jacob U8 Reserved; /* 06h */ 1129b631363SMatt Jacob U8 MsgFlags; /* 07h */ 1139b631363SMatt Jacob U32 MsgContext; /* 08h */ 1149b631363SMatt Jacob U8 LUN[8]; /* 0Ch */ 1159b631363SMatt Jacob U32 Control; /* 14h */ 1169b631363SMatt Jacob U8 CDB[16]; /* 18h */ 1179b631363SMatt Jacob U32 DataLength; /* 28h */ 1189b631363SMatt Jacob U32 SenseBufferLowAddr; /* 2Ch */ 1199b631363SMatt Jacob SGE_IO_UNION SGL; /* 30h */ 1209b631363SMatt Jacob } MSG_SCSI_IO_REQUEST, MPI_POINTER PTR_MSG_SCSI_IO_REQUEST, 1219b631363SMatt Jacob SCSIIORequest_t, MPI_POINTER pSCSIIORequest_t; 1229b631363SMatt Jacob 1237fed69eeSMatt Jacob /* SCSI IO MsgFlags bits */ 1249b631363SMatt Jacob 1259b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_WIDTH (0x01) 1269b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_WIDTH_32 (0x00) 1279b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_WIDTH_64 (0x01) 1289de3c85cSMatt Jacob 1299b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_LOCATION (0x02) 1309b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_LOC_HOST (0x00) 1319b631363SMatt Jacob #define MPI_SCSIIO_MSGFLGS_SENSE_LOC_IOC (0x02) 1329de3c85cSMatt Jacob 1337fed69eeSMatt Jacob #define MPI_SCSIIO_MSGFLGS_CMD_DETERMINES_DATA_DIR (0x04) 1349b631363SMatt Jacob 1359b631363SMatt Jacob /* SCSI IO LUN fields */ 1369b631363SMatt Jacob 1379b631363SMatt Jacob #define MPI_SCSIIO_LUN_FIRST_LEVEL_ADDRESSING (0x0000FFFF) 1389b631363SMatt Jacob #define MPI_SCSIIO_LUN_SECOND_LEVEL_ADDRESSING (0xFFFF0000) 1399b631363SMatt Jacob #define MPI_SCSIIO_LUN_THIRD_LEVEL_ADDRESSING (0x0000FFFF) 1409b631363SMatt Jacob #define MPI_SCSIIO_LUN_FOURTH_LEVEL_ADDRESSING (0xFFFF0000) 1419b631363SMatt Jacob #define MPI_SCSIIO_LUN_LEVEL_1_WORD (0xFF00) 1429b631363SMatt Jacob #define MPI_SCSIIO_LUN_LEVEL_1_DWORD (0x0000FF00) 1439b631363SMatt Jacob 1447fed69eeSMatt Jacob /* SCSI IO Control bits */ 1459b631363SMatt Jacob 1469b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_DATADIRECTION_MASK (0x03000000) 1479b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_NODATATRANSFER (0x00000000) 1489b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_WRITE (0x01000000) 1499b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_READ (0x02000000) 1509b631363SMatt Jacob 1519b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_ADDCDBLEN_MASK (0x3C000000) 1529b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_ADDCDBLEN_SHIFT (26) 1539b631363SMatt Jacob 1549b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_TASKATTRIBUTE_MASK (0x00000700) 1559b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_SIMPLEQ (0x00000000) 1569b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_HEADOFQ (0x00000100) 1579b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_ORDEREDQ (0x00000200) 1589b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_ACAQ (0x00000400) 1599b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_UNTAGGED (0x00000500) 1609b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_NO_DISCONNECT (0x00000700) 1619b631363SMatt Jacob 1629b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_TASKMANAGE_MASK (0x00FF0000) 1639b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_OBSOLETE (0x00800000) 1649b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_CLEAR_ACA_RSV (0x00400000) 1659b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_TARGET_RESET (0x00200000) 1669b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_LUN_RESET_RSV (0x00100000) 1679b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_RESERVED (0x00080000) 1689b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_CLR_TASK_SET_RSV (0x00040000) 1699b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_ABORT_TASK_SET (0x00020000) 1709b631363SMatt Jacob #define MPI_SCSIIO_CONTROL_RESERVED2 (0x00010000) 1719b631363SMatt Jacob 1729b631363SMatt Jacob /* SCSI IO reply structure */ 1739b631363SMatt Jacob typedef struct _MSG_SCSI_IO_REPLY 1749b631363SMatt Jacob { 1759b631363SMatt Jacob U8 TargetID; /* 00h */ 1769b631363SMatt Jacob U8 Bus; /* 01h */ 1779b631363SMatt Jacob U8 MsgLength; /* 02h */ 1789b631363SMatt Jacob U8 Function; /* 03h */ 1799b631363SMatt Jacob U8 CDBLength; /* 04h */ 1809b631363SMatt Jacob U8 SenseBufferLength; /* 05h */ 1819b631363SMatt Jacob U8 Reserved; /* 06h */ 1829b631363SMatt Jacob U8 MsgFlags; /* 07h */ 1839b631363SMatt Jacob U32 MsgContext; /* 08h */ 1849b631363SMatt Jacob U8 SCSIStatus; /* 0Ch */ 1859b631363SMatt Jacob U8 SCSIState; /* 0Dh */ 1869b631363SMatt Jacob U16 IOCStatus; /* 0Eh */ 1879b631363SMatt Jacob U32 IOCLogInfo; /* 10h */ 1889b631363SMatt Jacob U32 TransferCount; /* 14h */ 1899b631363SMatt Jacob U32 SenseCount; /* 18h */ 1909b631363SMatt Jacob U32 ResponseInfo; /* 1Ch */ 1919de3c85cSMatt Jacob U16 TaskTag; /* 20h */ 1929de3c85cSMatt Jacob U16 Reserved1; /* 22h */ 1939b631363SMatt Jacob } MSG_SCSI_IO_REPLY, MPI_POINTER PTR_MSG_SCSI_IO_REPLY, 1949b631363SMatt Jacob SCSIIOReply_t, MPI_POINTER pSCSIIOReply_t; 1959b631363SMatt Jacob 1969b631363SMatt Jacob /* SCSI IO Reply SCSIStatus values (SAM-2 status codes) */ 1979b631363SMatt Jacob 1989b631363SMatt Jacob #define MPI_SCSI_STATUS_SUCCESS (0x00) 1999b631363SMatt Jacob #define MPI_SCSI_STATUS_CHECK_CONDITION (0x02) 2009b631363SMatt Jacob #define MPI_SCSI_STATUS_CONDITION_MET (0x04) 2019b631363SMatt Jacob #define MPI_SCSI_STATUS_BUSY (0x08) 2029b631363SMatt Jacob #define MPI_SCSI_STATUS_INTERMEDIATE (0x10) 2039b631363SMatt Jacob #define MPI_SCSI_STATUS_INTERMEDIATE_CONDMET (0x14) 2049b631363SMatt Jacob #define MPI_SCSI_STATUS_RESERVATION_CONFLICT (0x18) 2059b631363SMatt Jacob #define MPI_SCSI_STATUS_COMMAND_TERMINATED (0x22) 2069b631363SMatt Jacob #define MPI_SCSI_STATUS_TASK_SET_FULL (0x28) 2079b631363SMatt Jacob #define MPI_SCSI_STATUS_ACA_ACTIVE (0x30) 2089b631363SMatt Jacob 2097fed69eeSMatt Jacob #define MPI_SCSI_STATUS_FCPEXT_DEVICE_LOGGED_OUT (0x80) 2107fed69eeSMatt Jacob #define MPI_SCSI_STATUS_FCPEXT_NO_LINK (0x81) 211b0a2fdeeSScott Long #define MPI_SCSI_STATUS_FCPEXT_UNASSIGNED (0x82) 2127fed69eeSMatt Jacob 2139b631363SMatt Jacob /* SCSI IO Reply SCSIState values */ 2149b631363SMatt Jacob 2159b631363SMatt Jacob #define MPI_SCSI_STATE_AUTOSENSE_VALID (0x01) 2169b631363SMatt Jacob #define MPI_SCSI_STATE_AUTOSENSE_FAILED (0x02) 2179b631363SMatt Jacob #define MPI_SCSI_STATE_NO_SCSI_STATUS (0x04) 2189b631363SMatt Jacob #define MPI_SCSI_STATE_TERMINATED (0x08) 2199b631363SMatt Jacob #define MPI_SCSI_STATE_RESPONSE_INFO_VALID (0x10) 2209b631363SMatt Jacob #define MPI_SCSI_STATE_QUEUE_TAG_REJECTED (0x20) 2219b631363SMatt Jacob 2229b631363SMatt Jacob /* SCSI IO Reply ResponseInfo values */ 2239b631363SMatt Jacob /* (FCP-1 RSP_CODE values and SPI-3 Packetized Failure codes) */ 2249b631363SMatt Jacob 2259b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_FUNCTION_COMPLETE (0x00000000) 2269b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_FCP_BURST_LEN_ERROR (0x01000000) 2279b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_CMND_FIELDS_INVALID (0x02000000) 2289b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_FCP_DATA_RO_ERROR (0x03000000) 2299b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_TASK_MGMT_UNSUPPORTED (0x04000000) 2309b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_TASK_MGMT_FAILED (0x05000000) 2319b631363SMatt Jacob #define MPI_SCSI_RSP_INFO_SPI_LQ_INVALID_TYPE (0x06000000) 2329b631363SMatt Jacob 2339de3c85cSMatt Jacob #define MPI_SCSI_TASKTAG_UNKNOWN (0xFFFF) 2349de3c85cSMatt Jacob 2359de3c85cSMatt Jacob /****************************************************************************/ 2369de3c85cSMatt Jacob /* SCSI IO 32 messages and associated structures */ 2379de3c85cSMatt Jacob /****************************************************************************/ 2389de3c85cSMatt Jacob 2399de3c85cSMatt Jacob typedef struct 2409de3c85cSMatt Jacob { 2419de3c85cSMatt Jacob U8 CDB[20]; /* 00h */ 2429de3c85cSMatt Jacob U32 PrimaryReferenceTag; /* 14h */ 2439de3c85cSMatt Jacob U16 PrimaryApplicationTag; /* 18h */ 2449de3c85cSMatt Jacob U16 PrimaryApplicationTagMask; /* 1Ah */ 2459de3c85cSMatt Jacob U32 TransferLength; /* 1Ch */ 2469de3c85cSMatt Jacob } MPI_SCSI_IO32_CDB_EEDP32, MPI_POINTER PTR_MPI_SCSI_IO32_CDB_EEDP32, 2479de3c85cSMatt Jacob MpiScsiIo32CdbEedp32_t, MPI_POINTER pMpiScsiIo32CdbEedp32_t; 2489de3c85cSMatt Jacob 2499de3c85cSMatt Jacob typedef struct 2509de3c85cSMatt Jacob { 2519de3c85cSMatt Jacob U8 CDB[16]; /* 00h */ 2529de3c85cSMatt Jacob U32 DataLength; /* 10h */ 2539de3c85cSMatt Jacob U32 PrimaryReferenceTag; /* 14h */ 2549de3c85cSMatt Jacob U16 PrimaryApplicationTag; /* 18h */ 2559de3c85cSMatt Jacob U16 PrimaryApplicationTagMask; /* 1Ah */ 2569de3c85cSMatt Jacob U32 TransferLength; /* 1Ch */ 2579de3c85cSMatt Jacob } MPI_SCSI_IO32_CDB_EEDP16, MPI_POINTER PTR_MPI_SCSI_IO32_CDB_EEDP16, 2589de3c85cSMatt Jacob MpiScsiIo32CdbEedp16_t, MPI_POINTER pMpiScsiIo32CdbEedp16_t; 2599de3c85cSMatt Jacob 2609de3c85cSMatt Jacob typedef union 2619de3c85cSMatt Jacob { 2629de3c85cSMatt Jacob U8 CDB32[32]; 2639de3c85cSMatt Jacob MPI_SCSI_IO32_CDB_EEDP32 EEDP32; 2649de3c85cSMatt Jacob MPI_SCSI_IO32_CDB_EEDP16 EEDP16; 2659de3c85cSMatt Jacob SGE_SIMPLE_UNION SGE; 2669de3c85cSMatt Jacob } MPI_SCSI_IO32_CDB_UNION, MPI_POINTER PTR_MPI_SCSI_IO32_CDB_UNION, 2679de3c85cSMatt Jacob MpiScsiIo32Cdb_t, MPI_POINTER pMpiScsiIo32Cdb_t; 2689de3c85cSMatt Jacob 2699de3c85cSMatt Jacob typedef struct 2709de3c85cSMatt Jacob { 2719de3c85cSMatt Jacob U8 TargetID; /* 00h */ 2729de3c85cSMatt Jacob U8 Bus; /* 01h */ 2739de3c85cSMatt Jacob U16 Reserved1; /* 02h */ 2749de3c85cSMatt Jacob U32 Reserved2; /* 04h */ 2759de3c85cSMatt Jacob } MPI_SCSI_IO32_BUS_TARGET_ID_FORM, MPI_POINTER PTR_MPI_SCSI_IO32_BUS_TARGET_ID_FORM, 2769de3c85cSMatt Jacob MpiScsiIo32BusTargetIdForm_t, MPI_POINTER pMpiScsiIo32BusTargetIdForm_t; 2779de3c85cSMatt Jacob 2789de3c85cSMatt Jacob typedef union 2799de3c85cSMatt Jacob { 2809de3c85cSMatt Jacob MPI_SCSI_IO32_BUS_TARGET_ID_FORM SCSIID; 2819de3c85cSMatt Jacob U64 WWID; 2829de3c85cSMatt Jacob } MPI_SCSI_IO32_ADDRESS, MPI_POINTER PTR_MPI_SCSI_IO32_ADDRESS, 2839de3c85cSMatt Jacob MpiScsiIo32Address_t, MPI_POINTER pMpiScsiIo32Address_t; 2849de3c85cSMatt Jacob 2859de3c85cSMatt Jacob typedef struct _MSG_SCSI_IO32_REQUEST 2869de3c85cSMatt Jacob { 2879de3c85cSMatt Jacob U8 Port; /* 00h */ 2889de3c85cSMatt Jacob U8 Reserved1; /* 01h */ 2899de3c85cSMatt Jacob U8 ChainOffset; /* 02h */ 2909de3c85cSMatt Jacob U8 Function; /* 03h */ 2919de3c85cSMatt Jacob U8 CDBLength; /* 04h */ 2929de3c85cSMatt Jacob U8 SenseBufferLength; /* 05h */ 2939de3c85cSMatt Jacob U8 Flags; /* 06h */ 2949de3c85cSMatt Jacob U8 MsgFlags; /* 07h */ 2959de3c85cSMatt Jacob U32 MsgContext; /* 08h */ 2969de3c85cSMatt Jacob U8 LUN[8]; /* 0Ch */ 2979de3c85cSMatt Jacob U32 Control; /* 14h */ 2989de3c85cSMatt Jacob MPI_SCSI_IO32_CDB_UNION CDB; /* 18h */ 2999de3c85cSMatt Jacob U32 DataLength; /* 38h */ 3009de3c85cSMatt Jacob U32 BidirectionalDataLength; /* 3Ch */ 3019de3c85cSMatt Jacob U32 SecondaryReferenceTag; /* 40h */ 3029de3c85cSMatt Jacob U16 SecondaryApplicationTag; /* 44h */ 3039de3c85cSMatt Jacob U16 Reserved2; /* 46h */ 3049de3c85cSMatt Jacob U16 EEDPFlags; /* 48h */ 3059de3c85cSMatt Jacob U16 ApplicationTagTranslationMask; /* 4Ah */ 3069de3c85cSMatt Jacob U32 EEDPBlockSize; /* 4Ch */ 3079de3c85cSMatt Jacob MPI_SCSI_IO32_ADDRESS DeviceAddress; /* 50h */ 3089de3c85cSMatt Jacob U8 SGLOffset0; /* 58h */ 3099de3c85cSMatt Jacob U8 SGLOffset1; /* 59h */ 3109de3c85cSMatt Jacob U8 SGLOffset2; /* 5Ah */ 3119de3c85cSMatt Jacob U8 SGLOffset3; /* 5Bh */ 3129de3c85cSMatt Jacob U32 Reserved3; /* 5Ch */ 3139de3c85cSMatt Jacob U32 Reserved4; /* 60h */ 3149de3c85cSMatt Jacob U32 SenseBufferLowAddr; /* 64h */ 3159de3c85cSMatt Jacob SGE_IO_UNION SGL; /* 68h */ 3169de3c85cSMatt Jacob } MSG_SCSI_IO32_REQUEST, MPI_POINTER PTR_MSG_SCSI_IO32_REQUEST, 3179de3c85cSMatt Jacob SCSIIO32Request_t, MPI_POINTER pSCSIIO32Request_t; 3189de3c85cSMatt Jacob 3199de3c85cSMatt Jacob /* SCSI IO 32 MsgFlags bits */ 3209de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_SENSE_WIDTH (0x01) 3219de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_32_SENSE_WIDTH (0x00) 3229de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_64_SENSE_WIDTH (0x01) 3239de3c85cSMatt Jacob 3249de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_SENSE_LOCATION (0x02) 3259de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_SENSE_LOC_HOST (0x00) 3269de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_SENSE_LOC_IOC (0x02) 3279de3c85cSMatt Jacob 3289de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_CMD_DETERMINES_DATA_DIR (0x04) 3299de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_SGL_OFFSETS_CHAINS (0x08) 3309de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_MULTICAST (0x10) 3319de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_BIDIRECTIONAL (0x20) 3329de3c85cSMatt Jacob #define MPI_SCSIIO32_MSGFLGS_LARGE_CDB (0x40) 3339de3c85cSMatt Jacob 3349de3c85cSMatt Jacob /* SCSI IO 32 Flags bits */ 3359de3c85cSMatt Jacob #define MPI_SCSIIO32_FLAGS_FORM_MASK (0x03) 3369de3c85cSMatt Jacob #define MPI_SCSIIO32_FLAGS_FORM_SCSIID (0x00) 3379de3c85cSMatt Jacob #define MPI_SCSIIO32_FLAGS_FORM_WWID (0x01) 3389de3c85cSMatt Jacob 3399de3c85cSMatt Jacob /* SCSI IO 32 LUN fields */ 3409de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_FIRST_LEVEL_ADDRESSING (0x0000FFFF) 3419de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_SECOND_LEVEL_ADDRESSING (0xFFFF0000) 3429de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_THIRD_LEVEL_ADDRESSING (0x0000FFFF) 3439de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_FOURTH_LEVEL_ADDRESSING (0xFFFF0000) 3449de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_LEVEL_1_WORD (0xFF00) 3459de3c85cSMatt Jacob #define MPI_SCSIIO32_LUN_LEVEL_1_DWORD (0x0000FF00) 3469de3c85cSMatt Jacob 3479de3c85cSMatt Jacob /* SCSI IO 32 Control bits */ 3489de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_DATADIRECTION_MASK (0x03000000) 3499de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_NODATATRANSFER (0x00000000) 3509de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_WRITE (0x01000000) 3519de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_READ (0x02000000) 3529de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_BIDIRECTIONAL (0x03000000) 3539de3c85cSMatt Jacob 3549de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_ADDCDBLEN_MASK (0xFC000000) 3559de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_ADDCDBLEN_SHIFT (26) 3569de3c85cSMatt Jacob 3579de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_TASKATTRIBUTE_MASK (0x00000700) 3589de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_SIMPLEQ (0x00000000) 3599de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_HEADOFQ (0x00000100) 3609de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_ORDEREDQ (0x00000200) 3619de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_ACAQ (0x00000400) 3629de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_UNTAGGED (0x00000500) 3639de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_NO_DISCONNECT (0x00000700) 3649de3c85cSMatt Jacob 3659de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_TASKMANAGE_MASK (0x00FF0000) 3669de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_OBSOLETE (0x00800000) 3679de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_CLEAR_ACA_RSV (0x00400000) 3689de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_TARGET_RESET (0x00200000) 3699de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_LUN_RESET_RSV (0x00100000) 3709de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_RESERVED (0x00080000) 3719de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_CLR_TASK_SET_RSV (0x00040000) 3729de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_ABORT_TASK_SET (0x00020000) 3739de3c85cSMatt Jacob #define MPI_SCSIIO32_CONTROL_RESERVED2 (0x00010000) 3749de3c85cSMatt Jacob 3759de3c85cSMatt Jacob /* SCSI IO 32 EEDPFlags */ 3769de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_MASK_OP (0x0007) 3779de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_NOOP_OP (0x0000) 3789de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_CHK_OP (0x0001) 3799de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_STRIP_OP (0x0002) 3809de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_CHKRM_OP (0x0003) 3819de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_INSERT_OP (0x0004) 3829de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_REPLACE_OP (0x0006) 3839de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_CHKREGEN_OP (0x0007) 3849de3c85cSMatt Jacob 3859de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_PASS_REF_TAG (0x0008) 3869de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_8_9THS_MODE (0x0010) 3879de3c85cSMatt Jacob 3889de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_T10_CHK_MASK (0x0700) 3899de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_T10_CHK_GUARD (0x0100) 3909de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_T10_CHK_REFTAG (0x0200) 3919de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_T10_CHK_LBATAG (0x0400) 3929de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_T10_CHK_SHIFT (8) 3939de3c85cSMatt Jacob 3949de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_INC_SEC_APPTAG (0x1000) 3959de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_INC_PRI_APPTAG (0x2000) 3969de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_INC_SEC_REFTAG (0x4000) 3979de3c85cSMatt Jacob #define MPI_SCSIIO32_EEDPFLAGS_INC_PRI_REFTAG (0x8000) 3989de3c85cSMatt Jacob 3999de3c85cSMatt Jacob /* SCSIIO32 IO reply structure */ 4009de3c85cSMatt Jacob typedef struct _MSG_SCSIIO32_IO_REPLY 4019de3c85cSMatt Jacob { 4029de3c85cSMatt Jacob U8 Port; /* 00h */ 4039de3c85cSMatt Jacob U8 Reserved1; /* 01h */ 4049de3c85cSMatt Jacob U8 MsgLength; /* 02h */ 4059de3c85cSMatt Jacob U8 Function; /* 03h */ 4069de3c85cSMatt Jacob U8 CDBLength; /* 04h */ 4079de3c85cSMatt Jacob U8 SenseBufferLength; /* 05h */ 4089de3c85cSMatt Jacob U8 Flags; /* 06h */ 4099de3c85cSMatt Jacob U8 MsgFlags; /* 07h */ 4109de3c85cSMatt Jacob U32 MsgContext; /* 08h */ 4119de3c85cSMatt Jacob U8 SCSIStatus; /* 0Ch */ 4129de3c85cSMatt Jacob U8 SCSIState; /* 0Dh */ 4139de3c85cSMatt Jacob U16 IOCStatus; /* 0Eh */ 4149de3c85cSMatt Jacob U32 IOCLogInfo; /* 10h */ 4159de3c85cSMatt Jacob U32 TransferCount; /* 14h */ 4169de3c85cSMatt Jacob U32 SenseCount; /* 18h */ 4179de3c85cSMatt Jacob U32 ResponseInfo; /* 1Ch */ 4189de3c85cSMatt Jacob U16 TaskTag; /* 20h */ 4199de3c85cSMatt Jacob U16 Reserved2; /* 22h */ 4209de3c85cSMatt Jacob U32 BidirectionalTransferCount; /* 24h */ 4219de3c85cSMatt Jacob } MSG_SCSIIO32_IO_REPLY, MPI_POINTER PTR_MSG_SCSIIO32_IO_REPLY, 4229de3c85cSMatt Jacob SCSIIO32Reply_t, MPI_POINTER pSCSIIO32Reply_t; 4239de3c85cSMatt Jacob 4249b631363SMatt Jacob /****************************************************************************/ 4259b631363SMatt Jacob /* SCSI Task Management messages */ 4269b631363SMatt Jacob /****************************************************************************/ 4279b631363SMatt Jacob 4289b631363SMatt Jacob typedef struct _MSG_SCSI_TASK_MGMT 4299b631363SMatt Jacob { 4309b631363SMatt Jacob U8 TargetID; /* 00h */ 4319b631363SMatt Jacob U8 Bus; /* 01h */ 4329b631363SMatt Jacob U8 ChainOffset; /* 02h */ 4339b631363SMatt Jacob U8 Function; /* 03h */ 4349b631363SMatt Jacob U8 Reserved; /* 04h */ 4359b631363SMatt Jacob U8 TaskType; /* 05h */ 4369b631363SMatt Jacob U8 Reserved1; /* 06h */ 4379b631363SMatt Jacob U8 MsgFlags; /* 07h */ 4389b631363SMatt Jacob U32 MsgContext; /* 08h */ 4399b631363SMatt Jacob U8 LUN[8]; /* 0Ch */ 4409b631363SMatt Jacob U32 Reserved2[7]; /* 14h */ 4419b631363SMatt Jacob U32 TaskMsgContext; /* 30h */ 4429b631363SMatt Jacob } MSG_SCSI_TASK_MGMT, MPI_POINTER PTR_SCSI_TASK_MGMT, 4439b631363SMatt Jacob SCSITaskMgmt_t, MPI_POINTER pSCSITaskMgmt_t; 4449b631363SMatt Jacob 4459b631363SMatt Jacob /* TaskType values */ 4469b631363SMatt Jacob 4479b631363SMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_ABORT_TASK (0x01) 4489b631363SMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_ABRT_TASK_SET (0x02) 4499b631363SMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_TARGET_RESET (0x03) 4509b631363SMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_RESET_BUS (0x04) 4519b631363SMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_LOGICAL_UNIT_RESET (0x05) 4529de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_CLEAR_TASK_SET (0x06) 4539de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_TASKTYPE_QUERY_TASK (0x07) 45462ae194dSScott Long #define MPI_SCSITASKMGMT_TASKTYPE_CLR_ACA (0x08) 4559b631363SMatt Jacob 4569b631363SMatt Jacob /* MsgFlags bits */ 45762ae194dSScott Long #define MPI_SCSITASKMGMT_MSGFLAGS_DO_NOT_SEND_TASK_IU (0x01) 45862ae194dSScott Long 4599b631363SMatt Jacob #define MPI_SCSITASKMGMT_MSGFLAGS_TARGET_RESET_OPTION (0x00) 4609b631363SMatt Jacob #define MPI_SCSITASKMGMT_MSGFLAGS_LIP_RESET_OPTION (0x02) 4619b631363SMatt Jacob #define MPI_SCSITASKMGMT_MSGFLAGS_LIPRESET_RESET_OPTION (0x04) 4629b631363SMatt Jacob 46362ae194dSScott Long #define MPI_SCSITASKMGMT_MSGFLAGS_SOFT_RESET_OPTION (0x08) 46462ae194dSScott Long 4659b631363SMatt Jacob /* SCSI Task Management Reply */ 4669b631363SMatt Jacob typedef struct _MSG_SCSI_TASK_MGMT_REPLY 4679b631363SMatt Jacob { 4689b631363SMatt Jacob U8 TargetID; /* 00h */ 4699b631363SMatt Jacob U8 Bus; /* 01h */ 4709b631363SMatt Jacob U8 MsgLength; /* 02h */ 4719b631363SMatt Jacob U8 Function; /* 03h */ 4729de3c85cSMatt Jacob U8 ResponseCode; /* 04h */ 4739b631363SMatt Jacob U8 TaskType; /* 05h */ 4749b631363SMatt Jacob U8 Reserved1; /* 06h */ 4759b631363SMatt Jacob U8 MsgFlags; /* 07h */ 4769b631363SMatt Jacob U32 MsgContext; /* 08h */ 4779b631363SMatt Jacob U8 Reserved2[2]; /* 0Ch */ 4789b631363SMatt Jacob U16 IOCStatus; /* 0Eh */ 4799b631363SMatt Jacob U32 IOCLogInfo; /* 10h */ 4809b631363SMatt Jacob U32 TerminationCount; /* 14h */ 4819b631363SMatt Jacob } MSG_SCSI_TASK_MGMT_REPLY, MPI_POINTER PTR_MSG_SCSI_TASK_MGMT_REPLY, 4829b631363SMatt Jacob SCSITaskMgmtReply_t, MPI_POINTER pSCSITaskMgmtReply_t; 4839b631363SMatt Jacob 4849de3c85cSMatt Jacob /* ResponseCode values */ 4859de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_TM_COMPLETE (0x00) 4869de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_INVALID_FRAME (0x02) 4879de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_TM_NOT_SUPPORTED (0x04) 4889de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_TM_FAILED (0x05) 4899de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_TM_SUCCEEDED (0x08) 4909de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_TM_INVALID_LUN (0x09) 4919de3c85cSMatt Jacob #define MPI_SCSITASKMGMT_RSP_IO_QUEUED_ON_IOC (0x80) 4929de3c85cSMatt Jacob 4939b631363SMatt Jacob /****************************************************************************/ 4949b631363SMatt Jacob /* SCSI Enclosure Processor messages */ 4959b631363SMatt Jacob /****************************************************************************/ 4969b631363SMatt Jacob 4979b631363SMatt Jacob typedef struct _MSG_SEP_REQUEST 4989b631363SMatt Jacob { 4999b631363SMatt Jacob U8 TargetID; /* 00h */ 5009b631363SMatt Jacob U8 Bus; /* 01h */ 5019b631363SMatt Jacob U8 ChainOffset; /* 02h */ 5029b631363SMatt Jacob U8 Function; /* 03h */ 5039b631363SMatt Jacob U8 Action; /* 04h */ 5049de3c85cSMatt Jacob U8 Flags; /* 05h */ 5059de3c85cSMatt Jacob U8 Reserved1; /* 06h */ 5069b631363SMatt Jacob U8 MsgFlags; /* 07h */ 5079b631363SMatt Jacob U32 MsgContext; /* 08h */ 5089b631363SMatt Jacob U32 SlotStatus; /* 0Ch */ 5099de3c85cSMatt Jacob U32 Reserved2; /* 10h */ 5109de3c85cSMatt Jacob U32 Reserved3; /* 14h */ 5119de3c85cSMatt Jacob U32 Reserved4; /* 18h */ 5129de3c85cSMatt Jacob U16 Slot; /* 1Ch */ 5139de3c85cSMatt Jacob U16 EnclosureHandle; /* 1Eh */ 5149b631363SMatt Jacob } MSG_SEP_REQUEST, MPI_POINTER PTR_MSG_SEP_REQUEST, 5159b631363SMatt Jacob SEPRequest_t, MPI_POINTER pSEPRequest_t; 5169b631363SMatt Jacob 5179b631363SMatt Jacob /* Action defines */ 5189b631363SMatt Jacob #define MPI_SEP_REQ_ACTION_WRITE_STATUS (0x00) 5199b631363SMatt Jacob #define MPI_SEP_REQ_ACTION_READ_STATUS (0x01) 5209b631363SMatt Jacob 5219de3c85cSMatt Jacob /* Flags defines */ 5229de3c85cSMatt Jacob #define MPI_SEP_REQ_FLAGS_ENCLOSURE_SLOT_ADDRESS (0x01) 5239de3c85cSMatt Jacob #define MPI_SEP_REQ_FLAGS_BUS_TARGETID_ADDRESS (0x00) 5249de3c85cSMatt Jacob 5259b631363SMatt Jacob /* SlotStatus bits for MSG_SEP_REQUEST */ 5269b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_NO_ERROR (0x00000001) 5279b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_DEV_FAULTY (0x00000002) 5289b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_DEV_REBUILDING (0x00000004) 5299b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_IN_FAILED_ARRAY (0x00000008) 5309b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_IN_CRITICAL_ARRAY (0x00000010) 5319b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_PARITY_CHECK (0x00000020) 5329b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_PREDICTED_FAULT (0x00000040) 5339b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_UNCONFIGURED (0x00000080) 5349b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_HOT_SPARE (0x00000100) 5359b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_REBUILD_STOPPED (0x00000200) 5369de3c85cSMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_REQ_CONSISTENCY_CHECK (0x00001000) 5379de3c85cSMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_DISABLE (0x00002000) 5389de3c85cSMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_REQ_RESERVED_DEVICE (0x00004000) 5399b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_IDENTIFY_REQUEST (0x00020000) 5409b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_REQUEST_REMOVE (0x00040000) 5419b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_REQUEST_INSERT (0x00080000) 5429b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_DO_NOT_MOVE (0x00400000) 5439de3c85cSMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_ACTIVE (0x00800000) 5449b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_B_ENABLE_BYPASS (0x04000000) 5459b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_A_ENABLE_BYPASS (0x08000000) 5469b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_DEV_OFF (0x10000000) 5479b631363SMatt Jacob #define MPI_SEP_REQ_SLOTSTATUS_SWAP_RESET (0x80000000) 5489b631363SMatt Jacob 5499b631363SMatt Jacob typedef struct _MSG_SEP_REPLY 5509b631363SMatt Jacob { 5519b631363SMatt Jacob U8 TargetID; /* 00h */ 5529b631363SMatt Jacob U8 Bus; /* 01h */ 5539b631363SMatt Jacob U8 MsgLength; /* 02h */ 5549b631363SMatt Jacob U8 Function; /* 03h */ 5559b631363SMatt Jacob U8 Action; /* 04h */ 5569b631363SMatt Jacob U8 Reserved1; /* 05h */ 5579b631363SMatt Jacob U8 Reserved2; /* 06h */ 5589b631363SMatt Jacob U8 MsgFlags; /* 07h */ 5599b631363SMatt Jacob U32 MsgContext; /* 08h */ 5609b631363SMatt Jacob U16 Reserved3; /* 0Ch */ 5619b631363SMatt Jacob U16 IOCStatus; /* 0Eh */ 5629b631363SMatt Jacob U32 IOCLogInfo; /* 10h */ 5639b631363SMatt Jacob U32 SlotStatus; /* 14h */ 5649de3c85cSMatt Jacob U32 Reserved4; /* 18h */ 5659de3c85cSMatt Jacob U16 Slot; /* 1Ch */ 5669de3c85cSMatt Jacob U16 EnclosureHandle; /* 1Eh */ 5679b631363SMatt Jacob } MSG_SEP_REPLY, MPI_POINTER PTR_MSG_SEP_REPLY, 5689b631363SMatt Jacob SEPReply_t, MPI_POINTER pSEPReply_t; 5699b631363SMatt Jacob 5709b631363SMatt Jacob /* SlotStatus bits for MSG_SEP_REPLY */ 5719b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_NO_ERROR (0x00000001) 5729b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_DEV_FAULTY (0x00000002) 5739b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_DEV_REBUILDING (0x00000004) 5749b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_IN_FAILED_ARRAY (0x00000008) 5759b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_IN_CRITICAL_ARRAY (0x00000010) 5769b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_PARITY_CHECK (0x00000020) 5779b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_PREDICTED_FAULT (0x00000040) 5789b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_UNCONFIGURED (0x00000080) 5799b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_HOT_SPARE (0x00000100) 5809b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_REBUILD_STOPPED (0x00000200) 5819de3c85cSMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_CONSISTENCY_CHECK (0x00001000) 5829de3c85cSMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_DISABLE (0x00002000) 5839de3c85cSMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_RESERVED_DEVICE (0x00004000) 5849b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_REPORT (0x00010000) 5859b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_IDENTIFY_REQUEST (0x00020000) 5869b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_REMOVE_READY (0x00040000) 5879b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_INSERT_READY (0x00080000) 5889b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_DO_NOT_REMOVE (0x00400000) 5899de3c85cSMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_ACTIVE (0x00800000) 5909b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_B_BYPASS_ENABLED (0x01000000) 5919b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_A_BYPASS_ENABLED (0x02000000) 5929b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_B_ENABLE_BYPASS (0x04000000) 5939b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_A_ENABLE_BYPASS (0x08000000) 5949b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_DEV_OFF (0x10000000) 5959b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_FAULT_SENSED (0x40000000) 5969b631363SMatt Jacob #define MPI_SEP_REPLY_SLOTSTATUS_SWAPPED (0x80000000) 5979b631363SMatt Jacob 5989b631363SMatt Jacob #endif 599