Rtnl2GetLogicalTxQueueTimestamp
Rtnl2GetLogicalTxQueueTimestamp gets the value of the last Egress Timestamp for the Logical Transmit Queue.
Syntax
BOOL Rtnl2GetLogicalTxQueueTimestamp(
[in] RTNL2_HLOGICAL_TX_QUEUE LogicalTxQueue,
[out] RTNL2_TIMESTAMP *pTimestamp
);
Parameters
[in] LogicalTxQueue
A handle to the Logical Transmit Queue returned by the Rtnl2CreateLogicalTxQueue function.
[out] pTimestamp
The value of the Egress Timestamp
Return Value
If the function succeeds, it returns TRUE. If the function fails, it returns FALSE. Call GetLastError to obtain an error code.
Possible error codes:
| Error code | Meaning |
|---|---|
|
ERROR_DEVICE_FEATURE_NOT_SUPPORTED |
Hardware timestamping is not supported by the hardware. |
|
ERROR_INVALID_DATA |
No new info available since the last call to this function. |
|
ERROR_INVALID_PARAMETER |
One of the following conditions occurred:
|
|
ERROR_IO_DEVICE |
The last requested timestamping operation was aborted due to a hardware issue. |
|
ERROR_NOT_READY |
The calling process has not called Rtnl2Init. |
|
RTNL2_ERROR_NO_MORE_COMMUNICATION |
Unable to communicate with the NL2 process. This might be because the NL2 process is not running anymore, or because an application process thread was terminated during a previous call to an NL2 API function. |
|
RTNL2_ERROR_LOGICAL_TX_QUEUE_IS_DESTROYING |
Another thread of the calling process is executing Rtnl2DestroyLogicalTxQueue at the same time. |
|
RTNL2_ERROR_TIMESTAMPING_NOT_CONFIGURED |
Timestamping has not been enabled globally for the NIC or specifically for the Physical Transmit Queue on which this Logical Transmit Queue sits. |
Remarks
This function should be called by the application every time the Egress Timestamp event gets signaled by the NL2. There are two reasons why the NL2 may signal the Egress Timestamp event:
- A frame has been successfully transmitted and timestamped. In this case, the call to this function will succeed and return a valid Egress Timestamp.
- The last to-be-timestamped frame was not timestamped due to a hardware issue, such as the link being down. The NL2 has aborted the operation. In this case, a call to this function will fail and return error code ERROR_IO_DEVICE.
In any case, calls to this function will result in the following:
- The Egress Timestamp will be invalidated. Consecutive calls to this function will return ERROR_INVALID_DATA.
- The Logical Transmit Queue becomes ready to transmit another to-be-timestamped frame.
Characteristics
| Real-time | ||
|
Deterministic |
No |
|
| Local memory usage | ||
|
Process |
External MSpace usage |
Internal MSpace usage |
|
System |
No |
No |
|
NL2 process |
No |
No |
|
Calling process |
No |
No |
| Contiguous memory usage | ||
|
Usage |
No |
|
Requirements
| Minimum supported version | Header | Library |
|---|---|---|
|
eRTOS 1.0 SDK |
Rtnl2Api.h |
Rtnl2Api.lib |
See Also: