Rtnl2ReturnPhysicalTxQueueBuffers

Rtnl2ReturnPhysicalTxQueueBuffers returns one or more NL2 Buffers that were received for the specified physical transmit queue.

Syntax

Copy
BOOL Rtnl2ReturnPhysicalTxQueueBuffers(
  [in]    RTNL2_HPHYSICAL_TX_QUEUE PhysicalTxQueue,
  [in]    RTNL2_BUFFER_HEADER *pBufferHeader
);

Parameters

[in] PhysicalTxQueue

A handle to the physical transmit queue represented by data type RTNL2_HPHYSICAL_TX_QUEUE.

[in] pBufferHeader

The address of the buffer header of the first buffer to return.

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_NOT_READY

The calling process has not called Rtnl2Init.

ERROR_INVALID_PARAMETER

One of the following conditions occurred:

  • The supplied physical transmit queue handle is invalid.
  • The supplied linked list is invalid, which can be due to one of the following conditions:
  • pBufferHeader is NULL.
  • One of the buffer headers in the linked list does not point to a buffer header that was returned by Rtnl2GetPhysicalTxQueueBuffers for this physical transmit queue.

RTNL2_ERROR_PHYSICAL_TX_QUEUE_BUFFER_NOT_OWNED

One of the buffers in the list is currently owned by the NL2, which means that it has been used in a call to Rtnl2SubmitToPhysicalTxQueue but has not been extracted yet by Rtnl2ExtractFromPhysicalTxQueue.

RTNL2_ERROR_PHYSICAL_TX_QUEUE_IS_RELEASING

Another thread of the calling process is executing Rtnl2ReleasePhysicalTxQueue at the same time.

RTNL2_ERROR_PHYSICAL_TX_QUEUE_NOT_READY

The Physical Transmit Queue is not ready yet.

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_SERIALIZED_COMMAND_TIMEOUT

The NL2 process didn’t reply within an acceptable amount of time.

Remarks

The application can request to release multiple buffers by linking all the buffer headers together and giving the address of the first buffer header to this function.

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: