Training courses

Kernel and Embedded Linux

Bootlin training courses

Embedded Linux, kernel,
Yocto Project, Buildroot, real-time,
graphics, boot time, debugging...

Bootlin logo

Elixir Cross Referencer

  1
  2
  3
  4
  5
  6
  7
  8
  9
 10
 11
 12
 13
 14
 15
 16
 17
 18
 19
 20
 21
 22
 23
 24
 25
 26
 27
 28
 29
 30
 31
 32
 33
 34
 35
 36
 37
 38
 39
 40
 41
 42
 43
 44
 45
 46
 47
 48
 49
 50
 51
 52
 53
 54
 55
 56
 57
 58
 59
 60
 61
 62
 63
 64
 65
 66
 67
 68
 69
 70
 71
 72
 73
 74
 75
 76
 77
 78
 79
 80
 81
 82
 83
 84
 85
 86
 87
 88
 89
 90
 91
 92
 93
 94
 95
 96
 97
 98
 99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
/*-
 * SPDX-License-Identifier: BSD-2-Clause-FreeBSD
 *
 * Copyright (c) 2006-2015 LSI Corp.
 * Copyright (c) 2013-2015 Avago Technologies
 * All rights reserved.
 *
 * Redistribution and use in source and binary forms, with or without
 * modification, are permitted provided that the following conditions
 * are met:
 * 1. Redistributions of source code must retain the above copyright
 *    notice, this list of conditions and the following disclaimer.
 * 2. Redistributions in binary form must reproduce the above copyright
 *    notice, this list of conditions and the following disclaimer in the
 *    documentation and/or other materials provided with the distribution.
 *
 * THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
 * ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
 * IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
 * ARE DISCLAIMED.  IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
 * SUCH DAMAGE.
 *
 * Avago Technologies (LSI) MPT-Fusion Host Adapter FreeBSD
 *
 * $FreeBSD$
 */

/*
 *  Copyright (c) 2006-2015 LSI Corporation.
 *  Copyright (c) 2013-2015 Avago Technologies
 *
 *
 *           Name:  mpi2_targ.h
 *          Title:  MPI Target mode messages and structures
 *  Creation Date:  September 8, 2006
 *
 *    mpi2_targ.h Version: 02.00.04
 *
 *  Version History
 *  ---------------
 *
 *  Date      Version   Description
 *  --------  --------  ------------------------------------------------------
 *  04-30-07  02.00.00  Corresponds to Fusion-MPT MPI Specification Rev A.
 *  08-31-07  02.00.01  Added Command Buffer Data Location Address Space bits to
 *                      BufferPostFlags field of CommandBufferPostBase Request.
 *  02-29-08  02.00.02  Modified various names to make them 32-character unique.
 *  10-02-08  02.00.03  Removed NextCmdBufferOffset from
 *                      MPI2_TARGET_CMD_BUF_POST_BASE_REQUEST.
 *                      Target Status Send Request only takes a single SGE for
 *                      response data.
 *  02-10-10  02.00.04  Added comment to MPI2_TARGET_SSP_RSP_IU structure.
 *  --------------------------------------------------------------------------
 */

#ifndef MPI2_TARG_H
#define MPI2_TARG_H

/******************************************************************************
*
*        SCSI Target Messages
*
*******************************************************************************/

/****************************************************************************
*  Target Command Buffer Post Base Request
****************************************************************************/

typedef struct _MPI2_TARGET_CMD_BUF_POST_BASE_REQUEST
{
    U8                      BufferPostFlags;        /* 0x00 */
    U8                      Reserved1;              /* 0x01 */
    U8                      ChainOffset;            /* 0x02 */
    U8                      Function;               /* 0x03 */
    U16                     TotalCmdBuffers;        /* 0x04 */
    U8                      Reserved;               /* 0x06 */
    U8                      MsgFlags;               /* 0x07 */
    U8                      VP_ID;                  /* 0x08 */
    U8                      VF_ID;                  /* 0x09 */
    U16                     Reserved2;              /* 0x0A */
    U32                     Reserved3;              /* 0x0C */
    U16                     CmdBufferLength;        /* 0x10 */
    U16                     Reserved4;              /* 0x12 */
    U32                     BaseAddressLow;         /* 0x14 */
    U32                     BaseAddressHigh;        /* 0x18 */
} MPI2_TARGET_CMD_BUF_POST_BASE_REQUEST,
  MPI2_POINTER PTR_MPI2_TARGET_CMD_BUF_POST_BASE_REQUEST,
  Mpi2TargetCmdBufferPostBaseRequest_t,
  MPI2_POINTER pMpi2TargetCmdBufferPostBaseRequest_t;

/* values for the BufferPostflags field */
#define MPI2_CMD_BUF_POST_BASE_ADDRESS_SPACE_MASK            (0x0C)
#define MPI2_CMD_BUF_POST_BASE_SYSTEM_ADDRESS_SPACE          (0x00)
#define MPI2_CMD_BUF_POST_BASE_IOCDDR_ADDRESS_SPACE          (0x04)
#define MPI2_CMD_BUF_POST_BASE_IOCPLB_ADDRESS_SPACE          (0x08)
#define MPI2_CMD_BUF_POST_BASE_IOCPLBNTA_ADDRESS_SPACE       (0x0C)

#define MPI2_CMD_BUF_POST_BASE_FLAGS_AUTO_POST_ALL           (0x01)

/****************************************************************************
*  Target Command Buffer Post List Request
****************************************************************************/

typedef struct _MPI2_TARGET_CMD_BUF_POST_LIST_REQUEST
{
    U16                     Reserved;               /* 0x00 */
    U8                      ChainOffset;            /* 0x02 */
    U8                      Function;               /* 0x03 */
    U16                     CmdBufferCount;         /* 0x04 */
    U8                      Reserved1;              /* 0x06 */
    U8                      MsgFlags;               /* 0x07 */
    U8                      VP_ID;                  /* 0x08 */
    U8                      VF_ID;                  /* 0x09 */
    U16                     Reserved2;              /* 0x0A */
    U32                     Reserved3;              /* 0x0C */
    U16                     IoIndex[2];             /* 0x10 */
} MPI2_TARGET_CMD_BUF_POST_LIST_REQUEST,
  MPI2_POINTER PTR_MPI2_TARGET_CMD_BUF_POST_LIST_REQUEST,
  Mpi2TargetCmdBufferPostListRequest_t,
  MPI2_POINTER pMpi2TargetCmdBufferPostListRequest_t;

/****************************************************************************
*  Target Command Buffer Post Base List Reply
****************************************************************************/

typedef struct _MPI2_TARGET_BUF_POST_BASE_LIST_REPLY
{
    U8                      Flags;                  /* 0x00 */
    U8                      Reserved;               /* 0x01 */
    U8                      MsgLength;              /* 0x02 */
    U8                      Function;               /* 0x03 */
    U16                     Reserved1;              /* 0x04 */
    U8                      Reserved2;              /* 0x06 */
    U8                      MsgFlags;               /* 0x07 */
    U8                      VP_ID;                  /* 0x08 */
    U8                      VF_ID;                  /* 0x09 */
    U16                     Reserved3;              /* 0x0A */
    U16                     Reserved4;              /* 0x0C */
    U16                     IOCStatus;              /* 0x0E */
    U32                     IOCLogInfo;             /* 0x10 */
    U16                     IoIndex;                /* 0x14 */
    U16                     Reserved5;              /* 0x16 */
    U32                     Reserved6;              /* 0x18 */
} MPI2_TARGET_BUF_POST_BASE_LIST_REPLY,
  MPI2_POINTER PTR_MPI2_TARGET_BUF_POST_BASE_LIST_REPLY,
  Mpi2TargetCmdBufferPostBaseListReply_t,
  MPI2_POINTER pMpi2TargetCmdBufferPostBaseListReply_t;

/* Flags defines */
#define MPI2_CMD_BUF_POST_REPLY_IOINDEX_VALID       (0x01)

/****************************************************************************
*  Command Buffer Formats (with 16 byte CDB)
****************************************************************************/

typedef struct _MPI2_TARGET_SSP_CMD_BUFFER
{
    U8      FrameType;                                  /* 0x00 */
    U8      Reserved1;                                  /* 0x01 */
    U16     InitiatorConnectionTag;                     /* 0x02 */
    U32     HashedSourceSASAddress;                     /* 0x04 */
    U16     Reserved2;                                  /* 0x08 */
    U16     Flags;                                      /* 0x0A */
    U32     Reserved3;                                  /* 0x0C */
    U16     Tag;                                        /* 0x10 */
    U16     TargetPortTransferTag;                      /* 0x12 */
    U32     DataOffset;                                 /* 0x14 */
    /* COMMAND information unit starts here */
    U8      LogicalUnitNumber[8];                       /* 0x18 */
    U8      Reserved4;                                  /* 0x20 */
    U8      TaskAttribute; /* lower 3 bits */           /* 0x21 */
    U8      Reserved5;                                  /* 0x22 */
    U8      AdditionalCDBLength; /* upper 5 bits */     /* 0x23 */
    U8      CDB[16];                                    /* 0x24 */
    /* Additional CDB bytes extend past the CDB field */
} MPI2_TARGET_SSP_CMD_BUFFER, MPI2_POINTER PTR_MPI2_TARGET_SSP_CMD_BUFFER,
  Mpi2TargetSspCmdBuffer, MPI2_POINTER pMp2iTargetSspCmdBuffer;

typedef struct _MPI2_TARGET_SSP_TASK_BUFFER
{
    U8      FrameType;                                  /* 0x00 */
    U8      Reserved1;                                  /* 0x01 */
    U16     InitiatorConnectionTag;                     /* 0x02 */
    U32     HashedSourceSASAddress;                     /* 0x04 */
    U16     Reserved2;                                  /* 0x08 */
    U16     Flags;                                      /* 0x0A */
    U32     Reserved3;                                  /* 0x0C */
    U16     Tag;                                        /* 0x10 */
    U16     TargetPortTransferTag;                      /* 0x12 */
    U32     DataOffset;                                 /* 0x14 */
    /* TASK information unit starts here */
    U8      LogicalUnitNumber[8];                       /* 0x18 */
    U16     Reserved4;                                  /* 0x20 */
    U8      TaskManagementFunction;                     /* 0x22 */
    U8      Reserved5;                                  /* 0x23 */
    U16     ManagedTaskTag;                             /* 0x24 */
    U16     Reserved6;                                  /* 0x26 */
    U32     Reserved7;                                  /* 0x28 */
    U32     Reserved8;                                  /* 0x2C */
    U32     Reserved9;                                  /* 0x30 */
} MPI2_TARGET_SSP_TASK_BUFFER, MPI2_POINTER PTR_MPI2_TARGET_SSP_TASK_BUFFER,
  Mpi2TargetSspTaskBuffer, MPI2_POINTER pMpi2TargetSspTaskBuffer;

/* mask and shift for HashedSourceSASAddress field */
#define MPI2_TARGET_HASHED_SAS_ADDRESS_MASK     (0xFFFFFF00)
#define MPI2_TARGET_HASHED_SAS_ADDRESS_SHIFT    (8)

/****************************************************************************
*   Target Assist Request
****************************************************************************/

typedef struct _MPI2_TARGET_ASSIST_REQUEST
{
    U8                  Reserved1;                          /* 0x00 */
    U8                  TargetAssistFlags;                  /* 0x01 */
    U8                  ChainOffset;                        /* 0x02 */
    U8                  Function;                           /* 0x03 */
    U16                 QueueTag;                           /* 0x04 */
    U8                  Reserved2;                          /* 0x06 */
    U8                  MsgFlags;                           /* 0x07 */
    U8                  VP_ID;                              /* 0x08 */
    U8                  VF_ID;                              /* 0x09 */
    U16                 Reserved3;                          /* 0x0A */
    U16                 IoIndex;                            /* 0x0C */
    U16                 InitiatorConnectionTag;             /* 0x0E */
    U16                 SGLFlags;                           /* 0x10 */
    U8                  SequenceNumber;                     /* 0x12 */
    U8                  Reserved4;                          /* 0x13 */
    U8                  SGLOffset0;                         /* 0x14 */
    U8                  SGLOffset1;                         /* 0x15 */
    U8                  SGLOffset2;                         /* 0x16 */
    U8                  SGLOffset3;                         /* 0x17 */
    U32                 SkipCount;                          /* 0x18 */
    U32                 DataLength;                         /* 0x1C */
    U32                 BidirectionalDataLength;            /* 0x20 */
    U16                 IoFlags;                            /* 0x24 */
    U16                 EEDPFlags;                          /* 0x26 */
    U32                 EEDPBlockSize;                      /* 0x28 */
    U32                 SecondaryReferenceTag;              /* 0x2C */
    U16                 SecondaryApplicationTag;            /* 0x30 */
    U16                 ApplicationTagTranslationMask;      /* 0x32 */
    U32                 PrimaryReferenceTag;                /* 0x34 */
    U16                 PrimaryApplicationTag;              /* 0x38 */
    U16                 PrimaryApplicationTagMask;          /* 0x3A */
    U32                 RelativeOffset;                     /* 0x3C */
    U32                 Reserved5;                          /* 0x40 */
    U32                 Reserved6;                          /* 0x44 */
    U32                 Reserved7;                          /* 0x48 */
    U32                 Reserved8;                          /* 0x4C */
    MPI2_SGE_IO_UNION   SGL[1];                             /* 0x50 */
} MPI2_TARGET_ASSIST_REQUEST, MPI2_POINTER PTR_MPI2_TARGET_ASSIST_REQUEST,
  Mpi2TargetAssistRequest_t, MPI2_POINTER pMpi2TargetAssistRequest_t;

