WdfDmaEnablerGetMaximumScatterGatherElements function

[Applies to KMDF only]

The WdfDmaEnablerGetMaximumScatterGatherElements method returns the maximum number of scatter/gather elements that the device and driver support, for a specified DMA enabler object.

Syntax

size_t WdfDmaEnablerGetMaximumScatterGatherElements(
  WDFDMAENABLER DmaEnabler
);

Parameters

DmaEnabler

A handle to a DMA enabler object that the driver obtained from a previous call to WdfDmaEnablerCreate.

Return Value

If the driver previously called WdfDmaEnablerSetMaximumScatterGatherElements, WdfDmaEnablerGetMaximumScatterGatherElements returns the value that the driver specified in the previous call. Otherwise, WdfDmaEnablerGetMaximumScatterGatherElements returns WDF_DMA_ENABLER_UNLIMITED_FRAGMENTS, which indicates that there is no limit to the number of scatter/gather elements.

A bug check occurs if the driver supplies an invalid object handle.

Remarks

For more information about this method, see Enabling DMA Transactions.

Examples

The following code example obtains the maximum number of scatter/gather elements for a specified DMA enabler object.

size_t maxElements;

maxElements = WdfDmaEnablerGetMaximumScatterGatherElements(DmaEnabler);
 

Requirements

   
Target Platform Universal
Minimum KMDF version 1.0
Header wdfdmaenabler.h (include Wdf.h)
Library Wdf01000.sys (see Framework Library Versioning.)
IRQL "<=DISPATCH_LEVEL"
DDI compliance rules DriverCreate, KmdfIrql, KmdfIrql2

See Also

WdfDmaEnablerCreate

WdfDmaEnablerSetMaximumScatterGatherElements