Mac OS X Reference Library Apple Developer
Search

SCSICmds_REPORT_LUNS_Definitions.h

Includes:
<IOKit/IOTypes.h>
<CoreFoundation/CoreFoundation.h>

Overview

This file contains all definitions for the data returned from the REPORT_LUNS (0xA0) command.



Typedefs

REPORT_LUNS_LOGICAL_UNIT_ADDRESSING
REPORT_LUNS_PERIPHERAL_DEVICE_ADDRESSING
SCSICmd_REPORT_LUNS_LUN_ENTRY

REPORT_LUNS_LOGICAL_UNIT_ADDRESSING



typedef struct REPORT_LUNS_LOGICAL_UNIT_ADDRESSING { 
    #ifdef __LITTLE_ENDIAN__ 
    UInt16 LUN : 5; 
    UInt16 BUS_NUMBER : 3; 
    UInt16 TARGET : 6; 
    UInt16 reserved2 : 1; 
    UInt16 reserved : 1; 
    #else /* !__LITTLE_ENDIAN__ */
    UInt16 reserved : 1; 
    UInt16 reserved2 : 1; 
    UInt16 TARGET : 6; 
    UInt16 BUS_NUMBER : 3; 
    UInt16 LUN : 5; 
    #endif 
    /* !__LITTLE_ENDIAN__ */
} REPORT_LUNS_LOGICAL_UNIT_ADDRESSING;  
Discussion

This structure represents a LUN Addressing scheme.


REPORT_LUNS_PERIPHERAL_DEVICE_ADDRESSING



typedef struct REPORT_LUNS_PERIPHERAL_DEVICE_ADDRESSING { 
    #ifdef __LITTLE_ENDIAN__ 
    UInt16 TARGET_LUN : 8; 
    UInt16 BUS_IDENTIFIER : 6; 
    UInt16 reserved2 : 1; 
    UInt16 reserved : 1; 
    #else /* !__LITTLE_ENDIAN__ */
    UInt16 reserved : 1; 
    UInt16 reserved2 : 1; 
    UInt16 BUS_IDENTIFIER : 6; 
    UInt16 TARGET_LUN : 8; 
    #endif 
    /* !__LITTLE_ENDIAN__ */
} REPORT_LUNS_PERIPHERAL_DEVICE_ADDRESSING;  
Discussion

This structure represents a Peripheral Device Addressing scheme.


SCSICmd_REPORT_LUNS_LUN_ENTRY



typedef struct SCSICmd_REPORT_LUNS_LUN_ENTRY { 
    UInt16 FIRST_LEVEL_ADDRESSING; 
    UInt16 SECOND_LEVEL_ADDRESSING; 
    UInt16 THIRD_LEVEL_ADDRESSING; 
    UInt16 FOURTH_LEVEL_ADDRESSING; 
} SCSICmd_REPORT_LUNS_LUN_ENTRY;  
Discussion

This structure represents a single LUN entry in a LUN list returned via the REPORT_LUNS command.

Structs and Unions

SCSICmd_REPORT_LUNS_Header

SCSICmd_REPORT_LUNS_Header



typedef struct SCSICmd_REPORT_LUNS_Header { 
    UInt32 LUN_LIST_LENGTH; // LUN list length in bytes. 
    UInt32 RESERVED; 
    SCSICmd_REPORT_LUNS_LUN_ENTRY LUN[1]; // Variable length list. Must have at least LUN 0 if 
} SCSICmd_REPORT_LUNS_Header;  // Target supports REPORT_LUNS command. 
Discussion

This structure defines the format of the data that is returned for the REPORT_LUNS command.

Enumerated Types

REPORT_LUNS addressing methods.

REPORT_LUNS addressing methods.



enum { 
    kREPORT_LUNS_ADDRESS_METHOD_PERIPHERAL_DEVICE = 0, 
    kREPORT_LUNS_ADDRESS_DEVICE_TYPE_SPECIFIC = 1, 
    kREPORT_LUNS_ADDRESS_METHOD_LOGICAL_UNIT = 2, 
    // Reserved [3] 
    kREPORT_LUNS_ADDRESS_METHOD_OFFSET = 14 
};  
Constants
kREPORT_LUNS_ADDRESS_METHOD_PERIPHERAL_DEVICE

Peripheral Device Addressing Method.

kREPORT_LUNS_ADDRESS_DEVICE_TYPE_SPECIFIC

Device Type Specific Addressing Method.

kREPORT_LUNS_ADDRESS_METHOD_LOGICAL_UNIT

Logical Unit Specific Addressing Method.

kREPORT_LUNS_ADDRESS_METHOD_OFFSET

Offset to the address method data.

Discussion

REPORT_LUNS addressing methods described in SAM-2 documents.

Macro Definitions

kREPORT_LUNS_HeaderSize

kREPORT_LUNS_HeaderSize


Discussion

Size of the REPORT_LUNS header as defined in the SPC-3 specification.

 

Did this document help you? Yes It's good, but... Not helpful...

Last Updated: 2010-07-29