Dxx_reclaim
2-78
Important Note:
This API will no longer be supported in the next major
release of DSP/BIOS. We recommend that you use the IOM driver
interface instead. See the
DSP/BIOS Driver Developer’s Guide
(SPRU616). This API is still supported in DSP/BIOS 5.32 and will be
supported in any patch releases or minor enhancements to DSP/BIOS
5.32.
C Interface
Syntax
status = Dxx_reclaim(device);
Parameters
DEV_Handle device;
/* device handle */
Return Value
Int
status;
/* result of operation */
Description
Dxx_reclaim is used to request a buffer back from a device. Dxx_reclaim
does not return until a buffer is available for the client in the
device->fromdevice queue. If the device was opened in DEV_INPUT
mode then Dxx_reclaim blocks until an input frame has been filled with
the number of MADUs requested, then processes the data in the frame
and place it on the device->fromdevice queue. If the device was opened
in DEV_OUTPUT mode, Dxx_reclaim blocks until an output frame has
been emptied, then place the frame on the device->fromdevice queue. In
either mode, Dxx_reclaim blocks until it has a frame to place on the
device->fromdevice queue, or until the stream’s timeout expires, and it
returns an error code indicating success (SYS_OK) or failure.
If device->timeout is not equal to SYS_FOREVER or 0, the task
suspension time can be up to 1 system clock tick less than timeout due
to granularity in system timekeeping.
If device->timeout is SYS_FOREVER, the task remains suspended until
a frame is available on the device’s fromdevice queue. If timeout is 0,
Dxx_reclaim returns immediately.
If timeout expires before a buffer is available on the device’s fromdevice
queue, Dxx_reclaim returns SYS_ETIMEOUT. Otherwise Dxx_reclaim
returns SYS_OK for success, or an error code.
If Dxx_reclaim fails due to a time out or any other reason, it does not
place a frame on the device->fromdevice queue.
Dxx_reclaim
Retrieve a buffer from a device