162306a36Sopenharmony_ci/* SPDX-License-Identifier: GPL-2.0 */
262306a36Sopenharmony_ci/*
362306a36Sopenharmony_ci * Copyright 2000-2020 Broadcom Inc. All rights reserved.
462306a36Sopenharmony_ci *
562306a36Sopenharmony_ci *
662306a36Sopenharmony_ci *          Name:  mpi2_sas.h
762306a36Sopenharmony_ci *         Title:  MPI Serial Attached SCSI structures and definitions
862306a36Sopenharmony_ci * Creation Date:  February 9, 2007
962306a36Sopenharmony_ci *
1062306a36Sopenharmony_ci * mpi2_sas.h Version:  02.00.10
1162306a36Sopenharmony_ci *
1262306a36Sopenharmony_ci * NOTE: Names (typedefs, defines, etc.) beginning with an MPI25 or Mpi25
1362306a36Sopenharmony_ci *       prefix are for use only on MPI v2.5 products, and must not be used
1462306a36Sopenharmony_ci *       with MPI v2.0 products. Unless otherwise noted, names beginning with
1562306a36Sopenharmony_ci *       MPI2 or Mpi2 are for use with both MPI v2.0 and MPI v2.5 products.
1662306a36Sopenharmony_ci *
1762306a36Sopenharmony_ci * Version History
1862306a36Sopenharmony_ci * ---------------
1962306a36Sopenharmony_ci *
2062306a36Sopenharmony_ci * Date      Version   Description
2162306a36Sopenharmony_ci * --------  --------  ------------------------------------------------------
2262306a36Sopenharmony_ci * 04-30-07  02.00.00  Corresponds to Fusion-MPT MPI Specification Rev A.
2362306a36Sopenharmony_ci * 06-26-07  02.00.01  Added Clear All Persistent Operation to SAS IO Unit
2462306a36Sopenharmony_ci *                     Control Request.
2562306a36Sopenharmony_ci * 10-02-08  02.00.02  Added Set IOC Parameter Operation to SAS IO Unit Control
2662306a36Sopenharmony_ci *                     Request.
2762306a36Sopenharmony_ci * 10-28-09  02.00.03  Changed the type of SGL in MPI2_SATA_PASSTHROUGH_REQUEST
2862306a36Sopenharmony_ci *                     to MPI2_SGE_IO_UNION since it supports chained SGLs.
2962306a36Sopenharmony_ci * 05-12-10  02.00.04  Modified some comments.
3062306a36Sopenharmony_ci * 08-11-10  02.00.05  Added NCQ operations to SAS IO Unit Control.
3162306a36Sopenharmony_ci * 11-18-11  02.00.06  Incorporating additions for MPI v2.5.
3262306a36Sopenharmony_ci * 07-10-12  02.00.07  Added MPI2_SATA_PT_SGE_UNION for use in the SATA
3362306a36Sopenharmony_ci *                     Passthrough Request message.
3462306a36Sopenharmony_ci * 08-19-13  02.00.08  Made MPI2_SAS_OP_TRANSMIT_PORT_SELECT_SIGNAL obsolete
3562306a36Sopenharmony_ci *			for anything newer than MPI v2.0.
3662306a36Sopenharmony_ci * 11-18-14  02.00.09  Updated copyright information.
3762306a36Sopenharmony_ci * 03-16-15  02.00.10  Updated for MPI v2.6.
3862306a36Sopenharmony_ci *                     Added MPI2_SATA_PT_REQ_PT_FLAGS_FPDMA.
3962306a36Sopenharmony_ci * --------------------------------------------------------------------------
4062306a36Sopenharmony_ci */
4162306a36Sopenharmony_ci
4262306a36Sopenharmony_ci#ifndef MPI2_SAS_H
4362306a36Sopenharmony_ci#define MPI2_SAS_H
4462306a36Sopenharmony_ci
4562306a36Sopenharmony_ci/*
4662306a36Sopenharmony_ci *Values for SASStatus.
4762306a36Sopenharmony_ci */
4862306a36Sopenharmony_ci#define MPI2_SASSTATUS_SUCCESS                          (0x00)
4962306a36Sopenharmony_ci#define MPI2_SASSTATUS_UNKNOWN_ERROR                    (0x01)
5062306a36Sopenharmony_ci#define MPI2_SASSTATUS_INVALID_FRAME                    (0x02)
5162306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_BAD_DEST                     (0x03)
5262306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_BREAK_RECEIVED               (0x04)
5362306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_CONNECT_RATE_NOT_SUPPORTED   (0x05)
5462306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_PORT_LAYER_REQUEST           (0x06)
5562306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_PROTOCOL_NOT_SUPPORTED       (0x07)
5662306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_STP_RESOURCES_BUSY           (0x08)
5762306a36Sopenharmony_ci#define MPI2_SASSTATUS_UTC_WRONG_DESTINATION            (0x09)
5862306a36Sopenharmony_ci#define MPI2_SASSTATUS_SHORT_INFORMATION_UNIT           (0x0A)
5962306a36Sopenharmony_ci#define MPI2_SASSTATUS_LONG_INFORMATION_UNIT            (0x0B)
6062306a36Sopenharmony_ci#define MPI2_SASSTATUS_XFER_RDY_INCORRECT_WRITE_DATA    (0x0C)
6162306a36Sopenharmony_ci#define MPI2_SASSTATUS_XFER_RDY_REQUEST_OFFSET_ERROR    (0x0D)
6262306a36Sopenharmony_ci#define MPI2_SASSTATUS_XFER_RDY_NOT_EXPECTED            (0x0E)
6362306a36Sopenharmony_ci#define MPI2_SASSTATUS_DATA_INCORRECT_DATA_LENGTH       (0x0F)
6462306a36Sopenharmony_ci#define MPI2_SASSTATUS_DATA_TOO_MUCH_READ_DATA          (0x10)
6562306a36Sopenharmony_ci#define MPI2_SASSTATUS_DATA_OFFSET_ERROR                (0x11)
6662306a36Sopenharmony_ci#define MPI2_SASSTATUS_SDSF_NAK_RECEIVED                (0x12)
6762306a36Sopenharmony_ci#define MPI2_SASSTATUS_SDSF_CONNECTION_FAILED           (0x13)
6862306a36Sopenharmony_ci#define MPI2_SASSTATUS_INITIATOR_RESPONSE_TIMEOUT       (0x14)
6962306a36Sopenharmony_ci
7062306a36Sopenharmony_ci/*
7162306a36Sopenharmony_ci *Values for the SAS DeviceInfo field used in SAS Device Status Change Event
7262306a36Sopenharmony_ci *data and SAS Configuration pages.
7362306a36Sopenharmony_ci */
7462306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SEP                (0x00004000)
7562306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_ATAPI_DEVICE       (0x00002000)
7662306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_LSI_DEVICE         (0x00001000)
7762306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_DIRECT_ATTACH      (0x00000800)
7862306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SSP_TARGET         (0x00000400)
7962306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_STP_TARGET         (0x00000200)
8062306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SMP_TARGET         (0x00000100)
8162306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SATA_DEVICE        (0x00000080)
8262306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SSP_INITIATOR      (0x00000040)
8362306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_STP_INITIATOR      (0x00000020)
8462306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SMP_INITIATOR      (0x00000010)
8562306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_SATA_HOST          (0x00000008)
8662306a36Sopenharmony_ci
8762306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_MASK_DEVICE_TYPE   (0x00000007)
8862306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_NO_DEVICE          (0x00000000)
8962306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_END_DEVICE         (0x00000001)
9062306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_EDGE_EXPANDER      (0x00000002)
9162306a36Sopenharmony_ci#define MPI2_SAS_DEVICE_INFO_FANOUT_EXPANDER    (0x00000003)
9262306a36Sopenharmony_ci
9362306a36Sopenharmony_ci/*****************************************************************************
9462306a36Sopenharmony_ci*
9562306a36Sopenharmony_ci*       SAS Messages
9662306a36Sopenharmony_ci*
9762306a36Sopenharmony_ci*****************************************************************************/
9862306a36Sopenharmony_ci
9962306a36Sopenharmony_ci/****************************************************************************
10062306a36Sopenharmony_ci* SMP Passthrough messages
10162306a36Sopenharmony_ci****************************************************************************/
10262306a36Sopenharmony_ci
10362306a36Sopenharmony_ci/*SMP Passthrough Request Message */
10462306a36Sopenharmony_citypedef struct _MPI2_SMP_PASSTHROUGH_REQUEST {
10562306a36Sopenharmony_ci	U8 PassthroughFlags;	/*0x00 */
10662306a36Sopenharmony_ci	U8 PhysicalPort;	/*0x01 */
10762306a36Sopenharmony_ci	U8 ChainOffset;		/*0x02 */
10862306a36Sopenharmony_ci	U8 Function;		/*0x03 */
10962306a36Sopenharmony_ci	U16 RequestDataLength;	/*0x04 */
11062306a36Sopenharmony_ci	U8 SGLFlags;		/*0x06*//*MPI v2.0 only. Reserved on MPI v2.5*/
11162306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
11262306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
11362306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
11462306a36Sopenharmony_ci	U16 Reserved1;		/*0x0A */
11562306a36Sopenharmony_ci	U32 Reserved2;		/*0x0C */
11662306a36Sopenharmony_ci	U64 SASAddress;		/*0x10 */
11762306a36Sopenharmony_ci	U32 Reserved3;		/*0x18 */
11862306a36Sopenharmony_ci	U32 Reserved4;		/*0x1C */
11962306a36Sopenharmony_ci	MPI2_SIMPLE_SGE_UNION SGL;/*0x20 */
12062306a36Sopenharmony_ci} MPI2_SMP_PASSTHROUGH_REQUEST, *PTR_MPI2_SMP_PASSTHROUGH_REQUEST,
12162306a36Sopenharmony_ci	Mpi2SmpPassthroughRequest_t, *pMpi2SmpPassthroughRequest_t;
12262306a36Sopenharmony_ci
12362306a36Sopenharmony_ci/*values for PassthroughFlags field */
12462306a36Sopenharmony_ci#define MPI2_SMP_PT_REQ_PT_FLAGS_IMMEDIATE      (0x80)
12562306a36Sopenharmony_ci
12662306a36Sopenharmony_ci/*MPI v2.0: use MPI2_SGLFLAGS_ defines from mpi2.h for the SGLFlags field */
12762306a36Sopenharmony_ci
12862306a36Sopenharmony_ci/*SMP Passthrough Reply Message */
12962306a36Sopenharmony_citypedef struct _MPI2_SMP_PASSTHROUGH_REPLY {
13062306a36Sopenharmony_ci	U8 PassthroughFlags;	/*0x00 */
13162306a36Sopenharmony_ci	U8 PhysicalPort;	/*0x01 */
13262306a36Sopenharmony_ci	U8 MsgLength;		/*0x02 */
13362306a36Sopenharmony_ci	U8 Function;		/*0x03 */
13462306a36Sopenharmony_ci	U16 ResponseDataLength;	/*0x04 */
13562306a36Sopenharmony_ci	U8 SGLFlags;		/*0x06 */
13662306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
13762306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
13862306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
13962306a36Sopenharmony_ci	U16 Reserved1;		/*0x0A */
14062306a36Sopenharmony_ci	U8 Reserved2;		/*0x0C */
14162306a36Sopenharmony_ci	U8 SASStatus;		/*0x0D */
14262306a36Sopenharmony_ci	U16 IOCStatus;		/*0x0E */
14362306a36Sopenharmony_ci	U32 IOCLogInfo;		/*0x10 */
14462306a36Sopenharmony_ci	U32 Reserved3;		/*0x14 */
14562306a36Sopenharmony_ci	U8 ResponseData[4];	/*0x18 */
14662306a36Sopenharmony_ci} MPI2_SMP_PASSTHROUGH_REPLY, *PTR_MPI2_SMP_PASSTHROUGH_REPLY,
14762306a36Sopenharmony_ci	Mpi2SmpPassthroughReply_t, *pMpi2SmpPassthroughReply_t;
14862306a36Sopenharmony_ci
14962306a36Sopenharmony_ci/*values for PassthroughFlags field */
15062306a36Sopenharmony_ci#define MPI2_SMP_PT_REPLY_PT_FLAGS_IMMEDIATE    (0x80)
15162306a36Sopenharmony_ci
15262306a36Sopenharmony_ci/*values for SASStatus field are at the top of this file */
15362306a36Sopenharmony_ci
15462306a36Sopenharmony_ci/****************************************************************************
15562306a36Sopenharmony_ci* SATA Passthrough messages
15662306a36Sopenharmony_ci****************************************************************************/
15762306a36Sopenharmony_ci
15862306a36Sopenharmony_citypedef union _MPI2_SATA_PT_SGE_UNION {
15962306a36Sopenharmony_ci	MPI2_SGE_SIMPLE_UNION MpiSimple;	/*MPI v2.0 only */
16062306a36Sopenharmony_ci	MPI2_SGE_CHAIN_UNION MpiChain;	/*MPI v2.0 only */
16162306a36Sopenharmony_ci	MPI2_IEEE_SGE_SIMPLE_UNION IeeeSimple;
16262306a36Sopenharmony_ci	MPI2_IEEE_SGE_CHAIN_UNION IeeeChain;	/*MPI v2.0 only */
16362306a36Sopenharmony_ci	MPI25_IEEE_SGE_CHAIN64 IeeeChain64;	/*MPI v2.5 only */
16462306a36Sopenharmony_ci} MPI2_SATA_PT_SGE_UNION, *PTR_MPI2_SATA_PT_SGE_UNION,
16562306a36Sopenharmony_ci	Mpi2SataPTSGEUnion_t, *pMpi2SataPTSGEUnion_t;
16662306a36Sopenharmony_ci
16762306a36Sopenharmony_ci/*SATA Passthrough Request Message */
16862306a36Sopenharmony_citypedef struct _MPI2_SATA_PASSTHROUGH_REQUEST {
16962306a36Sopenharmony_ci	U16 DevHandle;		/*0x00 */
17062306a36Sopenharmony_ci	U8 ChainOffset;		/*0x02 */
17162306a36Sopenharmony_ci	U8 Function;		/*0x03 */
17262306a36Sopenharmony_ci	U16 PassthroughFlags;	/*0x04 */
17362306a36Sopenharmony_ci	U8 SGLFlags;		/*0x06*//*MPI v2.0 only. Reserved on MPI v2.5*/
17462306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
17562306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
17662306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
17762306a36Sopenharmony_ci	U16 Reserved1;		/*0x0A */
17862306a36Sopenharmony_ci	U32 Reserved2;		/*0x0C */
17962306a36Sopenharmony_ci	U32 Reserved3;		/*0x10 */
18062306a36Sopenharmony_ci	U32 Reserved4;		/*0x14 */
18162306a36Sopenharmony_ci	U32 DataLength;		/*0x18 */
18262306a36Sopenharmony_ci	U8 CommandFIS[20];	/*0x1C */
18362306a36Sopenharmony_ci	MPI2_SATA_PT_SGE_UNION SGL;/*0x30*//*MPI v2.5: IEEE 64 elements only*/
18462306a36Sopenharmony_ci} MPI2_SATA_PASSTHROUGH_REQUEST, *PTR_MPI2_SATA_PASSTHROUGH_REQUEST,
18562306a36Sopenharmony_ci	Mpi2SataPassthroughRequest_t,
18662306a36Sopenharmony_ci	*pMpi2SataPassthroughRequest_t;
18762306a36Sopenharmony_ci
18862306a36Sopenharmony_ci/*values for PassthroughFlags field */
18962306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_EXECUTE_DIAG      (0x0100)
19062306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_FPDMA             (0x0040)
19162306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_DMA               (0x0020)
19262306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_PIO               (0x0010)
19362306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_UNSPECIFIED_VU    (0x0004)
19462306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_WRITE             (0x0002)
19562306a36Sopenharmony_ci#define MPI2_SATA_PT_REQ_PT_FLAGS_READ              (0x0001)
19662306a36Sopenharmony_ci
19762306a36Sopenharmony_ci/*MPI v2.0: use MPI2_SGLFLAGS_ defines from mpi2.h for the SGLFlags field */
19862306a36Sopenharmony_ci
19962306a36Sopenharmony_ci/*SATA Passthrough Reply Message */
20062306a36Sopenharmony_citypedef struct _MPI2_SATA_PASSTHROUGH_REPLY {
20162306a36Sopenharmony_ci	U16 DevHandle;		/*0x00 */
20262306a36Sopenharmony_ci	U8 MsgLength;		/*0x02 */
20362306a36Sopenharmony_ci	U8 Function;		/*0x03 */
20462306a36Sopenharmony_ci	U16 PassthroughFlags;	/*0x04 */
20562306a36Sopenharmony_ci	U8 SGLFlags;		/*0x06 */
20662306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
20762306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
20862306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
20962306a36Sopenharmony_ci	U16 Reserved1;		/*0x0A */
21062306a36Sopenharmony_ci	U8 Reserved2;		/*0x0C */
21162306a36Sopenharmony_ci	U8 SASStatus;		/*0x0D */
21262306a36Sopenharmony_ci	U16 IOCStatus;		/*0x0E */
21362306a36Sopenharmony_ci	U32 IOCLogInfo;		/*0x10 */
21462306a36Sopenharmony_ci	U8 StatusFIS[20];	/*0x14 */
21562306a36Sopenharmony_ci	U32 StatusControlRegisters;	/*0x28 */
21662306a36Sopenharmony_ci	U32 TransferCount;	/*0x2C */
21762306a36Sopenharmony_ci} MPI2_SATA_PASSTHROUGH_REPLY, *PTR_MPI2_SATA_PASSTHROUGH_REPLY,
21862306a36Sopenharmony_ci	Mpi2SataPassthroughReply_t, *pMpi2SataPassthroughReply_t;
21962306a36Sopenharmony_ci
22062306a36Sopenharmony_ci/*values for SASStatus field are at the top of this file */
22162306a36Sopenharmony_ci
22262306a36Sopenharmony_ci/****************************************************************************
22362306a36Sopenharmony_ci* SAS IO Unit Control messages
22462306a36Sopenharmony_ci* (MPI v2.5 and earlier only.
22562306a36Sopenharmony_ci* Replaced by IO Unit Control messages in MPI v2.6 and later.)
22662306a36Sopenharmony_ci****************************************************************************/
22762306a36Sopenharmony_ci
22862306a36Sopenharmony_ci/*SAS IO Unit Control Request Message */
22962306a36Sopenharmony_citypedef struct _MPI2_SAS_IOUNIT_CONTROL_REQUEST {
23062306a36Sopenharmony_ci	U8 Operation;		/*0x00 */
23162306a36Sopenharmony_ci	U8 Reserved1;		/*0x01 */
23262306a36Sopenharmony_ci	U8 ChainOffset;		/*0x02 */
23362306a36Sopenharmony_ci	U8 Function;		/*0x03 */
23462306a36Sopenharmony_ci	U16 DevHandle;		/*0x04 */
23562306a36Sopenharmony_ci	U8 IOCParameter;	/*0x06 */
23662306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
23762306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
23862306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
23962306a36Sopenharmony_ci	U16 Reserved3;		/*0x0A */
24062306a36Sopenharmony_ci	U16 Reserved4;		/*0x0C */
24162306a36Sopenharmony_ci	U8 PhyNum;		/*0x0E */
24262306a36Sopenharmony_ci	U8 PrimFlags;		/*0x0F */
24362306a36Sopenharmony_ci	U32 Primitive;		/*0x10 */
24462306a36Sopenharmony_ci	U8 LookupMethod;	/*0x14 */
24562306a36Sopenharmony_ci	U8 Reserved5;		/*0x15 */
24662306a36Sopenharmony_ci	U16 SlotNumber;		/*0x16 */
24762306a36Sopenharmony_ci	U64 LookupAddress;	/*0x18 */
24862306a36Sopenharmony_ci	U32 IOCParameterValue;	/*0x20 */
24962306a36Sopenharmony_ci	U32 Reserved7;		/*0x24 */
25062306a36Sopenharmony_ci	U32 Reserved8;		/*0x28 */
25162306a36Sopenharmony_ci} MPI2_SAS_IOUNIT_CONTROL_REQUEST,
25262306a36Sopenharmony_ci	*PTR_MPI2_SAS_IOUNIT_CONTROL_REQUEST,
25362306a36Sopenharmony_ci	Mpi2SasIoUnitControlRequest_t,
25462306a36Sopenharmony_ci	*pMpi2SasIoUnitControlRequest_t;
25562306a36Sopenharmony_ci
25662306a36Sopenharmony_ci/*values for the Operation field */
25762306a36Sopenharmony_ci#define MPI2_SAS_OP_CLEAR_ALL_PERSISTENT        (0x02)
25862306a36Sopenharmony_ci#define MPI2_SAS_OP_PHY_LINK_RESET              (0x06)
25962306a36Sopenharmony_ci#define MPI2_SAS_OP_PHY_HARD_RESET              (0x07)
26062306a36Sopenharmony_ci#define MPI2_SAS_OP_PHY_CLEAR_ERROR_LOG         (0x08)
26162306a36Sopenharmony_ci#define MPI2_SAS_OP_SEND_PRIMITIVE              (0x0A)
26262306a36Sopenharmony_ci#define MPI2_SAS_OP_FORCE_FULL_DISCOVERY        (0x0B)
26362306a36Sopenharmony_ci#define MPI2_SAS_OP_TRANSMIT_PORT_SELECT_SIGNAL (0x0C) /* MPI v2.0 only */
26462306a36Sopenharmony_ci#define MPI2_SAS_OP_REMOVE_DEVICE               (0x0D)
26562306a36Sopenharmony_ci#define MPI2_SAS_OP_LOOKUP_MAPPING              (0x0E)
26662306a36Sopenharmony_ci#define MPI2_SAS_OP_SET_IOC_PARAMETER           (0x0F)
26762306a36Sopenharmony_ci#define MPI25_SAS_OP_ENABLE_FP_DEVICE           (0x10)
26862306a36Sopenharmony_ci#define MPI25_SAS_OP_DISABLE_FP_DEVICE          (0x11)
26962306a36Sopenharmony_ci#define MPI25_SAS_OP_ENABLE_FP_ALL              (0x12)
27062306a36Sopenharmony_ci#define MPI25_SAS_OP_DISABLE_FP_ALL             (0x13)
27162306a36Sopenharmony_ci#define MPI2_SAS_OP_DEV_ENABLE_NCQ              (0x14)
27262306a36Sopenharmony_ci#define MPI2_SAS_OP_DEV_DISABLE_NCQ             (0x15)
27362306a36Sopenharmony_ci#define MPI2_SAS_OP_PRODUCT_SPECIFIC_MIN        (0x80)
27462306a36Sopenharmony_ci
27562306a36Sopenharmony_ci/*values for the PrimFlags field */
27662306a36Sopenharmony_ci#define MPI2_SAS_PRIMFLAGS_SINGLE               (0x08)
27762306a36Sopenharmony_ci#define MPI2_SAS_PRIMFLAGS_TRIPLE               (0x02)
27862306a36Sopenharmony_ci#define MPI2_SAS_PRIMFLAGS_REDUNDANT            (0x01)
27962306a36Sopenharmony_ci
28062306a36Sopenharmony_ci/*values for the LookupMethod field */
28162306a36Sopenharmony_ci#define MPI2_SAS_LOOKUP_METHOD_SAS_ADDRESS          (0x01)
28262306a36Sopenharmony_ci#define MPI2_SAS_LOOKUP_METHOD_SAS_ENCLOSURE_SLOT   (0x02)
28362306a36Sopenharmony_ci#define MPI2_SAS_LOOKUP_METHOD_SAS_DEVICE_NAME      (0x03)
28462306a36Sopenharmony_ci
28562306a36Sopenharmony_ci/*SAS IO Unit Control Reply Message */
28662306a36Sopenharmony_citypedef struct _MPI2_SAS_IOUNIT_CONTROL_REPLY {
28762306a36Sopenharmony_ci	U8 Operation;		/*0x00 */
28862306a36Sopenharmony_ci	U8 Reserved1;		/*0x01 */
28962306a36Sopenharmony_ci	U8 MsgLength;		/*0x02 */
29062306a36Sopenharmony_ci	U8 Function;		/*0x03 */
29162306a36Sopenharmony_ci	U16 DevHandle;		/*0x04 */
29262306a36Sopenharmony_ci	U8 IOCParameter;	/*0x06 */
29362306a36Sopenharmony_ci	U8 MsgFlags;		/*0x07 */
29462306a36Sopenharmony_ci	U8 VP_ID;		/*0x08 */
29562306a36Sopenharmony_ci	U8 VF_ID;		/*0x09 */
29662306a36Sopenharmony_ci	U16 Reserved3;		/*0x0A */
29762306a36Sopenharmony_ci	U16 Reserved4;		/*0x0C */
29862306a36Sopenharmony_ci	U16 IOCStatus;		/*0x0E */
29962306a36Sopenharmony_ci	U32 IOCLogInfo;		/*0x10 */
30062306a36Sopenharmony_ci} MPI2_SAS_IOUNIT_CONTROL_REPLY,
30162306a36Sopenharmony_ci	*PTR_MPI2_SAS_IOUNIT_CONTROL_REPLY,
30262306a36Sopenharmony_ci	Mpi2SasIoUnitControlReply_t, *pMpi2SasIoUnitControlReply_t;
30362306a36Sopenharmony_ci
30462306a36Sopenharmony_ci#endif
305