Xilinx KCU105 User Manual page 96

Pci express streaming data plane trd
Hide thumbs Also See for KCU105:
Table of Contents

Advertisement

Table D-1: APIs Provided by the XDMA Driver (Cont'd)
API Prototype
int
xlnx_get_dma_channel(
ps_pcie_dma_desc_t
*ptr_dma_desc, u32
channel_id, direction_t
dir,
ps_pcie_dma_chann_desc
_t **pptr_chann_desc,
func_ptr_chann_health_c
bk_no_block
ptr_chann_health);
int
xlnx_rel_dma_channel (
ps_pcie_dma_chann_desc
_t *ptr_chann_desc);
PCIe Streaming Data Plane TRD
UG920 (v2017.1) June 01, 2017
Appendix D:
Details
API is used to get a
pointer to a DMA channel
descriptor. XDMA has four
DMA channels.
This API is typically called
during initialization by the
application driver to
acquire a DMA channel,
whereby I/Os can be
performed. After the
channel is acquired, same
cannot be acquired until it
is relinquished.
An API is used to
relinquish an acquired
DMA channel.
www.xilinx.com
APIs Provided by the XDMA Driver in Linux
Parameters
ptr_dma_desc – XDMA
descriptor pointer
acquired from a call to
xlnx_get_pform_dma_desc
.
channel_id – Channel
number
dir – IN/OUT. Specifies the
direction of data
movement for channel. On
the host system OUT is
specified if a channel is
used to move data to the
Endpoint. On an Endpoint,
IN is specified if the
channel is used to move
data from the host to
Endpoint.
pptr_chann_desc –
Pointer to a placeholder to
store the pointer to the
XDMA channel software
descriptor populated by
an API. The Returned
channel descriptor pointer
is used by other APIs.
ptr_chann_health –
Callback that notifies the
application driver about
changes in the state of the
XDMA channel or the
DMA at large. The
application driver might
choose to keep this NULL.
The application driver
should check the channel
state to get more
information.
ptr_chann_desc –
Channel descriptor
pointer to be released. The
pointer should have been
acquired by an earlier call
to xlnx_get_dma_channel.
Return
Returns XLNX_SUCCESS
on success. On failure, a
negative value is returned.
Check "/* Xilinx DMA
driver status messages */"
in
ps_pcie_dma_driver.
h for more information on
error codes.
Returns XLNX_SUCCESS
on success. On failure, a
negative value is returned.
Check "/* Xilinx DMA
driver status messages */"
in
ps_pcie_dma_driver.
h for more information on
error codes.
96
Send Feedback

Advertisement

Table of Contents
loading

Table of Contents