/* Target Assist TargetAssistFlags bits */

#define MPI2_TARGET_ASSIST_FLAGS_REPOST_CMD_BUFFER      (0x80)
#define MPI2_TARGET_ASSIST_FLAGS_TLR                    (0x10)
#define MPI2_TARGET_ASSIST_FLAGS_RETRANSMIT             (0x04)
#define MPI2_TARGET_ASSIST_FLAGS_AUTO_STATUS            (0x02)
#define MPI2_TARGET_ASSIST_FLAGS_DATA_DIRECTION         (0x01)

/* Target Assist SGLFlags bits */

/* base values for Data Location Address Space */
#define MPI2_TARGET_ASSIST_SGLFLAGS_ADDR_MASK           (0x0C)
#define MPI2_TARGET_ASSIST_SGLFLAGS_SYSTEM_ADDR         (0x00)
#define MPI2_TARGET_ASSIST_SGLFLAGS_IOCDDR_ADDR         (0x04)
#define MPI2_TARGET_ASSIST_SGLFLAGS_IOCPLB_ADDR         (0x08)
#define MPI2_TARGET_ASSIST_SGLFLAGS_PLBNTA_ADDR         (0x0C)

/* base values for Type */
#define MPI2_TARGET_ASSIST_SGLFLAGS_TYPE_MASK           (0x03)
#define MPI2_TARGET_ASSIST_SGLFLAGS_MPI_TYPE            (0x00)
#define MPI2_TARGET_ASSIST_SGLFLAGS_32IEEE_TYPE         (0x01)
#define MPI2_TARGET_ASSIST_SGLFLAGS_64IEEE_TYPE         (0x02)

/* shift values for each sub-field */
#define MPI2_TARGET_ASSIST_SGLFLAGS_SGL3_SHIFT          (12)
#define MPI2_TARGET_ASSIST_SGLFLAGS_SGL2_SHIFT          (8)
#define MPI2_TARGET_ASSIST_SGLFLAGS_SGL1_SHIFT          (4)
#define MPI2_TARGET_ASSIST_SGLFLAGS_SGL0_SHIFT          (0)

/* Target Assist IoFlags bits */

#define MPI2_TARGET_ASSIST_IOFLAGS_BIDIRECTIONAL        (0x0800)
#define MPI2_TARGET_ASSIST_IOFLAGS_MULTICAST            (0x0400)
#define MPI2_TARGET_ASSIST_IOFLAGS_RECEIVE_FIRST        (0x0200)

/* Target Assist EEDPFlags bits */

#define MPI2_TA_EEDPFLAGS_INC_PRI_REFTAG            (0x8000)
#define MPI2_TA_EEDPFLAGS_INC_SEC_REFTAG            (0x4000)
#define MPI2_TA_EEDPFLAGS_INC_PRI_APPTAG            (0x2000)
#define MPI2_TA_EEDPFLAGS_INC_SEC_APPTAG            (0x1000)

#define MPI2_TA_EEDPFLAGS_CHECK_REFTAG              (0x0400)
#define MPI2_TA_EEDPFLAGS_CHECK_APPTAG              (0x0200)
#define MPI2_TA_EEDPFLAGS_CHECK_GUARD               (0x0100)

#define MPI2_TA_EEDPFLAGS_PASSTHRU_REFTAG           (0x0008)

