aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/mpt2sas/mpi/mpi2_raid.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/mpt2sas/mpi/mpi2_raid.h')
-rw-r--r--drivers/scsi/mpt2sas/mpi/mpi2_raid.h67
1 files changed, 60 insertions, 7 deletions
diff --git a/drivers/scsi/mpt2sas/mpi/mpi2_raid.h b/drivers/scsi/mpt2sas/mpi/mpi2_raid.h
index bd61a7b60a2..0601612b875 100644
--- a/drivers/scsi/mpt2sas/mpi/mpi2_raid.h
+++ b/drivers/scsi/mpt2sas/mpi/mpi2_raid.h
@@ -6,7 +6,7 @@
6 * Title: MPI Integrated RAID messages and structures 6 * Title: MPI Integrated RAID messages and structures
7 * Creation Date: April 26, 2007 7 * Creation Date: April 26, 2007
8 * 8 *
9 * mpi2_raid.h Version: 02.00.05 9 * mpi2_raid.h Version: 02.00.06
10 * 10 *
11 * Version History 11 * Version History
12 * --------------- 12 * ---------------
@@ -23,6 +23,10 @@
23 * 07-30-09 02.00.04 Added proper define for the Use Default Settings bit of 23 * 07-30-09 02.00.04 Added proper define for the Use Default Settings bit of
24 * VolumeCreationFlags and marked the old one as obsolete. 24 * VolumeCreationFlags and marked the old one as obsolete.
25 * 05-12-10 02.00.05 Added MPI2_RAID_VOL_FLAGS_OP_MDC define. 25 * 05-12-10 02.00.05 Added MPI2_RAID_VOL_FLAGS_OP_MDC define.
26 * 08-24-10 02.00.06 Added MPI2_RAID_ACTION_COMPATIBILITY_CHECK along with
27 * related structures and defines.
28 * Added product-specific range to RAID Action values.
29
26 * -------------------------------------------------------------------------- 30 * --------------------------------------------------------------------------
27 */ 31 */
28 32
@@ -176,7 +180,9 @@ typedef struct _MPI2_RAID_ACTION_REQUEST
176#define MPI2_RAID_ACTION_SYSTEM_SHUTDOWN_INITIATED (0x20) 180#define MPI2_RAID_ACTION_SYSTEM_SHUTDOWN_INITIATED (0x20)
177#define MPI2_RAID_ACTION_START_RAID_FUNCTION (0x21) 181#define MPI2_RAID_ACTION_START_RAID_FUNCTION (0x21)
178#define MPI2_RAID_ACTION_STOP_RAID_FUNCTION (0x22) 182#define MPI2_RAID_ACTION_STOP_RAID_FUNCTION (0x22)
179 183#define MPI2_RAID_ACTION_COMPATIBILITY_CHECK (0x23)
184#define MPI2_RAID_ACTION_MIN_PRODUCT_SPECIFIC (0x80)
185#define MPI2_RAID_ACTION_MAX_PRODUCT_SPECIFIC (0xFF)
180 186
181/* RAID Volume Creation Structure */ 187/* RAID Volume Creation Structure */
182 188
@@ -244,6 +250,23 @@ typedef struct _MPI2_RAID_ONLINE_CAPACITY_EXPANSION
244 Mpi2RaidOnlineCapacityExpansion_t, 250 Mpi2RaidOnlineCapacityExpansion_t,
245 MPI2_POINTER pMpi2RaidOnlineCapacityExpansion_t; 251 MPI2_POINTER pMpi2RaidOnlineCapacityExpansion_t;
246 252
253/* RAID Compatibility Input Structure */
254
255typedef struct _MPI2_RAID_COMPATIBILITY_INPUT_STRUCT {
256 U16 SourceDevHandle; /* 0x00 */
257 U16 CandidateDevHandle; /* 0x02 */
258 U32 Flags; /* 0x04 */
259 U32 Reserved1; /* 0x08 */
260 U32 Reserved2; /* 0x0C */
261} MPI2_RAID_COMPATIBILITY_INPUT_STRUCT,
262MPI2_POINTER PTR_MPI2_RAID_COMPATIBILITY_INPUT_STRUCT,
263Mpi2RaidCompatibilityInputStruct_t,
264MPI2_POINTER pMpi2RaidCompatibilityInputStruct_t;
265
266/* defines for RAID Compatibility Structure Flags field */
267#define MPI2_RAID_COMPAT_SOURCE_IS_VOLUME_FLAG (0x00000002)
268#define MPI2_RAID_COMPAT_REPORT_SOURCE_INFO_FLAG (0x00000001)
269
247 270
248/* RAID Volume Indicator Structure */ 271/* RAID Volume Indicator Structure */
249 272
@@ -263,15 +286,45 @@ typedef struct _MPI2_RAID_VOL_INDICATOR
263#define MPI2_RAID_VOL_FLAGS_OP_RESYNC (0x00000003) 286#define MPI2_RAID_VOL_FLAGS_OP_RESYNC (0x00000003)
264#define MPI2_RAID_VOL_FLAGS_OP_MDC (0x00000004) 287#define MPI2_RAID_VOL_FLAGS_OP_MDC (0x00000004)
265 288
289/* RAID Compatibility Result Structure */
290
291typedef struct _MPI2_RAID_COMPATIBILITY_RESULT_STRUCT {
292 U8 State; /* 0x00 */
293 U8 Reserved1; /* 0x01 */
294 U16 Reserved2; /* 0x02 */
295 U32 GenericAttributes; /* 0x04 */
296 U32 OEMSpecificAttributes; /* 0x08 */
297 U32 Reserved3; /* 0x0C */
298 U32 Reserved4; /* 0x10 */
299} MPI2_RAID_COMPATIBILITY_RESULT_STRUCT,
300MPI2_POINTER PTR_MPI2_RAID_COMPATIBILITY_RESULT_STRUCT,
301Mpi2RaidCompatibilityResultStruct_t,
302MPI2_POINTER pMpi2RaidCompatibilityResultStruct_t;
303
304/* defines for RAID Compatibility Result Structure State field */
305#define MPI2_RAID_COMPAT_STATE_COMPATIBLE (0x00)
306#define MPI2_RAID_COMPAT_STATE_NOT_COMPATIBLE (0x01)
307
308/* defines for RAID Compatibility Result Structure GenericAttributes field */
309#define MPI2_RAID_COMPAT_GENATTRIB_4K_SECTOR (0x00000010)
310
311#define MPI2_RAID_COMPAT_GENATTRIB_MEDIA_MASK (0x0000000C)
312#define MPI2_RAID_COMPAT_GENATTRIB_SOLID_STATE_DRIVE (0x00000008)
313#define MPI2_RAID_COMPAT_GENATTRIB_HARD_DISK_DRIVE (0x00000004)
314
315#define MPI2_RAID_COMPAT_GENATTRIB_PROTOCOL_MASK (0x00000003)
316#define MPI2_RAID_COMPAT_GENATTRIB_SAS_PROTOCOL (0x00000002)
317#define MPI2_RAID_COMPAT_GENATTRIB_SATA_PROTOCOL (0x00000001)
266 318
267/* RAID Action Reply ActionData union */ 319/* RAID Action Reply ActionData union */
268typedef union _MPI2_RAID_ACTION_REPLY_DATA 320typedef union _MPI2_RAID_ACTION_REPLY_DATA
269{ 321{
270 U32 Word[5]; 322 U32 Word[5];
271 MPI2_RAID_VOL_INDICATOR RaidVolumeIndicator; 323 MPI2_RAID_VOL_INDICATOR RaidVolumeIndicator;
272 U16 VolDevHandle; 324 U16 VolDevHandle;
273 U8 VolumeState; 325 U8 VolumeState;
274 U8 PhysDiskNum; 326 U8 PhysDiskNum;
327 MPI2_RAID_COMPATIBILITY_RESULT_STRUCT RaidCompatibilityResult;
275} MPI2_RAID_ACTION_REPLY_DATA, MPI2_POINTER PTR_MPI2_RAID_ACTION_REPLY_DATA, 328} MPI2_RAID_ACTION_REPLY_DATA, MPI2_POINTER PTR_MPI2_RAID_ACTION_REPLY_DATA,
276 Mpi2RaidActionReplyData_t, MPI2_POINTER pMpi2RaidActionReplyData_t; 329 Mpi2RaidActionReplyData_t, MPI2_POINTER pMpi2RaidActionReplyData_t;
277 330