doc: update links in nfb guide
[dpdk.git] / doc / guides / bbdevs / la12xx.rst
1 ..  SPDX-License-Identifier: BSD-3-Clause
2     Copyright 2021 NXP
3
4 NXP LA12xx Poll Mode Driver
5 ===========================
6
7 The BBDEV LA12xx poll mode driver (PMD) supports an implementation for
8 offloading High Phy processing functions like LDPC Encode / Decode 5GNR wireless
9 acceleration function, using PCI based LA12xx Software defined radio.
10
11 More information can be found at `NXP Official Website
12 <https://www.nxp.com/products/processors-and-microcontrollers/arm-processors/layerscape-processors/layerscape-access-la1200-programmable-baseband-processor:LA1200>`_.
13
14 Features
15 --------
16
17 LA12xx PMD supports the following features:
18
19 - Maximum of 8 LDPC decode (UL) queues
20 - Maximum of 8 LDPC encode (DL) queues
21 - PCIe Gen-3 x8 Interface
22
23 Installation
24 ------------
25
26 Section 3 of the DPDK manual provides instructions on installing and compiling DPDK.
27
28 DPDK requires hugepages to be configured as detailed in section 2 of the DPDK manual.
29
30 Initialization
31 --------------
32
33 The device can be listed on the host console with:
34
35
36 Use the following lspci command to get the multiple LA12xx processor ids. The
37 device ID of the LA12xx baseband processor is "1c30".
38
39 .. code-block:: console
40
41   sudo lspci -nn
42
43 ...
44 0001:01:00.0 Power PC [0b20]: Freescale Semiconductor Inc Device [1957:1c30] (
45 rev 10)
46 ...
47 0002:01:00.0 Power PC [0b20]: Freescale Semiconductor Inc Device [1957:1c30] (
48 rev 10)
49
50
51 Prerequisites
52 -------------
53
54 Currently supported by DPDK:
55
56 - NXP LA1224 BSP **1.0+**.
57 - NXP LA1224 PCIe Modem card connected to ARM host.
58
59 - Follow the DPDK :ref:`Getting Started Guide for Linux <linux_gsg>` to setup the basic DPDK environment.
60
61 * Use dev arg option ``modem=0`` to identify the modem instance for a given
62   device. This is required only if more than 1 modem cards are attached to host.
63   this is optional and the default value is 0.
64   e.g. ``--vdev=baseband_la12xx,modem=0``
65
66 * Use dev arg option ``max_nb_queues=x`` to specify the maximum number of queues
67   to be used for communication with offload device i.e. modem. default is 16.
68   e.g. ``--vdev=baseband_la12xx,max_nb_queues=4``
69
70 Enabling logs
71 -------------
72
73 For enabling logs, use the following EAL parameter:
74
75 .. code-block:: console
76
77    ./your_bbdev_application <EAL args> --log-level=la12xx:<level>
78
79 Using ``bb.la12xx`` as log matching criteria, all Baseband PMD logs can be
80 enabled which are lower than logging ``level``.
81
82 Test Application
83 ----------------
84
85 BBDEV provides a test application, ``test-bbdev.py`` and range of test data for testing
86 the functionality of LA12xx for FEC encode and decode, depending on the device
87 capabilities. The test application is located under app->test-bbdev folder and has the
88 following options:
89
90 .. code-block:: console
91
92   "-p", "--testapp-path": specifies path to the bbdev test app.
93   "-e", "--eal-params"  : EAL arguments which are passed to the test app.
94   "-t", "--timeout"     : Timeout in seconds (default=300).
95   "-c", "--test-cases"  : Defines test cases to run. Run all if not specified.
96   "-v", "--test-vector" : Test vector path (default=dpdk_path+/app/test-bbdev/test_vectors/bbdev_null.data).
97   "-n", "--num-ops"     : Number of operations to process on device (default=32).
98   "-b", "--burst-size"  : Operations enqueue/dequeue burst size (default=32).
99   "-s", "--snr"         : SNR in dB used when generating LLRs for bler tests.
100   "-s", "--iter_max"    : Number of iterations for LDPC decoder.
101   "-l", "--num-lcores"  : Number of lcores to run (default=16).
102   "-i", "--init-device" : Initialise PF device with default values.
103
104
105 To execute the test application tool using simple decode or encode data,
106 type one of the following:
107
108 .. code-block:: console
109
110   ./test-bbdev.py -e="--vdev=baseband_la12xx,socket_id=0,max_nb_queues=8" -c validation -n 64 -b 1 -v ./ldpc_dec_default.data
111   ./test-bbdev.py -e="--vdev=baseband_la12xx,socket_id=0,max_nb_queues=8" -c validation -n 64 -b 1 -v ./ldpc_enc_default.data
112
113 The test application ``test-bbdev.py``, supports the ability to configure the PF device with
114 a default set of values, if the "-i" or "- -init-device" option is included. The default values
115 are defined in test_bbdev_perf.c.
116
117
118 Test Vectors
119 ~~~~~~~~~~~~
120
121 In addition to the simple LDPC decoder and LDPC encoder tests, bbdev also provides
122 a range of additional tests under the test_vectors folder, which may be useful. The results
123 of these tests will depend on the LA12xx FEC capabilities which may cause some
124 testcases to be skipped, but no failure should be reported.