#define MPI2_TA_EEDPFLAGS_MASK_OP                   (0x0007)
#define MPI2_TA_EEDPFLAGS_NOOP_OP                   (0x0000)
#define MPI2_TA_EEDPFLAGS_CHECK_OP                  (0x0001)
#define MPI2_TA_EEDPFLAGS_STRIP_OP                  (0x0002)
#define MPI2_TA_EEDPFLAGS_CHECK_REMOVE_OP           (0x0003)
#define MPI2_TA_EEDPFLAGS_INSERT_OP                 (0x0004)
#define MPI2_TA_EEDPFLAGS_REPLACE_OP                (0x0006)
#define MPI2_TA_EEDPFLAGS_CHECK_REGEN_OP            (0x0007)

/****************************************************************************
*  Target Status Send Request
****************************************************************************/

typedef struct _MPI2_TARGET_STATUS_SEND_REQUEST
{
    U8                      Reserved1;                  /* 0x00 */
    U8                      StatusFlags;                /* 0x01 */
    U8                      ChainOffset;                /* 0x02 */
    U8                      Function;                   /* 0x03 */
    U16                     QueueTag;                   /* 0x04 */
    U8                      Reserved2;                  /* 0x06 */
    U8                      MsgFlags;                   /* 0x07 */
    U8                      VP_ID;                      /* 0x08 */
    U8                      VF_ID;                      /* 0x09 */
    U16                     Reserved3;                  /* 0x0A */
    U16                     IoIndex;                    /* 0x0C */
    U16                     InitiatorConnectionTag;     /* 0x0E */
    U16                     SGLFlags;                   /* 0x10 */
    U16                     Reserved4;                  /* 0x12 */
    U8                      SGLOffset0;                 /* 0x14 */
    U8                      Reserved5;                  /* 0x15 */
    U16                     Reserved6;                  /* 0x16 */
    U32                     Reserved7;                  /* 0x18 */
    U32                     Reserved8;                  /* 0x1C */
    MPI2_SIMPLE_SGE_UNION   StatusDataSGE;              /* 0x20 */
} MPI2_TARGET_STATUS_SEND_REQUEST,
  MPI2_POINTER PTR_MPI2_TARGET_STATUS_SEND_REQUEST,
  Mpi2TargetStatusSendRequest_t, MPI2_POINTER pMpi2TargetStatusSendRequest_t;

/* Target Status Send StatusFlags bits */

#define MPI2_TSS_FLAGS_REPOST_CMD_BUFFER            (0x80)
#define MPI2_TSS_FLAGS_RETRANSMIT                   (0x04)
#define MPI2_TSS_FLAGS_AUTO_GOOD_STATUS             (0x01)

/* Target Status Send SGLFlags bits */
/* Data Location Address Space */
#define MPI2_TSS_SGLFLAGS_ADDR_MASK                 (0x0C)
#define MPI2_TSS_SGLFLAGS_SYSTEM_ADDR               (0x00)
#define MPI2_TSS_SGLFLAGS_IOCDDR_ADDR               (0x04)
#define MPI2_TSS_SGLFLAGS_IOCPLB_ADDR               (0x08)
#define MPI2_TSS_SGLFLAGS_IOCPLBNTA_ADDR            (0x0C)
/* Type */
#define MPI2_TSS_SGLFLAGS_TYPE_MASK                 (0x03)
#define MPI2_TSS_SGLFLAGS_MPI_TYPE                  (0x00)
#define MPI2_TSS_SGLFLAGS_IEEE32_TYPE               (0x01)
#define MPI2_TSS_SGLFLAGS_IEEE64_TYPE               (0x02)

/*
 * NOTE: The SSP status IU is big-endian. When used on a little-endian system,
 * this structure properly orders the bytes.
 */
typedef struct _MPI2_TARGET_SSP_RSP_IU
{
    U32     Reserved0[6]; /* reserved for SSP header */ /* 0x00 */

    /* start of RESPONSE information unit */
    U32     Reserved1;                                  /* 0x18 */
    U32     Reserved2;                                  /* 0x1C */
    U16     Reserved3;                                  /* 0x20 */
    U8      DataPres; /* lower 2 bits */                /* 0x22 */
    U8      Status;                                     /* 0x23 */
    U32     Reserved4;                                  /* 0x24 */
    U32     SenseDataLength;                            /* 0x28 */
    U32     ResponseDataLength;                         /* 0x2C */

    /* start of Response or Sense Data (size may vary dynamically) */
    U8      ResponseSenseData[4];                       /* 0x30 */
} MPI2_TARGET_SSP_RSP_IU, MPI2_POINTER PTR_MPI2_TARGET_SSP_RSP_IU,
  Mpi2TargetSspRspIu_t, MPI2_POINTER pMpi2TargetSspRspIu_t;

