DCB


#include <dcb.h>

typedef struct  _DCB { 
    DCB_COMMON  DCB_cmn;              // common information
    ULONG  DCB_max_xfer_len;          // maximum transfer length 

// Actual geometry data (as seen below the TSD)
    ULONG  DCB_actual_sector_cnt[2];  // number of sectors 
    ULONG  DCB_actual_blk_size;       // actual block size of the device  
    ULONG  DCB_actual_head_cnt;       // number of heads
    ULONG  DCB_actual_cyl_cnt;        // number of cylinders
    ULONG  DCB_actual_spt;            // number of sectors per track

    PVOID  DCB_next_ddb_dcb;          // link to next DCB on DDB chain 
    PVOID  DCB_dev_node;              // address of dev node for device 
    BYTE   DCB_bus_type;              // Bus type; see below
    BYTE   DCB_bus_number;            // channel (cable) within adapter   
    UCHAR  DCB_queue_freeze;          // queue freeze depth counter 
    UCHAR  DCB_max_sg_elements;       // max # s/g elements; see below

// Volume tracking layer use only
    UCHAR  DCB_io_pend_count;         // # of pending requests for DCB
    UCHAR  DCB_lock_count;            // # of LOCK MEDIA commands 

// SCSI
    USHORT DCB_SCSI_VSD_FLAGS;        // Flags for SRB builder
    BYTE   DCB_scsi_target_id;        // SCSI target ID 
    BYTE   DCB_scsi_lun;              // SCSI logical unit number      
    BYTE   DCB_scsi_hba;              // prot-driver-relative adapter #
    BYTE   DCB_max_sense_data_len;    // Maximum sense length
    USHORT DCB_srb_ext_size;          // miniport srb extension length

    BYTE   DCB_inquiry_flags[8];      // Device inquiry flags
    BYTE   DCB_vendor_id[8];          // Vendor ID string
    BYTE   DCB_product_id[16];        // Product ID string
    BYTE   DCB_rev_level[4];          // Product revision level
    BYTE   DCB_port_name[8];          // 
    UCHAR  DCB_current_unit;          // current unit #; see below

// Volume tracking layer use only
    ULONG  DCB_blocked_iop;           // address of requests for an 
                                      //  inactive volume 

    ULONG  DCB_vol_unlock_timer;      // unlock timer handle 
    UCHAR  DCB_access_timer;          // time measure between accesses 

// Volume tracking layer use only
    UCHAR  DCB_Vol_Flags;             // Volume tracking; see below

    BYTE  DCB_q_algo;                 // algorithm index; see below
    BYTE  DCB_unit_on_ctl;            // 0-based device number on ctlr
    ULONG  DCB_Port_Specific;         // bytes for port driver use
    ULONG  DCB_spindown_timer;        // timer for drive spin down

    DCB_BLOCKDEV  DCB_bdd;
} DCB, *PDCB;

Contains device control block information for physical devices.

DCB_bus_type

Bus type. Can be one of these values:

DCB_BUS_ESDI

ESDI BUS

DCB_BUS_SCSI

SCSI BUS

DCB_BUS_NEC

NEC BUS

DCB_BUS_SMART

SMART BUS

DCB_BUS_ABIOS

ABIOS BUS


DCB_max_sg_elements

Maximum number of scatter/gather elements. This value is set initially by the port driver, but may be more restrictively updated by other layer drivers.

DCB_current_unit

Used to emulate multiple logical devices with a single physical device.

DCB_vol_flags

Volume tracking flags. Can be one of these values:

DCB_VF_INHIBIT_LOCKING

Indicates locking is temporarily inhibited

DCB_VF_INHIBIT_IO

Indicates i/o is temporarily inhibited (event scheduled in volume tracker).

DCB_VF_INHIBIT_GEOM_RECOMPUTE

Indicates geometry recompute is temporarily inhibited.

DCB_VF_UNLOCK_SCHED

Indicates unlock event is scheduled.

DCB_VF_NEED_PHYS_RECOMP

Indicates that a mapper drive needs a compute geometry request sent to the physical drive with same number as the given logical drive.

DCB_VF_PROT_NEC_DRIVE

Indicates that this DCB has a corresponding protected mode physical NEC driver.


DCB_q_algo

Queuing algorithm index. Can be one of these values:

DCB_q_fi_fo

First in, first out.

DCB_q_sort

Special algorithm for disk.


See also DCB_COMMON, DCB_BLOCKDEV