[dpdk-dev] [PATCH v3 3/3] xen: Add documentation

Jan Blunck jblunck at infradead.org
Tue Mar 22 10:55:29 CET 2016


Add basic documentation for Xen Netfront PMD compilation and testpmd
invocation.

Signed-off-by: Jan Blunck <jblunck at infradead.org>
---
 doc/guides/nics/overview.rst |  28 ++++++------
 doc/guides/nics/xen.rst      | 101 +++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 115 insertions(+), 14 deletions(-)
 create mode 100644 doc/guides/nics/xen.rst

diff --git a/doc/guides/nics/overview.rst b/doc/guides/nics/overview.rst
index 2d4f014..de07390 100644
--- a/doc/guides/nics/overview.rst
+++ b/doc/guides/nics/overview.rst
@@ -74,18 +74,18 @@ Most of these differences are summarized below.
 
 .. table:: Features availability in networking drivers
 
-   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
-   Feature              a b b b c e e i i i i i i i i i i f f m m m n n p r s v v v x
-                        f n n o x 1 n 4 4 4 4 g g x x x x m m l l p f u c i z i i m e
-                        p x x n g 0 i 0 0 0 0 b b g g g g 1 1 x x i p l a n e r r x n
-                        a 2 2 d b 0 c e e e e   v b b b b 0 0 4 5 p   l p g d t t n v
-                        c x x i e 0     . v v   f e e e e k k     e         a i i e i
-                        k   v n         . f f       . v v   .               t o o t r
-                        e   f g         .   .       . f f   .               a   . 3 t
+   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+   Feature              a b b b c e e i i i i i i i i i i f f m m m n n p r s v v v x x
+                        f n n o x 1 n 4 4 4 4 g g x x x x m m l l p f u c i z i i m e e
+                        p x x n g 0 i 0 0 0 0 b b g g g g 1 1 x x i p l a n e r r x n n
+                        a 2 2 d b 0 c e e e e   v b b b b 0 0 4 5 p   l p g d t t n   v
+                        c x x i e 0     . v v   f e e e e k k     e         a i i e   i
+                        k   v n         . f f       . v v   .               t o o t   r
+                        e   f g         .   .       . f f   .               a   . 3   t
                         t               v   v       v   v   v               2   v
                                         e   e       e   e   e                   e
                                         c   c       c   c   c                   c
-   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
    link status                  X     X X                                   X
    link status event                  X X
    Rx interrupt                       X X X X
@@ -125,23 +125,23 @@ Most of these differences are summarized below.
    inner L4 checksum                  X   X
    packet type parsing          X     X   X
    timesync                           X X
-   basic stats                  X     X X X X                               X
+   basic stats                  X     X X X X                               X       X
    extended stats                     X X X X
    stats per queue              X                                           X
    EEPROM dump
    registers dump
    multiprocess aware                 X X X X
    BSD nic_uio                  X     X X X X
-   Linux UIO                    X     X X X X
+   Linux UIO                    X     X X X X                                       X
    Linux VFIO                   X     X X X X
    other kdrv                                                               X
    ARMv7
    ARMv8
    Power8
    TILE-Gx
-   x86-32                       X     X X X X
-   x86-64                       X     X X X X                               X
+   x86-32                       X     X X X X                                       X
+   x86-64                       X     X X X X                               X       X
    usage doc                    X                                           X
    design doc
    perf doc
-   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
+   ==================== = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = = =
diff --git a/doc/guides/nics/xen.rst b/doc/guides/nics/xen.rst
new file mode 100644
index 0000000..4e4531e
--- /dev/null
+++ b/doc/guides/nics/xen.rst
@@ -0,0 +1,101 @@
+..  BSD LICENSE
+    Copyright(c) 2016 Brocade Communications Systems, Inc.
+
+    All rights reserved.
+
+    Redistribution and use in source and binary forms, with or without
+    modification, are permitted provided that the following conditions
+    are met:
+
+    * Redistributions of source code must retain the above copyright
+    notice, this list of conditions and the following disclaimer.
+    * Redistributions in binary form must reproduce the above copyright
+    notice, this list of conditions and the following disclaimer in
+    the documentation and/or other materials provided with the
+    distribution.
+    * Neither the name of Brocade Communications Systems nor the names of
+    its contributors may be used to endorse or promote products derived
+    from this software without specific prior written permission.
+
+    THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
+    "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
+    LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
+    A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
+    OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
+    SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
+    LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
+    DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
+    THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+    (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
+    OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+XEN Netfront Poll Mode Driver
+=============================
+
+The XEN netfront poll mode driver connects to the XEN netback driver offering the same functionality as the
+Xen netfront driver in the Linux kernel.
+
+Supported Features
+------------------
+
+- Single TX/RX queue pair
+- Single MAC address
+
+Config File Options
+-------------------
+
+
+- ``CONFIG_RTE_LIBRTE_PMD_XEN`` (default **n**)
+
+  Toggle compilation of the ``librte_pmd_xen`` driver.
+
+
+Linux
+-----
+
+This section demonstrates how to load the Xen netfront PMD.
+
+#. Load ``xen_uio`` driver:
+
+   .. code-block:: console
+
+		   modprobe uio
+		   insmod ./x86_64-native-linuxapp-gcc/kmod/xen_uio.ko
+
+#. Bind the XEN network device vif-0 to ``xen_uio`` driver:
+
+   .. code-block:: console
+
+		   echo vif-0 > /sys/bus/xen/drivers/vif/unbind
+		   echo vif-0 > /sys/bus/xen/drivers/xen_uio/bind
+
+#. Start ``testpmd`` with basic parameters:
+
+   .. code-block:: console
+
+		   testpmd -c 0x3 -n 4  -- -i --txqflags=0x0e00 --mbuf-size=9000 --total-num-mbufs=2048
+
+   Example output:
+
+   .. code-block:: console
+
+		   ...
+		   EAL: Master lcore 0 is ready (tid=6e4128c0;cpuset=[0])
+		   PMD: vif-0 skipping device with driver vif
+		   PMD: vif-1 Creating xen-netfront PMD ethdev on socket 0
+		   PMD: vif-1 uio_num = 0
+		   PMD: /dev/uio0 mmap map0 (4096 at 0x0) to 0x7f366e419000
+		   PMD: /dev/uio0 mmap map1 (4096 at 0x0) to 0x7f366e418000
+		   PMD: /dev/uio0 mmap map2 (4096 at 0x0) to 0x7f366e411000
+		   EAL: lcore 1 is ready (tid=4c5ff700;cpuset=[1])
+		   Interactive-mode selected
+		   Configuring Port 0 (socket 0)
+		   rte_eth_dev_config_restore: port 0: MAC address array not supported
+		   rte_eth_promiscuous_disable: Function not supported
+		   rte_eth_allmulticast_disable: Function not supported
+		   Port 0: 00:16:3E:0A:CC:6D
+		   Checking link statuses...
+		   Port 0 Link Up - speed 10000 Mbps - full-duplex
+		   Done
+		   rte_eth_promiscuous_enable: Function not supported
+		   testpmd> 
-- 
2.5.5



More information about the dev mailing list