/****************************************************************************
*  Target Standard Reply - used with Target Assist or Target Status Send
****************************************************************************/

typedef struct _MPI2_TARGET_STANDARD_REPLY
{
    U16                     Reserved;                   /* 0x00 */
    U8                      MsgLength;                  /* 0x02 */
    U8                      Function;                   /* 0x03 */
    U16                     Reserved1;                  /* 0x04 */
    U8                      Reserved2;                  /* 0x06 */
    U8                      MsgFlags;                   /* 0x07 */
    U8                      VP_ID;                      /* 0x08 */
    U8                      VF_ID;                      /* 0x09 */
    U16                     Reserved3;                  /* 0x0A */
    U16                     Reserved4;                  /* 0x0C */
    U16                     IOCStatus;                  /* 0x0E */
    U32                     IOCLogInfo;                 /* 0x10 */
    U16                     IoIndex;                    /* 0x14 */
    U16                     Reserved5;                  /* 0x16 */
    U32                     TransferCount;              /* 0x18 */
    U32                     BidirectionalTransferCount; /* 0x1C */
} MPI2_TARGET_STANDARD_REPLY, MPI2_POINTER PTR_MPI2_TARGET_STANDARD_REPLY,
  Mpi2TargetErrorReply_t, MPI2_POINTER pMpi2TargetErrorReply_t;

/****************************************************************************
*  Target Mode Abort Request
****************************************************************************/

typedef struct _MPI2_TARGET_MODE_ABORT_REQUEST
{
    U8                      AbortType;                  /* 0x00 */
    U8                      Reserved1;                  /* 0x01 */
    U8                      ChainOffset;                /* 0x02 */
    U8                      Function;                   /* 0x03 */
    U16                     Reserved2;                  /* 0x04 */
    U8                      Reserved3;                  /* 0x06 */
    U8                      MsgFlags;                   /* 0x07 */
    U8                      VP_ID;                      /* 0x08 */
    U8                      VF_ID;                      /* 0x09 */
    U16                     Reserved4;                  /* 0x0A */
    U16                     IoIndexToAbort;             /* 0x0C */
    U16                     Reserved6;                  /* 0x0E */
    U32                     MidToAbort;                 /* 0x10 */
} MPI2_TARGET_MODE_ABORT, MPI2_POINTER PTR_MPI2_TARGET_MODE_ABORT,
  Mpi2TargetModeAbort_t, MPI2_POINTER pMpi2TargetModeAbort_t;

/* Target Mode Abort AbortType values */

#define MPI2_TARGET_MODE_ABORT_ALL_CMD_BUFFERS      (0x00)
#define MPI2_TARGET_MODE_ABORT_ALL_IO               (0x01)
#define MPI2_TARGET_MODE_ABORT_EXACT_IO             (0x02)
#define MPI2_TARGET_MODE_ABORT_EXACT_IO_REQUEST     (0x03)
#define MPI2_TARGET_MODE_ABORT_IO_REQUEST_AND_IO    (0x04)

/****************************************************************************
*  Target Mode Abort Reply
****************************************************************************/

typedef struct _MPI2_TARGET_MODE_ABORT_REPLY
{
    U16                     Reserved;                   /* 0x00 */
    U8                      MsgLength;                  /* 0x02 */
    U8                      Function;                   /* 0x03 */
    U16                     Reserved1;                  /* 0x04 */
    U8                      Reserved2;                  /* 0x06 */
    U8                      MsgFlags;                   /* 0x07 */
    U8                      VP_ID;                      /* 0x08 */
    U8                      VF_ID;                      /* 0x09 */
    U16                     Reserved3;                  /* 0x0A */
    U16                     Reserved4;                  /* 0x0C */
    U16                     IOCStatus;                  /* 0x0E */
    U32                     IOCLogInfo;                 /* 0x10 */
    U32                     AbortCount;                 /* 0x14 */
} MPI2_TARGET_MODE_ABORT_REPLY, MPI2_POINTER PTR_MPI2_TARGET_MODE_ABORT_REPLY,
  Mpi2TargetModeAbortReply_t, MPI2_POINTER pMpi2TargetModeAbortReply_t;

#endif