Export (0) Print
Expand All

NDIS_GET_PACKET_TIME_RECEIVED (Windows Embedded CE 6.0)

1/6/2010

This function returns the TimeReceived value from the out-of-band (OOB) data block associated with a given packet descriptor.


ULONGLONG NDIS_GET_PACKET_TIME_RECEIVED(
  PNDIS_PACKET _Packet
);

_Packet

Points to a packet descriptor.

NDIS_GET_PACKET_TIME_RECEIVED returns the timestamp, if any, set by the miniport when the net packet was received on the underlying network interface card (NIC).

When a protocol driver's ProtocolReceivePacket function is called with an indication, it can use this macro to retrieve the TimeReceived timestamp using the _Packet pointer it is given on entry.

A protocol driver can call NdisGetReceivedPacket and the NDIS_GET_ORIGINAL_PACKET macro to obtain this time stamp from the NDIS_PACKET_OOB_DATA structure associated with a packet descriptor when its ProtocolReceive function is given an indication. However, these calls are superfluous if the protocol is bound to an underlying driver that does not supply OOB information with its indications.

A highest-level protocol driver might use this macro before it forwards a received net packet to clients if its clients expect time stamps. Still higher-level drivers or system components can convert this time stamp into locale-specific values more meaningful to the end user.

The NDIS_GET_PACKET_TIME_RECEIVED macro is defined as follows.

#define NDIS_GET_PACKET_TIME_RECEIVED(_Packet)                          \
                        ((PNDIS_PACKET_OOB_DATA)((PUCHAR)(_Packet) +    \
                        (_Packet)->Private.NdisPacketOobOffset))->TimeReceived

Headerndis.h
Windows Embedded CEWindows CE .NET 4.0 and later

Community Additions

ADD
Show:
© 2014 Microsoft