doc: add octeontx mempool guide
[dpdk.git] / doc / guides / mempool / octeontx.rst
1 ..  BSD LICENSE
2     Copyright (C) Cavium, Inc. 2017. All rights reserved.
3
4     Redistribution and use in source and binary forms, with or without
5     modification, are permitted provided that the following conditions
6     are met:
7
8     * Redistributions of source code must retain the above copyright
9     notice, this list of conditions and the following disclaimer.
10     * Redistributions in binary form must reproduce the above copyright
11     notice, this list of conditions and the following disclaimer in
12     the documentation and/or other materials provided with the
13     distribution.
14     * Neither the name of Cavium, Inc nor the names of its
15     contributors may be used to endorse or promote products derived
16     from this software without specific prior written permission.
17
18     THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
19     "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
20     LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
21     A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
22     OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
23     SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
24     LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
25     DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
26     THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
27     (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
28     OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
29
30 OCTEONTX FPAVF Mempool Driver
31 =============================
32
33 The OCTEONTX FPAVF PMD (**librte_mempool_octeontx**) is a mempool
34 driver for offload mempool device found in **Cavium OCTEONTX** SoC
35 family.
36
37 More information can be found at `Cavium, Inc Official Website
38 <http://www.cavium.com/OCTEON-TX_ARM_Processors.html>`_.
39
40 Features
41 --------
42
43 Features of the OCTEONTX FPAVF PMD are:
44
45 - 32 SR-IOV Virtual functions
46 - 32 Pools
47 - HW mempool manager
48
49 Supported OCTEONTX SoCs
50 -----------------------
51
52 - CN83xx
53
54 Prerequisites
55 -------------
56
57 See :doc: `../platform/octeontx.rst` for setup information.
58
59 Pre-Installation Configuration
60 ------------------------------
61
62 Config File Options
63 ~~~~~~~~~~~~~~~~~~~
64
65 The following options can be modified in the ``config`` file.
66 Please note that enabling debugging options may affect system performance.
67
68 - ``CONFIG_RTE_MBUF_DEFAULT_MEMPOOL_OPS`` ( set to ``octeontx_fpavf``)
69
70   Set default mempool ops to octeontx_fpavf.
71
72 - ``CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL`` (default ``y``)
73
74   Toggle compilation of the ``librte_mempool_octeontx`` driver.
75
76 - ``CONFIG_RTE_LIBRTE_OCTEONTX_MEMPOOL_DEBUG`` (default ``n``)
77
78   Toggle display of generic debugging messages
79
80 Driver Compilation
81 ~~~~~~~~~~~~~~~~~~
82
83 To compile the OCTEONTX FPAVF MEMPOOL PMD for Linux arm64 gcc target, run the
84 following ``make`` command:
85
86 .. code-block:: console
87
88    cd <DPDK-source-directory>
89    make config T=arm64-thunderx-linuxapp-gcc test-build
90
91
92 Initialization
93 --------------
94
95 The octeontx fpavf mempool initialization similar to other mempool
96 drivers like ring. However user need to pass --base-virtaddr as
97 command line input to application example test_mempool.c application.
98
99 Example:
100
101 .. code-block:: console
102
103     ./build/app/test -c 0xf --base-virtaddr=0x100000000000 \
104                         --mbuf-pool-ops-name="octeontx_fpavf"