Specifications
alt_dma_rxchan_prepare()
Prototype
int alt_dma_rxchan_prepare (alt_dma_rxchan dma,
void* data,
alt_u32 length,
alt_rxchan_done* done,
void* handle)
Commonly Called By
C/C++ programs
Device drivers
Thread-safe
See description.
Available from ISR
See description.
Include
<sys/alt_dma.h>
Description
The alt_dma_rxchan_prepare() posts a receive request to a DMA receive channel. The input arguments
are: dma, the channel to use; data, a pointer to the location that data is to be received to; length, the
maximum length of the data to receive in bytes; done, callback function that is called after the data is
received; handle, an opaque value passed to done.
Whether this function is thread-safe, or can be called from an ISR, depends on the underlying device
driver. In general it safest to assume that it is not thread-safe.
Return
The return value is zero upon success. A negative return value indicates that the request cannot be posted.
Related Information
• alt_dma_rxchan_close() on page 14-13
• alt_dma_rxchan_depth() on page 14-12
• alt_dma_rxchan_open() on page 14-15
• alt_dma_rxchan_reg() on page 14-17
• alt_dma_txchan_close() on page 14-18
• alt_dma_txchan_ioctl() on page 14-19
• alt_dma_txchan_open() on page 14-20
• alt_dma_txchan_reg() on page 14-21
• alt_dma_txchan_send() on page 14-27
• alt_dma_txchan_space() on page 14-26
14-16
alt_dma_rxchan_prepare()
NII5V2
2015.05.14
Altera Corporation
HAL API Reference
Send Feedback