Specifying Segments for DMA Buffers

The display miniport driver can specify aperture segments from which DMA buffers can be allocated. DMA buffers can also be allocated as contiguous locked-down system memory.

The video memory manager allocates and destroys DMA buffers when applications require them. Therefore, the video memory manager requires a set of segments from which it can allocate DMA buffers. Note that the segment set might consist of only one segment.

When the Microsoft DirectX graphics kernel subsystem calls the display miniport driver's DxgkDdiCreateDevice function to create a graphics context device, the display miniport driver can specify a segment set from which the video memory manager can allocate DMA buffers. If the display miniport driver sets the DmaBufferSegmentSet member of the DXGK_DEVICEINFO structure to 0, then the video memory manager will allocate contiguous nonpaged memory for DMA buffers; in this case, the display miniport driver must access the memory by using PCI cycles, and through DMA, must send data directly from the memory's physical address. If the display miniport driver sets DmaBufferSegmentSet to nonzero, then the video memory manager will allocate pageable memory and will map the pages to the specified aperture segments. The pages within the aperture segments are revealed to the display miniport driver in a call to its DxgkDdiSubmitCommand function.

Note that the basic video memory manager model does not support DMA buffers in local video memory.