Mac Developer Library

Developer

SCSICmds_MODE_Definitions.h Reference

Options
Deployment Target:

On This Page

SCSICmds_MODE_Definitions.h Reference

Inheritance


Not Applicable

Conforms To


Not Applicable

Import Statement


Not Applicable

Objective-C

@import IOKit;

This file contains all definitions for the data returned from the MODE_SENSE_6 and MODE_SENSE_10 commands.

Included Headers

  • <IOKit/IOTypes.h>

  • <CoreFoundation/CoreFoundation.h>

Data Types

See the Overview section above for header-level documentation.

  • Declaration

    Objective-C

    typedef struct DASDModeParameterBlockDescriptor { UInt32 NUMBER_OF_BLOCKS; UInt8 DENSITY_CODE; UInt8 BLOCK_LENGTH[3]; } DASDModeParameterBlockDescriptor;

    Discussion

    Direct Access Storage Device mode parameter block descriptor.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct LongLBAModeParameterBlockDescriptor { UInt64 NUMBER_OF_BLOCKS; UInt8 DENSITY_CODE; UInt8 RESERVED[3]; UInt32 BLOCK_LENGTH; } LongLBAModeParameterBlockDescriptor;

    Discussion

    Long LBA mode parameter block descriptor.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct ModePageFormatHeader { UInt8 PS_PAGE_CODE; UInt8 PAGE_LENGTH; } ModePageFormatHeader;

    Discussion

    Mode Page format header.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct ModeParameterBlockDescriptor { UInt8 DENSITY_CODE; UInt8 NUMBER_OF_BLOCKS[3]; UInt8 RESERVED; UInt8 BLOCK_LENGTH[3]; } ModeParameterBlockDescriptor;

    Discussion

    General mode parameter block descriptor.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SBCModePageCaching { ModePageFormatHeader header; UInt8 flags; UInt8 DEMAND_READ_WRITE_RETENTION_PRIORITY; UInt16 DISABLE_PREFETCH_TRANSFER_LENGTH; UInt16 MINIMUM_PREFETCH; UInt16 MAXIMUM_PREFETCH; UInt16 MAXIMUM_PREFETCH_CEILING; UInt8 flags2; UInt8 NUMBER_OF_CACHE_SEGMENTS; UInt16 CACHE_SEGMENT_SIZE; UInt8 RESERVED; UInt8 NON_CACHE_SEGMENT_SIZE[3]; } SBCModePageCaching;

    Discussion

    Caching Mode Page (PAGE CODE 0x08) format.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SBCModePageFlexibleDisk { ModePageFormatHeader header; UInt16 TRANSFER_RATE; UInt8 NUMBER_OF_HEADS; UInt8 SECTORS_PER_TRACK; UInt16 DATA_BYTES_PER_SECTOR; UInt16 NUMBER_OF_CYLINDERS; UInt16 STARTING_CYLINDER_WRITE_PRECOMPENSATION; UInt16 STARTING_CYLINDER_REDUCED_WRITE_CURRENT; UInt16 DEVICE_STEP_RATE; UInt8 DEVICE_STEP_PULSE_WIDTH; UInt16 HEAD_SETTLE_DELAY; UInt8 MOTOR_ON_DELAY; UInt8 MOTOR_OFF_DELAY; UInt8 TRDY_SSN_MO; UInt8 SPC; UInt8 WRITE_COMPENSATION; UInt8 HEAD_LOAD_DELAY; UInt8 HEAD_UNLOAD_DELAY; UInt8 PIN_34_PIN_2; UInt8 PIN_4_PIN_1; UInt16 MEDIUM_ROTATION_RATE; UInt8 RESERVED[2]; } SBCModePageFlexibleDisk;

    Discussion

    Flexible Disk Mode Page (PAGE CODE 0x05) format.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SBCModePageFormatDevice { ModePageFormatHeader header; UInt16 TRACKS_PER_ZONE; UInt16 ALTERNATE_SECTORS_PER_ZONE; UInt16 ALTERNATE_TRACKS_PER_ZONE; UInt16 ALTERNATE_TRACKS_PER_LOGICAL_UNIT; UInt16 SECTORS_PER_TRACK; UInt16 DATA_BYTES_PER_PHYSICAL_SECTOR; UInt16 INTERLEAVE; UInt16 TRACK_SKEW_FACTOR; UInt16 CYLINDER_SKEW_FACTOR; UInt8 SSEC_HSEC_RMB_SURF; UInt8 RESERVED[3]; } SBCModePageFormatDevice;

    Discussion

    Format Device Mode Page (PAGE CODE 0x03) format.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SBCModePageRigidDiskGeometry { ModePageFormatHeader header; UInt8 NUMBER_OF_CYLINDERS[3]; UInt8 NUMBER_OF_HEADS; UInt8 STARTING_CYLINDER_WRITE_PRECOMPENSATION[3]; UInt8 STARTING_CYLINDER_REDUCED_WRITE_CURRENT[3]; UInt16 DEVICE_STEP_RATE; UInt8 LANDING_ZONE_CYLINDER[3]; UInt8 RPL; UInt8 ROTATIONAL_OFFSET; UInt8 RESERVED; UInt16 MEDIUM_ROTATION_RATE; UInt8 RESERVED1[2]; } SBCModePageRigidDiskGeometry;

    Discussion

    Rigid Disk Geometry Mode Page (PAGE CODE 0x04) format.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SPCModePagePowerCondition { ModePageFormatHeader header; UInt8 RESERVED; UInt8 IDLE_STANDBY; UInt32 IDLE_CONDITION_TIMER; UInt32 STANDBY_CONDITION_TIMER; } SPCModePagePowerCondition;

    Discussion

    Power Conditions Mode Page (PAGE CODE 0x1A) format.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SPCModeParameterHeader10 { UInt16 MODE_DATA_LENGTH; UInt8 MEDIUM_TYPE; UInt8 DEVICE_SPECIFIC_PARAMETER; UInt8 LONGLBA; UInt8 RESERVED; UInt16 BLOCK_DESCRIPTOR_LENGTH; } SPCModeParameterHeader10;

    Discussion

    Mode Parameter Header for the MODE_SENSE_10 command.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

  • Declaration

    Objective-C

    typedef struct SPCModeParameterHeader6 { UInt8 MODE_DATA_LENGTH; UInt8 MEDIUM_TYPE; UInt8 DEVICE_SPECIFIC_PARAMETER; UInt8 BLOCK_DESCRIPTOR_LENGTH; } SPCModeParameterHeader6;

    Discussion

    Mode Parameter Header for the MODE_SENSE_6 command.

    Import Statement

    Objective-C

    @import IOKit;

    Availability

    Available in OS X v10.3 and later.

