New upstream version 18.11-rc4
[deb_dpdk.git] / doc / guides / rawdevs / dpaa2_cmdif.rst
1 ..  SPDX-License-Identifier: BSD-3-Clause
2     Copyright 2018 NXP
3
4 NXP DPAA2 CMDIF Driver
5 ======================
6
7 The DPAA2 CMDIF is an implementation of the rawdev API, that provides
8 communication between the GPP and AIOP (Firmware). This is achieved
9 via using the DPCI devices exposed by MC for GPP <--> AIOP interaction.
10
11 More information can be found at `NXP Official Website
12 <http://www.nxp.com/products/microcontrollers-and-processors/arm-processors/qoriq-arm-processors:QORIQ-ARM>`_.
13
14 Features
15 --------
16
17 The DPAA2 CMDIF implements following features in the rawdev API;
18
19 - Getting the object ID of the device (DPCI) using attributes
20 - I/O to and from the AIOP device using DPCI
21
22 Supported DPAA2 SoCs
23 --------------------
24
25 - LS2084A/LS2044A
26 - LS2088A/LS2048A
27 - LS1088A/LS1048A
28
29 Prerequisites
30 -------------
31
32 See :doc:`../platform/dpaa2` for setup information
33
34 Currently supported by DPDK:
35
36 - NXP SDK **18.09+**.
37 - MC Firmware version **10.10.0** and higher.
38 - Supported architectures:  **arm64 LE**.
39
40 - Follow the DPDK :ref:`Getting Started Guide for Linux <linux_gsg>` to setup the basic DPDK environment.
41
42 .. note::
43
44    Some part of fslmc bus code (mc flib - object library) routines are
45    dual licensed (BSD & GPLv2).
46
47 Pre-Installation Configuration
48 ------------------------------
49
50 Config File Options
51 ~~~~~~~~~~~~~~~~~~~
52
53 The following options can be modified in the ``config`` file.
54
55 - ``CONFIG_RTE_LIBRTE_PMD_DPAA2_CMDIF_RAWDEV`` (default ``y``)
56
57   Toggle compilation of the ``lrte_pmd_dpaa2_cmdif`` driver.
58
59 Enabling logs
60 -------------
61
62 For enabling logs, use the following EAL parameter:
63
64 .. code-block:: console
65
66    ./your_cmdif_application <EAL args> --log-level=pmd.raw.dpaa2.cmdif,<level>
67
68 Using ``pmd.raw.dpaa2.cmdif`` as log matching criteria, all Event PMD logs can be
69 enabled which are lower than logging ``level``.
70
71 Driver Compilation
72 ~~~~~~~~~~~~~~~~~~
73
74 To compile the DPAA2 CMDIF PMD for Linux arm64 gcc target, run the
75 following ``make`` command:
76
77 .. code-block:: console
78
79    cd <DPDK-source-directory>
80    make config T=arm64-dpaa2-linuxapp-gcc install
81
82 Initialization
83 --------------
84
85 The DPAA2 CMDIF is exposed as a vdev device which consists of dpci devices.
86 On EAL initialization, dpci devices will be probed and then vdev device
87 can be created from the application code by
88
89 * Invoking ``rte_vdev_init("dpaa2_dpci")`` from the application
90
91 * Using ``--vdev="dpaa2_dpci"`` in the EAL options, which will call
92   rte_vdev_init() internally
93
94 Example:
95
96 .. code-block:: console
97
98     ./your_cmdif_application <EAL args> --vdev="dpaa2_dpci"
99
100 Platform Requirement
101 ~~~~~~~~~~~~~~~~~~~~
102
103 DPAA2 drivers for DPDK can only work on NXP SoCs as listed in the
104 ``Supported DPAA2 SoCs``.