xref: /dpdk/doc/guides/dmadevs/dpaa2.rst (revision 388e888dc082520f3dbe6318ae32fbf99695cf4c)
1..  SPDX-License-Identifier: BSD-3-Clause
2    Copyright 2018-2022 NXP
3
4NXP DPAA2 QDMA Driver
5=====================
6
7The DPAA2 QDMA is an implementation of the dmadev API, that provide means
8to initiate a DMA transaction from CPU. The initiated DMA is performed
9without CPU being involved in the actual DMA transaction. This is achieved
10via using the DPDMAI device exposed by MC.
11
12More information can be found at `NXP Official Website
13<http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/qoriq-arm-processors:QORIQ-ARM>`_.
14
15Features
16--------
17
18The DPAA2 QDMA implements following features in the dmadev API;
19
20- Supports issuing DMA of data within memory without hogging CPU while
21  performing DMA operation.
22- Supports configuring to optionally get status of the DMA translation on
23  per DMA operation basis.
24- Supports statistics.
25
26Supported DPAA2 SoCs
27--------------------
28
29- LX2160A
30- LS2084A/LS2044A
31- LS2088A/LS2048A
32- LS1088A/LS1048A
33
34Prerequisites
35-------------
36
37See :doc:`../platform/dpaa2` for setup information
38
39- Follow the DPDK :ref:`Getting Started Guide for Linux <linux_gsg>` to setup the basic DPDK environment.
40
41.. note::
42
43   Some part of fslmc bus code (mc flib - object library) routines are
44   dual licensed (BSD & GPLv2).
45
46
47Enabling logs
48-------------
49
50For enabling logs, use the following EAL parameter:
51
52.. code-block:: console
53
54   ./your_qdma_application <EAL args> --log-level=pmd.dma.dpaa2.qdma,<level>
55
56Using ``pmd.dma.dpaa2.qdma`` as log matching criteria, all Event PMD logs can be
57enabled which are lower than logging ``level``.
58
59
60Initialization
61--------------
62
63The DPAA2 QDMA is exposed as a dma device which consists of dpdmai devices.
64On EAL initialization, dpdmai devices will be probed and populated into the
65dmadevices. The dmadev ID of the device can be obtained using
66
67* Invoking ``rte_dma_get_dev_id_by_name("dpdmai.x")`` from the application
68  where x is the object ID of the DPDMAI object created by MC. Use can
69  use this index for further rawdev function calls.
70
71Platform Requirement
72~~~~~~~~~~~~~~~~~~~~
73
74DPAA2 drivers for DPDK can only work on NXP SoCs as listed in the
75``Supported DPAA2 SoCs``.
76
77Device Arguments
78----------------
79
80``fle_pre_populate=1``
81  Pre-populate all DMA descriptors with pre-initialized values.
82  Usage example: ``fslmc:dpdmai.1,fle_pre_populate=1``
83
84``desc_debug=1``
85  Enable descriptor debugs.
86  Usage example: ``fslmc:dpdmai.1,desc_debug=1``
87
88``short_fd=1``
89  Enable short FDs.
90  Usage example: ``fslmc:dpdmai.1,short_fd=1``
91