Constants

See the Overview section above for header-level documentation.

  • Declaration

    Objective-C

    enum { kSBCModePageCaching_RCD_Bit = 0, kSBCModePageCaching_MF_Bit = 1, kSBCModePageCaching_WCE_Bit = 2, kSBCModePageCaching_SIZE_Bit = 3, kSBCModePageCaching_DISC_Bit = 4, kSBCModePageCaching_CAP_Bit = 5, kSBCModePageCaching_ABPF_Bit = 6, kSBCModePageCaching_IC_Bit = 7, kSBCModePageCaching_RCD_Mask = ( 1 << kSBCModePageCaching_RCD_Bit ), kSBCModePageCaching_MF_Mask = ( 1 << kSBCModePageCaching_MF_Bit ), kSBCModePageCaching_WCE_Mask = ( 1 << kSBCModePageCaching_WCE_Bit ), kSBCModePageCaching_SIZE_Mask = ( 1 << kSBCModePageCaching_SIZE_Bit ), kSBCModePageCaching_DISC_Mask = ( 1 << kSBCModePageCaching_DISC_Bit ), kSBCModePageCaching_CAP_Mask = ( 1 << kSBCModePageCaching_CAP_Bit ), kSBCModePageCaching_ABPF_Mask = ( 1 << kSBCModePageCaching_ABPF_Bit ), kSBCModePageCaching_IC_Mask = ( 1 << kSBCModePageCaching_IC_Bit ) };

    Constants

    • kSBCModePageCaching_RCD_Bit

      kSBCModePageCaching_RCD_Bit

      RCD Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_MF_Bit

      kSBCModePageCaching_MF_Bit

      MF Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_WCE_Bit

      kSBCModePageCaching_WCE_Bit

      WCE Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_SIZE_Bit

      kSBCModePageCaching_SIZE_Bit

      SIZE Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_DISC_Bit

      kSBCModePageCaching_DISC_Bit

      DISC Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_CAP_Bit

      kSBCModePageCaching_CAP_Bit

      CAP Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_ABPF_Bit

      kSBCModePageCaching_ABPF_Bit

      ABPF Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_IC_Bit

      kSBCModePageCaching_IC_Bit

      IC Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_RCD_Mask

      kSBCModePageCaching_RCD_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_MF_Mask

      kSBCModePageCaching_MF_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_WCE_Mask

      kSBCModePageCaching_WCE_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_SIZE_Mask

      kSBCModePageCaching_SIZE_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_DISC_Mask

      kSBCModePageCaching_DISC_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_CAP_Mask

      kSBCModePageCaching_CAP_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_ABPF_Mask

      kSBCModePageCaching_ABPF_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_IC_Mask

      kSBCModePageCaching_IC_Mask

      Mask for use with flags field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Caching flags field.

  • Declaration

    Objective-C

    enum { // Bits 0:2 Reserved kSBCModePageCaching_VS1_Bit = 3, kSBCModePageCaching_VS2_Bit = 4, kSBCModePageCaching_DRA_Bit = 5, kSBCModePageCaching_LBCSS_Bit = 6, kSBCModePageCaching_FSW_Bit = 7, kSBCModePageCaching_VS1_Mask = ( 1 << kSBCModePageCaching_VS1_Bit ), kSBCModePageCaching_VS2_Mask = ( 1 << kSBCModePageCaching_VS2_Bit ), kSBCModePageCaching_DRA_Mask = ( 1 << kSBCModePageCaching_DRA_Bit ), kSBCModePageCaching_LBCSS_Mask = ( 1 << kSBCModePageCaching_LBCSS_Bit ), kSBCModePageCaching_FSW_Mask = ( 1 << kSBCModePageCaching_FSW_Bit ) };

    Constants

    • kSBCModePageCaching_VS1_Bit

      kSBCModePageCaching_VS1_Bit

      VS1 Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_VS2_Bit

      kSBCModePageCaching_VS2_Bit

      VS2 Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_DRA_Bit

      kSBCModePageCaching_DRA_Bit

      DRA Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_LBCSS_Bit

      kSBCModePageCaching_LBCSS_Bit

      LBCSS Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_FSW_Bit

      kSBCModePageCaching_FSW_Bit

      FSW Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_VS1_Mask

      kSBCModePageCaching_VS1_Mask

      Mask for use with flags2 field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_VS2_Mask

      kSBCModePageCaching_VS2_Mask

      Mask for use with flags2 field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_DRA_Mask

      kSBCModePageCaching_DRA_Mask

      Mask for use with flags2 field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_LBCSS_Mask

      kSBCModePageCaching_LBCSS_Mask

      Mask for use with flags2 field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_FSW_Mask

      kSBCModePageCaching_FSW_Mask

      Mask for use with flags2 field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Caching flags2 field.

  • Declaration

    Objective-C

    enum { kSBCModePageCaching_DEMAND_WRITE_Mask = 0x00FF, kSBCModePageCaching_DEMAND_READ_Mask = 0xFF00 };

    Constants

    • kSBCModePageCaching_DEMAND_WRITE_Mask

      kSBCModePageCaching_DEMAND_WRITE_Mask

      Mask for the DEMAND_READ_WRITE_RETENTION_PRIORITY field.

      Available in OS X v10.3 and later.

    • kSBCModePageCaching_DEMAND_READ_Mask

      kSBCModePageCaching_DEMAND_READ_Mask

      Mask for the DEMAND_READ_WRITE_RETENTION_PRIORITY field.

      Available in OS X v10.3 and later.

    Discussion

    Demand Read/Write Retention masks.

  • Declaration

    Objective-C

    enum { kModeSenseSBCDeviceSpecific_DPOFUABit = 4, kModeSenseSBCDeviceSpecific_WriteProtectBit = 7, kModeSenseSBCDeviceSpecific_DPOFUAMask = ( 1 << kModeSenseSBCDeviceSpecific_DPOFUABit ), kModeSenseSBCDeviceSpecific_WriteProtectMask = ( 1 << kModeSenseSBCDeviceSpecific_WriteProtectBit ) };

    Constants

    • kModeSenseSBCDeviceSpecific_DPOFUABit

      kModeSenseSBCDeviceSpecific_DPOFUABit

      Bit to indicate DPO and FUA bits are accepted by the device server.

      Available in OS X v10.6 and later.

    • kModeSenseSBCDeviceSpecific_WriteProtectBit

      kModeSenseSBCDeviceSpecific_WriteProtectBit

      Bit to indicate medium is write protected.

      Available in OS X v10.3 and later.

    • kModeSenseSBCDeviceSpecific_DPOFUAMask

      kModeSenseSBCDeviceSpecific_DPOFUAMask

      Mask to test for kModeSenseSBCDeviceSpecific_DPOFUABit.

      Available in OS X v10.6 and later.

    • kModeSenseSBCDeviceSpecific_WriteProtectMask

      kModeSenseSBCDeviceSpecific_WriteProtectMask

      Mask to test for kModeSenseSBCDeviceSpecific_WriteProtectBit.

      Available in OS X v10.3 and later.

    Discussion

    SBC definitions for Device Specific Parameter in the Mode Sense Header Block.

  • Declaration

    Objective-C

    enum { kModeSenseParameterHeader10_LongLBABit = 0, kModeSenseParameterHeader10_LongLBAMask = ( 1 << kModeSenseParameterHeader10_LongLBABit ), };

    Constants

    • kModeSenseParameterHeader10_LongLBABit

      kModeSenseParameterHeader10_LongLBABit

      Bit to indicate Long LBA block descriptors follow.

      Available in OS X v10.3 and later.

    • kModeSenseParameterHeader10_LongLBAMask

      kModeSenseParameterHeader10_LongLBAMask

      Mask to test for kModeSenseParameterHeader10_LongLBABit.

      Available in OS X v10.3 and later.

    Discussion

    Long LBA Bitfield definitions for Mode Parameter Header for MODE_SENSE_10 command.

  • Declaration

    Objective-C

    enum { kModePageFormat_PS_Bit = 7, kModePageFormat_PAGE_CODE_Mask = 0x3F, kModePageFormat_PS_Mask = ( 1 << kModePageFormat_PS_Bit ) };

    Constants

    • kModePageFormat_PS_Bit

      kModePageFormat_PS_Bit

      Bit to indicate Parameters Saveable.

      Available in OS X v10.3 and later.

    • kModePageFormat_PAGE_CODE_Mask

      kModePageFormat_PAGE_CODE_Mask

      Mask to obtain the PAGE_CODE from the PS_PAGE_CODE field.

      Available in OS X v10.3 and later.

    • kModePageFormat_PS_Mask

      kModePageFormat_PS_Mask

      Mask to test for kModePageFormat_PS_Bit.

      Available in OS X v10.3 and later.

    Discussion

    Mode Page Format bit definitions.

  • Declaration

    Objective-C

    enum { kSBCModePageFlexibleDisk_PIN_2_Mask = 0x0F, kSBCModePageFlexibleDisk_PIN_34_Mask = 0xF0 };

    Constants

    • kSBCModePageFlexibleDisk_PIN_2_Mask

      kSBCModePageFlexibleDisk_PIN_2_Mask

      Mask for use with PIN_34_PIN_2 field.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_PIN_34_Mask

      kSBCModePageFlexibleDisk_PIN_34_Mask

      Mask for use with PIN_34_PIN_2 field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Flexible Disk PIN_34_PIN_2 field.

  • Declaration

    Objective-C

    enum { kSBCModePageFlexibleDisk_PIN_1_Mask = 0x0F, kSBCModePageFlexibleDisk_PIN_4_Mask = 0xF0 };

    Constants

    • kSBCModePageFlexibleDisk_PIN_1_Mask

      kSBCModePageFlexibleDisk_PIN_1_Mask

      Mask for use with PIN_4_PIN_1 field.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_PIN_4_Mask

      kSBCModePageFlexibleDisk_PIN_4_Mask

      Mask for use with PIN_4_PIN_1 field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Flexible Disk PIN_4_PIN_1 field.

  • Declaration

    Objective-C

    enum { kSBCModePageRigidDiskGeometry_RPL_Mask = 0x03 };

    Constants

    • kSBCModePageRigidDiskGeometry_RPL_Mask

      kSBCModePageRigidDiskGeometry_RPL_Mask

      Mask for use with the RPL field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field masks for Rigid Disk Geometry structure fields.

  • Declaration

    Objective-C

    enum { kSBCModePageFormatDeviceCode = 0x03, kSBCModePageRigidDiskGeometryCode = 0x04, kSBCModePageFlexibleDiskCode = 0x05, kSBCModePageCachingCode = 0x08 };

    Constants

    • kSBCModePageFormatDeviceCode

      kSBCModePageFormatDeviceCode

      Format Device Mode Page value.

      Available in OS X v10.3 and later.

    • kSBCModePageRigidDiskGeometryCode

      kSBCModePageRigidDiskGeometryCode

      Rigid Disk Geometry Page value.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDiskCode

      kSBCModePageFlexibleDiskCode

      Flexible Disk Page value.

      Available in OS X v10.3 and later.

    • kSBCModePageCachingCode

      kSBCModePageCachingCode

      Caching Page value.

      Available in OS X v10.3 and later.

    Discussion

    SBC Mode Page definitions.

  • Declaration

    Objective-C

    enum { kSBCModePageFlexibleDisk_SPC_Mask = 0x0F };

    Constants

    • kSBCModePageFlexibleDisk_SPC_Mask

      kSBCModePageFlexibleDisk_SPC_Mask

      Mask for use with SPC field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Flexible Disk SPC field.

  • Declaration

    Objective-C

    enum { kSPCModePagePowerConditionCode = 0x1A, kSPCModePageAllPagesCode = 0x3F };

    Constants

    • kSPCModePagePowerConditionCode

      kSPCModePagePowerConditionCode

      Power Conditions Mode Page value.

      Available in OS X v10.3 and later.

    • kSPCModePageAllPagesCode

      kSPCModePageAllPagesCode

      All Mode Pages value.

      Available in OS X v10.5 and later.

    Discussion

    SPC Mode Page definitions.

  • Declaration

    Objective-C

    enum { // Bits 0:4 Reserved kSBCModePageFlexibleDisk_MO_Bit = 5, kSBCModePageFlexibleDisk_SSN_Bit = 6, kSBCModePageFlexibleDisk_TRDY_Bit = 7, kSBCModePageFlexibleDisk_MO_Mask = ( 1 << kSBCModePageFlexibleDisk_MO_Bit ), kSBCModePageFlexibleDisk_SSN_Mask = ( 1 << kSBCModePageFlexibleDisk_SSN_Bit ), kSBCModePageFlexibleDisk_TRDY_Mask = ( 1 << kSBCModePageFlexibleDisk_TRDY_Bit ) };

    Constants

    • kSBCModePageFlexibleDisk_MO_Bit

      kSBCModePageFlexibleDisk_MO_Bit

      MO Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_SSN_Bit

      kSBCModePageFlexibleDisk_SSN_Bit

      SSN Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_TRDY_Bit

      kSBCModePageFlexibleDisk_TRDY_Bit

      TRDY Bit definition.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_MO_Mask

      kSBCModePageFlexibleDisk_MO_Mask

      Mask for use with TRDY_SSN_MO field.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_SSN_Mask

      kSBCModePageFlexibleDisk_SSN_Mask

      Mask for use with TRDY_SSN_MO field.

      Available in OS X v10.3 and later.

    • kSBCModePageFlexibleDisk_TRDY_Mask

      kSBCModePageFlexibleDisk_TRDY_Mask

      Mask for use with TRDY_SSN_MO field.

      Available in OS X v10.3 and later.

    Discussion

    Bit field definitions and masks for Flexible Disk TRDY_SSN_MO field.