NetRingGetElementAtIndex function (ring.h)

The NetRingGetElementAtIndex function retrieves an element from a net ring.

Syntax

void * NetRingGetElementAtIndex(
  [_In_] NET_RING const *Ring,
  [_In_] UINT32         Index
);

Parameters

[_In_] Ring

A pointer to a NET_RING.

[_In_] Index

The element index, within the range [0, Ring->NumberOfElements).

Return value

Returns the element at the specified location.

Remarks

NetRingGetElementAtIndex uses the ElementStride member of the net ring to index into the buffer and returns the location of the specified element.

NetRingGetElementAtIndex is meant for generic use of net rings. Instead, a NetAdapterCx client driver typically calls either NetRingGetPacketAtIndex for a packet ring or NetRingGetFragmentAtIndex for a fragment ring.

Requirements

Requirement Value
Target Platform Universal
Minimum KMDF version 1.29
Minimum UMDF version 2.33
Header ring.h (include netadaptercx.h)
IRQL Any level as long as target memory is resident

See also

NetRingGetPacketAtIndex

NetRingGetFragmentAtIndex