共用方式為


NDIS_SET_PACKET_TIME_RECEIVED (Compact 2013)

3/26/2014

This macro sets the _TimeReceived value in the out-of-band data block associated with a specified packet descriptor.

Syntax

ULONGLONG NDIS_SET_PACKET_TIME_RECEIVED(
  PNDIS_PACKET _Packet,
  ULONGLONG _TimeReceived
);

Parameters

  • _Packet
    Pointer to a packet descriptor that is allocated by the caller for receive indications
  • _TimeReceived
    Specifies the system time at which the packet was received from the remote node on the network

Return Value

The return value is _TimeReceived value.

Remarks

Drivers use this macro to set this time stamp in the out-of-band data block associated with a packet descriptor before they call the NdisMIndicateReceivePacket function. Miniports that indicate multipacket receives can set the _TimeReceived parameter for each packet in an indicated array to the same value before they make an indication, especially if the network adapter has no internal clock. Therefore, that the network adapter driver calls the NdisGetCurrentSystemTime66688098-7ad2-4c3b-a3b6-34ecbecc2ce7 function.

All time stamps set in the NDIS_PACKET_OOB_DATA structures associated with packet descriptors are expressed in system time units as the number of 100-nanosecond intervals since January 1, 1601. A driver calls NdisGetCurrentSystemTime to supply the _TimeReceived parameter to NDIS_SET_PACKET_TIME_RECEIVED.

The NDIS_SET_PACKET_TIME_RECEIVED macro is defined as follows.

#define NDIS_SET_PACKET_TIME_RECEIVED(_Packet, _TimeReceived)   \
    ((PNDIS_PACKET_OOB_DATA)((PUCHAR)(_Packet) +                \
    (_Packet)->Private.NdisPacketOobOffset))->TimeReceived = (_TimeReceived)

Requirements

Header

ndis.h

See Also

Reference

NDIS 5.x Legacy Network Driver Macros
NdisGetCurrentSystemTime
NdisMIndicateReceivePacket
NdisMSendComplete
NdisSend
ProtocolReceive
ProtocolReceiveComplete
NDIS 5.x Legacy Reference