HW_STREAM_OBJECT structure (strmini.h)

HW_STREAM_OBJECT describes an instance of a minidriver stream.

Syntax

typedef struct _HW_STREAM_OBJECT {
  ULONG                          SizeOfThisPacket;
  ULONG                          StreamNumber;
  PVOID                          HwStreamExtension;
  PHW_RECEIVE_STREAM_DATA_SRB    ReceiveDataPacket;
  PHW_RECEIVE_STREAM_CONTROL_SRB ReceiveControlPacket;
  HW_CLOCK_OBJECT                HwClockObject;
  BOOLEAN                        Dma;
  BOOLEAN                        Pio;
  PVOID                          HwDeviceExtension;
  ULONG                          StreamHeaderMediaSpecific;
  ULONG                          StreamHeaderWorkspace;
  BOOLEAN                        Allocator;
  PHW_EVENT_ROUTINE              HwEventRoutine;
  ULONG                          Reserved[2];
} HW_STREAM_OBJECT, *PHW_STREAM_OBJECT;

Members

SizeOfThisPacket

Specifies the size, in bytes, of this structure.

StreamNumber

Specifies the offset of the stream within the minidriver's HW_STREAM_DESCRIPTOR structure.

HwStreamExtension

Points to the stream extension, a buffer allocated by the class driver for the minidriver to use to hold private information about this stream. The minidriver sets the size of the buffer in the HW_INITIALIZATION_DATA structure it passes when it registers itself with the stream class driver.

ReceiveDataPacket

Pointer to the stream's StrMiniReceiveStreamDataPacket routine.

ReceiveControlPacket

Pointer to the stream's StrMiniReceiveStreamControlPacket routine.

HwClockObject

Contains the stream's clock object. See HW_CLOCK_OBJECT for details.

Dma

If TRUE, the device uses DMA to transfer data for this stream.

Pio

If TRUE, the device uses programmed I/O to transfer data for this stream. Note that both the Pio and Dma members may be TRUE.

HwDeviceExtension

Pointer to the minidriver's device extension. The minidriver may use this buffer to record private information. The minidriver sets the size of this buffer in the HW_INITIALIZATION_DATA structure it passes when it registers itself via StreamClassRegisterMinidriver. The class driver also passes pointers to this buffer in the HwDeviceExtension member of the HW_STREAM_REQUEST_BLOCK, HW_TIME_CONTEXT, and PORT_CONFIGURATION_INFORMATION structures it passes to the minidriver.

StreamHeaderMediaSpecific

Specifies the size in bytes of the media-specific, per-stream header extension.

StreamHeaderWorkspace

Specifies the size of the per-stream-header workspace.

Allocator

Specifies TRUE if the driver uses allocators. Most minidrivers set this value to FALSE.

HwEventRoutine

Pointer to the stream's StrMiniEvent routine

Reserved[2]

Reserved for system use. Do not use.

Remarks

This structure is created by the class driver to hold information about a particular stream in the minidriver. For each stream-specific request, the class driver passes the HW_STREAM_OBJECT for the stream in the StreamObject member of the stream request block (See HW_STREAM_REQUEST_BLOCK).

When the class driver opens the stream and issues the SRB_OPEN_STREAM request to the minidriver's StrMiniReceiveDevicePacket routine, the minidriver initializes the stream object.

Requirements

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

See also

HW_CLOCK_OBJECT