HW_INITIALIZATION_DATA structure (strmini.h)

The HW_INITIALIZATION_DATA structure specifies the basic information the class driver needs to begin initializing the minidriver. The minidriver passes an HW_INITIALIZATION_DATA structure to the class driver when it registers itself by calling StreamClassRegisterMinidriver.

Syntax

typedef struct _HW_INITIALIZATION_DATA {
  union {
    ULONG HwInitializationDataSize;
    struct {
      USHORT SizeOfThisPacket;
      USHORT StreamClassVersion;
    };
  };
  ULONG                       HwInitializationDataSize;
  PHW_INTERRUPT               HwInterrupt;
  PHW_RECEIVE_DEVICE_SRB      HwReceivePacket;
  PHW_CANCEL_SRB              HwCancelPacket;
  PHW_REQUEST_TIMEOUT_HANDLER HwRequestTimeoutHandler;
  ULONG                       DeviceExtensionSize;
  ULONG                       PerRequestExtensionSize;
  ULONG                       PerStreamExtensionSize;
  ULONG                       FilterInstanceExtensionSize;
  BOOLEAN                     BusMasterDMA;
  BOOLEAN                     Dma24BitAddresses;
  ULONG                       BufferAlignment;
  BOOLEAN                     TurnOffSynchronization;
  ULONG                       DmaBufferSize;
  ULONG                       NumNameExtensions;
  PWCHAR                      *NameExtensionArray;
  ULONG                       Reserved[2];
} HW_INITIALIZATION_DATA, *PHW_INITIALIZATION_DATA;

Members

HwInitializationDataSize

Specifies the size of this data structure, in bytes.

SizeOfThisPacket

StreamClassVersion

HwInterrupt

Points to the minidriver's StrMiniInterrupt routine.

HwReceivePacket

Points to the minidriver's StrMiniReceiveDevicePacket routine.

HwCancelPacket

Points to the minidriver's StrMiniCancelPacket routine.

HwRequestTimeoutHandler

Points to the minidriver's StrMiniRequestTimeout routine.

DeviceExtensionSize

Specifies the size in bytes of the buffer the class driver should allocate for the minidriver's device extension. The minidriver may use this buffer to record private information. The class driver passes pointers to this buffer in the HwDeviceExtension member of HW_STREAM_OBJECT, HW_STREAM_REQUEST_BLOCK, HW_TIME_CONTEXT, and PORT_CONFIGURATION_INFORMATION structures it passes to the minidriver.

PerRequestExtensionSize

Specifies the size in bytes of the buffer the class driver should allocate for the buffer pointed to by SRBExtension member of HW_STREAM_REQUEST_BLOCK structures it passes to the minidriver. The class driver will allocate one buffer for each HW_STREAM_REQUEST_BLOCK.

PerStreamExtensionSize

Specifies the size in bytes of the buffer the class driver should allocate for the buffer pointed to by the HwStreamExtension member of a stream's HW_STREAM_OBJECT. The class driver will allocate one buffer for each stream.

FilterInstanceExtensionSize

Specifies the size in bytes of the buffer the class extension should allocate for the buffer pointed to by the HwInstanceExtension member of HW_STREAM_REQUEST_BLOCK structures it passes to the minidriver. The class driver allocates one buffer for each instance of the minidriver.

BusMasterDMA

If TRUE, the device can perform direct bus-master DMA to the minidriver's DMA buffer.

Dma24BitAddresses

Minidrivers should set this to TRUE if the DMA hardware the devices uses can access only the lower 24 bits of the address space.

BufferAlignment

Specifies the alignment requirement, in bytes, for DMA buffers. For example, a value of 4 indicates the DMA buffers should be aligned on 4-byte boundaries.

TurnOffSynchronization

If TRUE, the minidriver will handle its own synchronization; otherwise the class driver handles synchronization. Most minidrivers should set this value to FALSE. See Minidriver Synchronization in the Streaming Minidriver Design Guide for more information.

DmaBufferSize

Specifies the size in bytes of the DMA buffer the class driver should allocate for the minidriver. The minidriver gets a pointer to this buffer by calling StreamClassGetDmaBuffer. The class driver allocates contiguous nonpageable memory that will not be available to the operating system, or to other drivers, so this value should be as small as possible.

NumNameExtensions

NameExtensionArray

Reserved[2]

Reserved for system use. Minidrivers should ignore this member.

Requirements

Requirement Value
Header strmini.h (include Strmini.h)