dma/dpaa2: support statistics
[dpdk.git] / doc / guides / dmadevs / dpaa2.rst
1 ..  SPDX-License-Identifier: BSD-3-Clause
2     Copyright 2018-2022 NXP
3
4 NXP DPAA2 QDMA Driver
5 =====================
6
7 The DPAA2 QDMA is an implementation of the dmadev API, that provide means
8 to initiate a DMA transaction from CPU. The initiated DMA is performed
9 without CPU being involved in the actual DMA transaction. This is achieved
10 via using the DPDMAI device exposed by MC.
11
12 More 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
15 Features
16 --------
17
18 The 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
26 Supported DPAA2 SoCs
27 --------------------
28
29 - LX2160A
30 - LS2084A/LS2044A
31 - LS2088A/LS2048A
32 - LS1088A/LS1048A
33
34 Prerequisites
35 -------------
36
37 See :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
47 Enabling logs
48 -------------
49
50 For 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
56 Using ``pmd.dma.dpaa2.qdma`` as log matching criteria, all Event PMD logs can be
57 enabled which are lower than logging ``level``.
58
59
60 Initialization
61 --------------
62
63 The DPAA2 QDMA is exposed as a dma device which consists of dpdmai devices.
64 On EAL initialization, dpdmai devices will be probed and populated into the
65 dmadevices. 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
71 Platform Requirement
72 ~~~~~~~~~~~~~~~~~~~~
73
74 DPAA2 drivers for DPDK can only work on NXP SoCs as listed in the
75 ``Supported DPAA2 SoCs``.