aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/scsi/mpt2sas/mpi/mpi2.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/scsi/mpt2sas/mpi/mpi2.h')
-rw-r--r--drivers/scsi/mpt2sas/mpi/mpi2.h104
1 files changed, 74 insertions, 30 deletions
diff --git a/drivers/scsi/mpt2sas/mpi/mpi2.h b/drivers/scsi/mpt2sas/mpi/mpi2.h
index 7bb2ece8b2e4..914168105297 100644
--- a/drivers/scsi/mpt2sas/mpi/mpi2.h
+++ b/drivers/scsi/mpt2sas/mpi/mpi2.h
@@ -8,7 +8,7 @@
8 * scatter/gather formats. 8 * scatter/gather formats.
9 * Creation Date: June 21, 2006 9 * Creation Date: June 21, 2006
10 * 10 *
11 * mpi2.h Version: 02.00.11 11 * mpi2.h Version: 02.00.13
12 * 12 *
13 * Version History 13 * Version History
14 * --------------- 14 * ---------------
@@ -45,6 +45,14 @@
45 * 10-02-08 02.00.10 Bumped MPI2_HEADER_VERSION_UNIT. 45 * 10-02-08 02.00.10 Bumped MPI2_HEADER_VERSION_UNIT.
46 * Moved LUN field defines from mpi2_init.h. 46 * Moved LUN field defines from mpi2_init.h.
47 * 01-19-09 02.00.11 Bumped MPI2_HEADER_VERSION_UNIT. 47 * 01-19-09 02.00.11 Bumped MPI2_HEADER_VERSION_UNIT.
48 * 05-06-09 02.00.12 Bumped MPI2_HEADER_VERSION_UNIT.
49 * In all request and reply descriptors, replaced VF_ID
50 * field with MSIxIndex field.
51 * Removed DevHandle field from
52 * MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR and made those
53 * bytes reserved.
54 * Added RAID Accelerator functionality.
55 * 07-30-09 02.00.13 Bumped MPI2_HEADER_VERSION_UNIT.
48 * -------------------------------------------------------------------------- 56 * --------------------------------------------------------------------------
49 */ 57 */
50 58
@@ -70,7 +78,7 @@
70#define MPI2_VERSION_02_00 (0x0200) 78#define MPI2_VERSION_02_00 (0x0200)
71 79
72/* versioning for this MPI header set */ 80/* versioning for this MPI header set */
73#define MPI2_HEADER_VERSION_UNIT (0x0B) 81#define MPI2_HEADER_VERSION_UNIT (0x0D)
74#define MPI2_HEADER_VERSION_DEV (0x00) 82#define MPI2_HEADER_VERSION_DEV (0x00)
75#define MPI2_HEADER_VERSION_UNIT_MASK (0xFF00) 83#define MPI2_HEADER_VERSION_UNIT_MASK (0xFF00)
76#define MPI2_HEADER_VERSION_UNIT_SHIFT (8) 84#define MPI2_HEADER_VERSION_UNIT_SHIFT (8)
@@ -257,7 +265,7 @@ typedef volatile struct _MPI2_SYSTEM_INTERFACE_REGS
257typedef struct _MPI2_DEFAULT_REQUEST_DESCRIPTOR 265typedef struct _MPI2_DEFAULT_REQUEST_DESCRIPTOR
258{ 266{
259 U8 RequestFlags; /* 0x00 */ 267 U8 RequestFlags; /* 0x00 */
260 U8 VF_ID; /* 0x01 */ 268 U8 MSIxIndex; /* 0x01 */
261 U16 SMID; /* 0x02 */ 269 U16 SMID; /* 0x02 */
262 U16 LMID; /* 0x04 */ 270 U16 LMID; /* 0x04 */
263 U16 DescriptorTypeDependent; /* 0x06 */ 271 U16 DescriptorTypeDependent; /* 0x06 */
@@ -271,6 +279,7 @@ typedef struct _MPI2_DEFAULT_REQUEST_DESCRIPTOR
271#define MPI2_REQ_DESCRIPT_FLAGS_SCSI_TARGET (0x02) 279#define MPI2_REQ_DESCRIPT_FLAGS_SCSI_TARGET (0x02)
272#define MPI2_REQ_DESCRIPT_FLAGS_HIGH_PRIORITY (0x06) 280#define MPI2_REQ_DESCRIPT_FLAGS_HIGH_PRIORITY (0x06)
273#define MPI2_REQ_DESCRIPT_FLAGS_DEFAULT_TYPE (0x08) 281#define MPI2_REQ_DESCRIPT_FLAGS_DEFAULT_TYPE (0x08)
282#define MPI2_REQ_DESCRIPT_FLAGS_RAID_ACCELERATOR (0x0A)
274 283
275#define MPI2_REQ_DESCRIPT_FLAGS_IOC_FIFO_MARKER (0x01) 284#define MPI2_REQ_DESCRIPT_FLAGS_IOC_FIFO_MARKER (0x01)
276 285
@@ -279,7 +288,7 @@ typedef struct _MPI2_DEFAULT_REQUEST_DESCRIPTOR
279typedef struct _MPI2_HIGH_PRIORITY_REQUEST_DESCRIPTOR 288typedef struct _MPI2_HIGH_PRIORITY_REQUEST_DESCRIPTOR
280{ 289{
281 U8 RequestFlags; /* 0x00 */ 290 U8 RequestFlags; /* 0x00 */
282 U8 VF_ID; /* 0x01 */ 291 U8 MSIxIndex; /* 0x01 */
283 U16 SMID; /* 0x02 */ 292 U16 SMID; /* 0x02 */
284 U16 LMID; /* 0x04 */ 293 U16 LMID; /* 0x04 */
285 U16 Reserved1; /* 0x06 */ 294 U16 Reserved1; /* 0x06 */
@@ -293,7 +302,7 @@ typedef struct _MPI2_HIGH_PRIORITY_REQUEST_DESCRIPTOR
293typedef struct _MPI2_SCSI_IO_REQUEST_DESCRIPTOR 302typedef struct _MPI2_SCSI_IO_REQUEST_DESCRIPTOR
294{ 303{
295 U8 RequestFlags; /* 0x00 */ 304 U8 RequestFlags; /* 0x00 */
296 U8 VF_ID; /* 0x01 */ 305 U8 MSIxIndex; /* 0x01 */
297 U16 SMID; /* 0x02 */ 306 U16 SMID; /* 0x02 */
298 U16 LMID; /* 0x04 */ 307 U16 LMID; /* 0x04 */
299 U16 DevHandle; /* 0x06 */ 308 U16 DevHandle; /* 0x06 */
@@ -306,7 +315,7 @@ typedef struct _MPI2_SCSI_IO_REQUEST_DESCRIPTOR
306typedef struct _MPI2_SCSI_TARGET_REQUEST_DESCRIPTOR 315typedef struct _MPI2_SCSI_TARGET_REQUEST_DESCRIPTOR
307{ 316{
308 U8 RequestFlags; /* 0x00 */ 317 U8 RequestFlags; /* 0x00 */
309 U8 VF_ID; /* 0x01 */ 318 U8 MSIxIndex; /* 0x01 */
310 U16 SMID; /* 0x02 */ 319 U16 SMID; /* 0x02 */
311 U16 LMID; /* 0x04 */ 320 U16 LMID; /* 0x04 */
312 U16 IoIndex; /* 0x06 */ 321 U16 IoIndex; /* 0x06 */
@@ -315,14 +324,29 @@ typedef struct _MPI2_SCSI_TARGET_REQUEST_DESCRIPTOR
315 Mpi2SCSITargetRequestDescriptor_t, 324 Mpi2SCSITargetRequestDescriptor_t,
316 MPI2_POINTER pMpi2SCSITargetRequestDescriptor_t; 325 MPI2_POINTER pMpi2SCSITargetRequestDescriptor_t;
317 326
327
328/* RAID Accelerator Request Descriptor */
329typedef struct _MPI2_RAID_ACCEL_REQUEST_DESCRIPTOR {
330 U8 RequestFlags; /* 0x00 */
331 U8 MSIxIndex; /* 0x01 */
332 U16 SMID; /* 0x02 */
333 U16 LMID; /* 0x04 */
334 U16 Reserved; /* 0x06 */
335} MPI2_RAID_ACCEL_REQUEST_DESCRIPTOR,
336 MPI2_POINTER PTR_MPI2_RAID_ACCEL_REQUEST_DESCRIPTOR,
337 Mpi2RAIDAcceleratorRequestDescriptor_t,
338 MPI2_POINTER pMpi2RAIDAcceleratorRequestDescriptor_t;
339
340
318/* union of Request Descriptors */ 341/* union of Request Descriptors */
319typedef union _MPI2_REQUEST_DESCRIPTOR_UNION 342typedef union _MPI2_REQUEST_DESCRIPTOR_UNION
320{ 343{
321 MPI2_DEFAULT_REQUEST_DESCRIPTOR Default; 344 MPI2_DEFAULT_REQUEST_DESCRIPTOR Default;
322 MPI2_HIGH_PRIORITY_REQUEST_DESCRIPTOR HighPriority; 345 MPI2_HIGH_PRIORITY_REQUEST_DESCRIPTOR HighPriority;
323 MPI2_SCSI_IO_REQUEST_DESCRIPTOR SCSIIO; 346 MPI2_SCSI_IO_REQUEST_DESCRIPTOR SCSIIO;
324 MPI2_SCSI_TARGET_REQUEST_DESCRIPTOR SCSITarget; 347 MPI2_SCSI_TARGET_REQUEST_DESCRIPTOR SCSITarget;
325 U64 Words; 348 MPI2_RAID_ACCEL_REQUEST_DESCRIPTOR RAIDAccelerator;
349 U64 Words;
326} MPI2_REQUEST_DESCRIPTOR_UNION, MPI2_POINTER PTR_MPI2_REQUEST_DESCRIPTOR_UNION, 350} MPI2_REQUEST_DESCRIPTOR_UNION, MPI2_POINTER PTR_MPI2_REQUEST_DESCRIPTOR_UNION,
327 Mpi2RequestDescriptorUnion_t, MPI2_POINTER pMpi2RequestDescriptorUnion_t; 351 Mpi2RequestDescriptorUnion_t, MPI2_POINTER pMpi2RequestDescriptorUnion_t;
328 352
@@ -333,19 +357,20 @@ typedef union _MPI2_REQUEST_DESCRIPTOR_UNION
333typedef struct _MPI2_DEFAULT_REPLY_DESCRIPTOR 357typedef struct _MPI2_DEFAULT_REPLY_DESCRIPTOR
334{ 358{
335 U8 ReplyFlags; /* 0x00 */ 359 U8 ReplyFlags; /* 0x00 */
336 U8 VF_ID; /* 0x01 */ 360 U8 MSIxIndex; /* 0x01 */
337 U16 DescriptorTypeDependent1; /* 0x02 */ 361 U16 DescriptorTypeDependent1; /* 0x02 */
338 U32 DescriptorTypeDependent2; /* 0x04 */ 362 U32 DescriptorTypeDependent2; /* 0x04 */
339} MPI2_DEFAULT_REPLY_DESCRIPTOR, MPI2_POINTER PTR_MPI2_DEFAULT_REPLY_DESCRIPTOR, 363} MPI2_DEFAULT_REPLY_DESCRIPTOR, MPI2_POINTER PTR_MPI2_DEFAULT_REPLY_DESCRIPTOR,
340 Mpi2DefaultReplyDescriptor_t, MPI2_POINTER pMpi2DefaultReplyDescriptor_t; 364 Mpi2DefaultReplyDescriptor_t, MPI2_POINTER pMpi2DefaultReplyDescriptor_t;
341 365
342/* defines for the ReplyFlags field */ 366/* defines for the ReplyFlags field */
343#define MPI2_RPY_DESCRIPT_FLAGS_TYPE_MASK (0x0F) 367#define MPI2_RPY_DESCRIPT_FLAGS_TYPE_MASK (0x0F)
344#define MPI2_RPY_DESCRIPT_FLAGS_SCSI_IO_SUCCESS (0x00) 368#define MPI2_RPY_DESCRIPT_FLAGS_SCSI_IO_SUCCESS (0x00)
345#define MPI2_RPY_DESCRIPT_FLAGS_ADDRESS_REPLY (0x01) 369#define MPI2_RPY_DESCRIPT_FLAGS_ADDRESS_REPLY (0x01)
346#define MPI2_RPY_DESCRIPT_FLAGS_TARGETASSIST_SUCCESS (0x02) 370#define MPI2_RPY_DESCRIPT_FLAGS_TARGETASSIST_SUCCESS (0x02)
347#define MPI2_RPY_DESCRIPT_FLAGS_TARGET_COMMAND_BUFFER (0x03) 371#define MPI2_RPY_DESCRIPT_FLAGS_TARGET_COMMAND_BUFFER (0x03)
348#define MPI2_RPY_DESCRIPT_FLAGS_UNUSED (0x0F) 372#define MPI2_RPY_DESCRIPT_FLAGS_RAID_ACCELERATOR_SUCCESS (0x05)
373#define MPI2_RPY_DESCRIPT_FLAGS_UNUSED (0x0F)
349 374
350/* values for marking a reply descriptor as unused */ 375/* values for marking a reply descriptor as unused */
351#define MPI2_RPY_DESCRIPT_UNUSED_WORD0_MARK (0xFFFFFFFF) 376#define MPI2_RPY_DESCRIPT_UNUSED_WORD0_MARK (0xFFFFFFFF)
@@ -355,7 +380,7 @@ typedef struct _MPI2_DEFAULT_REPLY_DESCRIPTOR
355typedef struct _MPI2_ADDRESS_REPLY_DESCRIPTOR 380typedef struct _MPI2_ADDRESS_REPLY_DESCRIPTOR
356{ 381{
357 U8 ReplyFlags; /* 0x00 */ 382 U8 ReplyFlags; /* 0x00 */
358 U8 VF_ID; /* 0x01 */ 383 U8 MSIxIndex; /* 0x01 */
359 U16 SMID; /* 0x02 */ 384 U16 SMID; /* 0x02 */
360 U32 ReplyFrameAddress; /* 0x04 */ 385 U32 ReplyFrameAddress; /* 0x04 */
361} MPI2_ADDRESS_REPLY_DESCRIPTOR, MPI2_POINTER PTR_MPI2_ADDRESS_REPLY_DESCRIPTOR, 386} MPI2_ADDRESS_REPLY_DESCRIPTOR, MPI2_POINTER PTR_MPI2_ADDRESS_REPLY_DESCRIPTOR,
@@ -368,10 +393,10 @@ typedef struct _MPI2_ADDRESS_REPLY_DESCRIPTOR
368typedef struct _MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR 393typedef struct _MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR
369{ 394{
370 U8 ReplyFlags; /* 0x00 */ 395 U8 ReplyFlags; /* 0x00 */
371 U8 VF_ID; /* 0x01 */ 396 U8 MSIxIndex; /* 0x01 */
372 U16 SMID; /* 0x02 */ 397 U16 SMID; /* 0x02 */
373 U16 TaskTag; /* 0x04 */ 398 U16 TaskTag; /* 0x04 */
374 U16 DevHandle; /* 0x06 */ 399 U16 Reserved1; /* 0x06 */
375} MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR, 400} MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR,
376 MPI2_POINTER PTR_MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR, 401 MPI2_POINTER PTR_MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR,
377 Mpi2SCSIIOSuccessReplyDescriptor_t, 402 Mpi2SCSIIOSuccessReplyDescriptor_t,
@@ -382,7 +407,7 @@ typedef struct _MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR
382typedef struct _MPI2_TARGETASSIST_SUCCESS_REPLY_DESCRIPTOR 407typedef struct _MPI2_TARGETASSIST_SUCCESS_REPLY_DESCRIPTOR
383{ 408{
384 U8 ReplyFlags; /* 0x00 */ 409 U8 ReplyFlags; /* 0x00 */
385 U8 VF_ID; /* 0x01 */ 410 U8 MSIxIndex; /* 0x01 */
386 U16 SMID; /* 0x02 */ 411 U16 SMID; /* 0x02 */
387 U8 SequenceNumber; /* 0x04 */ 412 U8 SequenceNumber; /* 0x04 */
388 U8 Reserved1; /* 0x05 */ 413 U8 Reserved1; /* 0x05 */
@@ -397,7 +422,7 @@ typedef struct _MPI2_TARGETASSIST_SUCCESS_REPLY_DESCRIPTOR
397typedef struct _MPI2_TARGET_COMMAND_BUFFER_REPLY_DESCRIPTOR 422typedef struct _MPI2_TARGET_COMMAND_BUFFER_REPLY_DESCRIPTOR
398{ 423{
399 U8 ReplyFlags; /* 0x00 */ 424 U8 ReplyFlags; /* 0x00 */
400 U8 VF_ID; /* 0x01 */ 425 U8 MSIxIndex; /* 0x01 */
401 U8 VP_ID; /* 0x02 */ 426 U8 VP_ID; /* 0x02 */
402 U8 Flags; /* 0x03 */ 427 U8 Flags; /* 0x03 */
403 U16 InitiatorDevHandle; /* 0x04 */ 428 U16 InitiatorDevHandle; /* 0x04 */
@@ -411,15 +436,28 @@ typedef struct _MPI2_TARGET_COMMAND_BUFFER_REPLY_DESCRIPTOR
411#define MPI2_RPY_DESCRIPT_TCB_FLAGS_PHYNUM_MASK (0x3F) 436#define MPI2_RPY_DESCRIPT_TCB_FLAGS_PHYNUM_MASK (0x3F)
412 437
413 438
439/* RAID Accelerator Success Reply Descriptor */
440typedef struct _MPI2_RAID_ACCELERATOR_SUCCESS_REPLY_DESCRIPTOR {
441 U8 ReplyFlags; /* 0x00 */
442 U8 MSIxIndex; /* 0x01 */
443 U16 SMID; /* 0x02 */
444 U32 Reserved; /* 0x04 */
445} MPI2_RAID_ACCELERATOR_SUCCESS_REPLY_DESCRIPTOR,
446 MPI2_POINTER PTR_MPI2_RAID_ACCELERATOR_SUCCESS_REPLY_DESCRIPTOR,
447 Mpi2RAIDAcceleratorSuccessReplyDescriptor_t,
448 MPI2_POINTER pMpi2RAIDAcceleratorSuccessReplyDescriptor_t;
449
450
414/* union of Reply Descriptors */ 451/* union of Reply Descriptors */
415typedef union _MPI2_REPLY_DESCRIPTORS_UNION 452typedef union _MPI2_REPLY_DESCRIPTORS_UNION
416{ 453{
417 MPI2_DEFAULT_REPLY_DESCRIPTOR Default; 454 MPI2_DEFAULT_REPLY_DESCRIPTOR Default;
418 MPI2_ADDRESS_REPLY_DESCRIPTOR AddressReply; 455 MPI2_ADDRESS_REPLY_DESCRIPTOR AddressReply;
419 MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR SCSIIOSuccess; 456 MPI2_SCSI_IO_SUCCESS_REPLY_DESCRIPTOR SCSIIOSuccess;
420 MPI2_TARGETASSIST_SUCCESS_REPLY_DESCRIPTOR TargetAssistSuccess; 457 MPI2_TARGETASSIST_SUCCESS_REPLY_DESCRIPTOR TargetAssistSuccess;
421 MPI2_TARGET_COMMAND_BUFFER_REPLY_DESCRIPTOR TargetCommandBuffer; 458 MPI2_TARGET_COMMAND_BUFFER_REPLY_DESCRIPTOR TargetCommandBuffer;
422 U64 Words; 459 MPI2_RAID_ACCELERATOR_SUCCESS_REPLY_DESCRIPTOR RAIDAcceleratorSuccess;
460 U64 Words;
423} MPI2_REPLY_DESCRIPTORS_UNION, MPI2_POINTER PTR_MPI2_REPLY_DESCRIPTORS_UNION, 461} MPI2_REPLY_DESCRIPTORS_UNION, MPI2_POINTER PTR_MPI2_REPLY_DESCRIPTORS_UNION,
424 Mpi2ReplyDescriptorsUnion_t, MPI2_POINTER pMpi2ReplyDescriptorsUnion_t; 462 Mpi2ReplyDescriptorsUnion_t, MPI2_POINTER pMpi2ReplyDescriptorsUnion_t;
425 463
@@ -458,6 +496,7 @@ typedef union _MPI2_REPLY_DESCRIPTORS_UNION
458#define MPI2_FUNCTION_DIAG_RELEASE (0x1E) /* Diagnostic Release */ 496#define MPI2_FUNCTION_DIAG_RELEASE (0x1E) /* Diagnostic Release */
459#define MPI2_FUNCTION_TARGET_CMD_BUF_BASE_POST (0x24) /* Target Command Buffer Post Base */ 497#define MPI2_FUNCTION_TARGET_CMD_BUF_BASE_POST (0x24) /* Target Command Buffer Post Base */
460#define MPI2_FUNCTION_TARGET_CMD_BUF_LIST_POST (0x25) /* Target Command Buffer Post List */ 498#define MPI2_FUNCTION_TARGET_CMD_BUF_LIST_POST (0x25) /* Target Command Buffer Post List */
499#define MPI2_FUNCTION_RAID_ACCELERATOR (0x2C) /* RAID Accelerator*/
461 500
462 501
463 502
@@ -555,12 +594,17 @@ typedef union _MPI2_REPLY_DESCRIPTORS_UNION
555 594
556#define MPI2_IOCSTATUS_DIAGNOSTIC_RELEASED (0x00A0) 595#define MPI2_IOCSTATUS_DIAGNOSTIC_RELEASED (0x00A0)
557 596
597/****************************************************************************
598* RAID Accelerator values
599****************************************************************************/
600
601#define MPI2_IOCSTATUS_RAID_ACCEL_ERROR (0x00B0)
558 602
559/**************************************************************************** 603/****************************************************************************
560* IOCStatus flag to indicate that log info is available 604* IOCStatus flag to indicate that log info is available
561****************************************************************************/ 605****************************************************************************/
562 606
563#define MPI2_IOCSTATUS_FLAG_LOG_INFO_AVAILABLE (0x8000) 607#define MPI2_IOCSTATUS_FLAG_LOG_INFO_AVAILABLE (0x8000)
564 608
565/**************************************************************************** 609/****************************************************************************
566* IOCLogInfo Types 610* IOCLogInfo Types