doc: add runtime option examples to hns3 guide
[dpdk.git] / doc / guides / nics / hns3.rst
1 ..  SPDX-License-Identifier: BSD-3-Clause
2     Copyright(c) 2018-2019 HiSilicon Limited.
3
4 HNS3 Poll Mode Driver
5 ===============================
6
7 The hns3 PMD (**librte_net_hns3**) provides poll mode driver support
8 for the inbuilt HiSilicon Network Subsystem(HNS) network engine
9 found in the HiSilicon Kunpeng 920 SoC and Kunpeng 930 SoC .
10
11 Features
12 --------
13
14 Features of the HNS3 PMD are:
15
16 - Multiple queues for TX and RX
17 - Receive Side Scaling (RSS)
18 - Packet type information
19 - Checksum offload
20 - TSO offload
21 - LRO offload
22 - Promiscuous mode
23 - Multicast mode
24 - Port hardware statistics
25 - Jumbo frames
26 - Link state information
27 - Interrupt mode for RX
28 - VLAN stripping and inserting
29 - QinQ inserting
30 - DCB
31 - Scattered and gather for TX and RX
32 - Vector Poll mode driver
33 - Dump register
34 - SR-IOV VF
35 - Multi-process
36 - MAC/VLAN filter
37 - MTU update
38 - NUMA support
39 - Generic flow API
40 - IEEE1588/802.1AS timestamping
41
42 Prerequisites
43 -------------
44 - Get the information about Kunpeng920 chip using
45   `<https://www.hisilicon.com/en/products/Kunpeng>`_.
46
47 - Follow the DPDK :ref:`Getting Started Guide for Linux <linux_gsg>` to setup the basic DPDK environment.
48
49
50 Runtime Config Options
51 ----------------------
52
53 - ``rx_func_hint`` (default ``none``)
54
55   Used to select Rx burst function, supported value are ``vec``, ``sve``,
56   ``simple``, ``common``.
57   ``vec``, if supported use the ``vec`` Rx function which indicates the
58   default vector algorithm, neon for Kunpeng Arm platform.
59   ``sve``, if supported use the ``sve`` Rx function which indicates the
60   sve algorithm.
61   ``simple``, if supported use the ``simple`` Rx function which indicates
62   the scalar simple algorithm.
63   ``common``, if supported use the ``common`` Rx function which indicates
64   the scalar scattered algorithm.
65
66   When provided parameter is not supported, ``vec`` usage condition will
67   be first checked, if meets, use the ``vec``. Then, ``simple``, at last
68   ``common``.
69
70   For example::
71   -a 0000:7d:00.0,rx_func_hint=simple
72
73 - ``tx_func_hint`` (default ``none``)
74
75   Used to select Tx burst function, supported value are ``vec``, ``sve``,
76   ``simple``, ``common``.
77   ``vec``, if supported use the ``vec`` Tx function which indicates the
78   default vector algorithm, neon for Kunpeng Arm platform.
79   ``sve``, if supported use the ``sve`` Tx function which indicates the
80   sve algorithm.
81   ``simple``, if supported use the ``simple`` Tx function which indicates
82   the scalar simple algorithm.
83   ``common``, if supported use the ``common`` Tx function which indicates
84   the scalar algorithm.
85
86   When provided parameter is not supported, ``vec`` usage condition will
87   be first checked, if meets, use the ``vec``. Then, ``simple``, at last
88   ``common``.
89
90   For example::
91   -a 0000:7d:00.0,tx_func_hint=common
92
93 - ``dev_caps_mask`` (default ``0``)
94
95   Used to mask the capability which queried from firmware.
96   This args take hexadecimal bitmask where each bit represents whether mask
97   corresponding capability. eg. If the capability is 0xFFFF queried from
98   firmware, and the args value is 0xF which means the bit0~bit3 should be
99   masked off, then the capability will be 0xFFF0.
100   Its main purpose is to debug and avoid problems.
101
102   For example::
103   -a 0000:7d:00.0,dev_caps_mask=0xF
104
105 Driver compilation and testing
106 ------------------------------
107
108 Refer to the document :ref:`compiling and testing a PMD for a NIC <pmd_build_and_test>`
109 for details.
110
111 Limitations or Known issues
112 ---------------------------
113 Currently, we only support VF device is bound to vfio_pci or
114 igb_uio and then driven by DPDK driver when PF is driven by
115 kernel mode hns3 ethdev driver, VF is not supported when PF
116 is driven by DPDK driver.
117
118 Build with ICC is not supported yet.
119 X86-32, Power8, ARMv7 and BSD are not supported yet.