@@ -31,30 +31,12 @@ Limitations
Compiling the Application
-------------------------
-#. DPDK needs to be built with ``baseband_turbo_sw`` PMD driver enabled along
- with ``FLEXRAN SDK`` Libraries. Refer to *SW Turbo Poll Mode Driver*
- documentation for more details on this.
+DPDK needs to be built with ``baseband_turbo_sw`` PMD driver enabled along
+with ``FLEXRAN SDK`` Libraries. Refer to *SW Turbo Poll Mode Driver*
+documentation for more details on this.
-#. Go to the example directory:
+To compile the sample application see :doc:`compiling`.
- .. code-block:: console
-
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}/examples/bbdev_app
-
-#. Set the target (a default target is used if not specified). For example:
-
- .. code-block:: console
-
- export RTE_TARGET=x86_64-native-linux-gcc
-
- See the *DPDK Getting Started Guide* for possible RTE_TARGET values.
-
-#. Build the application:
-
- .. code-block:: console
-
- make
Running the Application
-----------------------
@@ -63,8 +45,8 @@ The application accepts a number of command line options:
.. code-block:: console
- $ ./build/bbdev [EAL options] -- [-e ENCODING_CORES] [-d DECODING_CORES] /
- [-p ETH_PORT_ID] [-b BBDEV_ID]
+ $ ./<build_dir>/examples/dpdk-bbdev [EAL options] -- [-e ENCODING_CORES] /
+ [-d DECODING_CORES] [-p ETH_PORT_ID] [-b BBDEV_ID]
where:
@@ -84,8 +66,8 @@ issue the command:
.. code-block:: console
- $ ./build/bbdev --vdev='baseband_turbo_sw' -w <NIC0PCIADDR> -c 0x38 --socket-mem=2,2 \
- --file-prefix=bbdev -- -e 0x10 -d 0x20
+ $ ./<build_dir>/examples/dpdk-bbdev --vdev='baseband_turbo_sw' -w <NIC0PCIADDR> \
+ -c 0x38 --socket-mem=2,2 --file-prefix=bbdev -- -e 0x10 -d 0x20
where, NIC0PCIADDR is the PCI address of the Rx port
@@ -52,7 +52,7 @@ To run the application in linux environment, issue the following command:
.. code-block:: console
- $ ./build/cmdline -l 0-3 -n 4
+ $ ./<build_dir>/examples/dpdk-cmdline -l 0-3 -n 4
Refer to the *DPDK Getting Started Guide* for general information on running applications
and the Environment Abstraction Layer (EAL) options.
@@ -9,100 +9,75 @@ This section explains how to compile the DPDK sample applications.
To compile all the sample applications
--------------------------------------
-Set the path to DPDK source code if its not set:
+Go to DPDK build directory:
.. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
+ cd dpdk/<build_dir>
-Go to DPDK source:
-
- .. code-block:: console
-
- cd $RTE_SDK
-
-Build DPDK:
+Enable examples compilation:
.. code-block:: console
- make defconfig
- make
+ meson configure -Dexamples=all
-Build the sample applications:
+Build:
.. code-block:: console
- export RTE_TARGET=build
- make -C examples
+ ninja
-For other possible ``RTE_TARGET`` values and additional information on
-compiling see
+For additional information on compiling see
:ref:`Compiling DPDK on Linux <linux_gsg_compiling_dpdk>` or
:ref:`Compiling DPDK on FreeBSD <building_from_source>`.
-Applications are output to: ``$RTE_SDK/examples/app-dir/build`` or
-``$RTE_SDK/examples/app-dir/$RTE_TARGET``.
+Applications are output to: ``dpdk/<build_dir>/examples``.
-In the example above the compiled application is written to the ``build`` subdirectory.
-To have the applications written to a different location,
-the ``O=/path/to/build/directory`` option may be specified in the make command.
+To compile a single application
+-------------------------------
- .. code-block:: console
- make O=/tmp
+Using meson
+~~~~~~~~~~~
-To build the applications for debugging use the ``DEBUG`` option.
-This option adds some extra flags, disables compiler optimizations and
-sets verbose output.
+Go to DPDK build directory:
.. code-block:: console
- make DEBUG=1
-
-
-To compile a single application
--------------------------------
+ cd dpdk/<build_dir>
-Set the path to DPDK source code:
+Enable example app compilation:
- .. code-block:: console
+ .. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
+ meson configure -Dexamples=helloworld
-Go to DPDK source:
+Build:
- .. code-block:: console
+ .. code-block:: console
- cd $RTE_SDK
+ ninja
-Build DPDK:
- .. code-block:: console
+Using Make
+~~~~~~~~~~
- make defconfig
- make
+Pkg-config is used when building an example app standalone using make, please
+see :ref:`building_app_using_installed_dpdk` for more information.
Go to the sample application directory. Unless otherwise specified the sample
-applications are located in ``$RTE_SDK/examples/``.
-
+applications are located in ``dpdk/examples/``.
Build the application:
.. code-block:: console
- export RTE_TARGET=build
make
-To cross compile the sample application(s)
-------------------------------------------
-
-For cross compiling the sample application(s), please append 'CROSS=$(CROSS_COMPILER_PREFIX)' to the 'make' command.
-In example of AARCH64 cross compiling:
+To build the application for debugging use the ``DEBUG`` option.
+This option adds some extra flags, disables compiler optimizations and
+sets verbose output.
.. code-block:: console
- export RTE_TARGET=build
- export RTE_SDK=/path/to/rte_sdk
- make -C examples CROSS=aarch64-linux-gnu-
- or
- make CROSS=aarch64-linux-gnu-
+ make DEBUG=1
@@ -42,7 +42,7 @@ Running the Application
.. code-block:: console
- ./build/distributor_app [EAL options] -- -p PORTMASK
+ ./<build-dir>/examples/dpdk-distributor [EAL options] -- -p PORTMASK
where,
@@ -53,7 +53,7 @@ Running the Application
.. code-block:: console
- $ ./build/distributor_app -l 1-9,22 -n 4 -- -p f
+ $ ./<build-dir>/examples/dpdk-distributor -l 1-9,22 -n 4 -- -p f
#. Refer to the DPDK Getting Started Guide for general information on running
applications and the Environment Abstraction Layer (EAL) options.
@@ -24,7 +24,7 @@ The only available options are the standard ones for the EAL:
.. code-block:: console
- ./ethtool-app/${RTE_TARGET}/ethtool [EAL options]
+ ./<build_dir>/examples/dpdk-ethtool [EAL options]
Refer to the *DPDK Getting Started Guide* for general information on
running applications and the Environment Abstraction Layer (EAL)
@@ -46,7 +46,8 @@ these settings is shown below:
.. code-block:: console
- ./build/eventdev_pipeline --vdev event_sw0 -- -r1 -t1 -e4 -w FF00 -s4 -n0 -c32 -W1000 -D
+ ./<build_dir>/examples/dpdk-eventdev_pipeline --vdev event_sw0 -- -r1 -t1 /
+ -e4 -w FF00 -s4 -n0 -c32 -W1000 -D
The application has some sanity checking built-in, so if there is a function
(e.g.; the RX core) which doesn't have a cpu core mask assigned, the application
@@ -70,9 +70,7 @@ Compiling the Application
* Compile Application
- .. code-block:: console
-
- make -C examples/fips_validation
+ To compile the sample application see :doc:`compiling`.
* Run ``dos2unix`` on the request files
@@ -92,7 +90,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./fips_validation [EAL options]
+ ./dpdk-fips_validation [EAL options]
-- --req-file FILE_PATH/FOLDER_PATH
--rsp-file FILE_PATH/FOLDER_PATH
[--cryptodev DEVICE_NAME] [--cryptodev-id ID] [--path-is-folder]
@@ -117,7 +115,7 @@ file for crypto_aesni_mb PMD, issue the command:
.. code-block:: console
- $ ./fips_validation --vdev crypto_aesni_mb --
+ $ ./dpdk-fips_validation --vdev crypto_aesni_mb --
--req-file /PATH/TO/REQUEST/FILE.req --rsp-file ./PATH/TO/RESPONSE/FILE.rsp
--cryptodev crypto_aesni_mb
@@ -126,7 +124,7 @@ data files in one folder for crypto_aesni_gcm PMD, issue the command:
.. code-block:: console
- $ ./fips_validation --vdev crypto_aesni_gcm0 --
+ $ ./dpdk-fips_validation --vdev crypto_aesni_gcm0 --
--req-file /PATH/TO/REQUEST/FILE/FOLDER/
--rsp-file ./PATH/TO/RESPONSE/FILE/FOLDER/
--cryptodev-id 0 --path-is-folder
@@ -28,8 +28,8 @@ To run the example in a ``linux`` environment:
.. code-block:: console
- cd ~/dpdk/examples/flow_classify
- ./build/flow_classify -c 4 -n 4 -- --rule_ipv4="../ipv4_rules_file.txt"
+ ./<build_dir>/examples/dpdk-flow_classify -c 4 -n 4 -- /
+ --rule_ipv4="../ipv4_rules_file.txt"
Please refer to the *DPDK Getting Started Guide*, section
:doc:`../linux_gsg/build_sample_apps`
@@ -13,28 +13,7 @@ It is intended as a demonstration of the basic components RTE flow rules.
Compiling the Application
-------------------------
-To compile the application export the path to the DPDK source tree and go to
-the example directory:
-
-.. code-block:: console
-
- export RTE_SDK=/path/to/rte_sdk
-
- cd ${RTE_SDK}/examples/flow_filtering
-
-Set the target, for example:
-
-.. code-block:: console
-
- export RTE_TARGET=x86_64-native-linux-gcc
-
-See the *DPDK Getting Started* Guide for possible ``RTE_TARGET`` values.
-
-Build the application as follows:
-
-.. code-block:: console
-
- make
+To compile the sample application see :doc:`compiling`.
Running the Application
@@ -44,7 +23,7 @@ To run the example in a ``linux`` environment:
.. code-block:: console
- ./build/flow -l 1 -n 1
+ ./<build_dir>/examples/dpdk-flow_filtering -l 1 -n 1
Refer to *DPDK Getting Started Guide* for general information on running
applications and the Environment Abstraction Layer (EAL) options.
@@ -21,7 +21,7 @@ To run the example in a linux environment:
.. code-block:: console
- $ ./build/helloworld -l 0-3 -n 4
+ $ ./<build_dir>/examples/dpdk-helloworld -l 0-3 -n 4
Refer to *DPDK Getting Started Guide* for general information on running applications
and the Environment Abstraction Layer (EAL) options.
@@ -45,7 +45,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/ioatfwd [EAL options] -- [-p MASK] [-q NQ] [-s RS] [-c <sw|hw>]
+ ./<build_dir>/examples/dpdk-ioat [EAL options] -- [-p MASK] [-q NQ] [-s RS] [-c <sw|hw>]
[--[no-]mac-updating]
where,
@@ -81,7 +81,7 @@ updating issue the command:
.. code-block:: console
- $ ./build/ioatfwd -l 0-2 -n 2 -- -p 0x1 --mac-updating -c sw
+ $ ./<build_dir>/examples/dpdk-ioat -l 0-2 -n 2 -- -p 0x1 --mac-updating -c sw
To run the application in a Linux environment with 2 lcores (the master lcore,
plus one forwarding core), 2 ports (ports 0 and 1), hardware copying and no MAC
@@ -89,7 +89,7 @@ updating issue the command:
.. code-block:: console
- $ ./build/ioatfwd -l 0-1 -n 1 -- -p 0x3 --no-mac-updating -c hw
+ $ ./<build_dir>/examples/dpdk-ioat -l 0-1 -n 1 -- -p 0x3 --no-mac-updating -c hw
Refer to the *DPDK Getting Started Guide* for general information on
running applications and the Environment Abstraction Layer (EAL) options.
@@ -53,7 +53,7 @@ Application usage:
.. code-block:: console
- ./build/ip_fragmentation [EAL options] -- -p PORTMASK [-q NQ]
+ ./<build_dir>/examples/dpdk-ip_fragmentation [EAL options] -- -p PORTMASK [-q NQ]
where:
@@ -65,7 +65,7 @@ To run the example in linux environment with 2 lcores (2,4) over 2 ports(0,2) wi
.. code-block:: console
- ./build/ip_fragmentation -l 2,4 -n 3 -- -p 5
+ ./<build_dir>/examples/dpdk-ip_fragmentation -l 2,4 -n 3 -- -p 5
EAL: coremask set to 14
EAL: Detected lcore 0 on socket 0
EAL: Detected lcore 1 on socket 1
@@ -94,7 +94,7 @@ To run the example in linux environment with 1 lcore (4) over 2 ports(0,2) with
.. code-block:: console
- ./build/ip_fragmentation -l 4 -n 3 -- -p 5 -q 2
+ ./<build_dir>/examples/dpdk-ip_fragmentation -l 4 -n 3 -- -p 5 -q 2
To test the application, flows should be set up in the flow generator that match the values in the
l3fwd_ipv4_route_array and/or l3fwd_ipv6_route_array table.
@@ -34,7 +34,7 @@ Running the application
The application startup command line is::
- ip_pipeline [EAL_ARGS] -- [-s SCRIPT_FILE] [-h HOST] [-p PORT]
+ dpdk-ip_pipeline [EAL_ARGS] -- [-s SCRIPT_FILE] [-h HOST] [-p PORT]
The application startup arguments are:
@@ -71,7 +71,7 @@ The following is an example command to run ip pipeline application configured fo
.. code-block:: console
- $ ./build/ip_pipeline -c 0x3 -- -s examples/route_ecmp.cli
+ $ ./<build_dir>/examples/dpdk-ip_pipeline -c 0x3 -- -s examples/route_ecmp.cli
The application should start successfully and display as follows:
@@ -42,7 +42,7 @@ The application has a number of command line options:
.. code-block:: console
- ./build/ip_reassembly [EAL options] -- -p PORTMASK [-q NQ] [--maxflows=FLOWS>] [--flowttl=TTL[(s|ms)]]
+ ./<build_dir>/examples/dpdk-ip_reassembly [EAL options] -- -p PORTMASK [-q NQ] [--maxflows=FLOWS>] [--flowttl=TTL[(s|ms)]]
where:
@@ -61,7 +61,7 @@ To run the example in linux environment with 2 lcores (2,4) over 2 ports(0,2) wi
.. code-block:: console
- ./build/ip_reassembly -l 2,4 -n 3 -- -p 5
+ ./<build_dir>/examples/dpdk-ip_reassembly -l 2,4 -n 3 -- -p 5
EAL: coremask set to 14
EAL: Detected lcore 0 on socket 0
EAL: Detected lcore 1 on socket 1
@@ -92,7 +92,7 @@ To run the example in linux environment with 1 lcore (4) over 2 ports(0,2) with
.. code-block:: console
- ./build/ip_reassembly -l 4 -n 3 -- -p 5 -q 2
+ ./<build_dir>/examples/dpdk-ip_reassembly -l 4 -n 3 -- -p 5 -q 2
To test the application, flows should be set up in the flow generator that match the values in the
l3fwd_ipv4_route_array and/or l3fwd_ipv6_route_array table.
@@ -231,7 +231,8 @@ Debug logging and Statistics Collection
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
The RTE_LIBRTE_IP_FRAG_TBL_STAT controls statistics collection for the IP Fragment Table.
-This macro is disabled by default.
+This macro is disabled by default, but it can be enabled by modifying the appropriate line
+in ``config/rte_config.h``.
To make ip_reassembly print the statistics to the standard output,
the user must send either an USR1, INT or TERM signal to the process.
For all of these signals, the ip_reassembly process prints Fragment table statistics for each RX queue,
@@ -116,12 +116,6 @@ To compile the sample application see :doc:`compiling`.
The application is located in the ``ipsec-secgw`` sub-directory.
-#. [Optional] Build the application for debugging:
- This option adds some extra flags, disables compiler optimizations and
- is verbose::
-
- make DEBUG=1
-
Running the Application
-----------------------
@@ -129,7 +123,7 @@ Running the Application
The application has a number of command line options::
- ./build/ipsec-secgw [EAL options] --
+ ./<build_dir>/examples/dpdk-ipsec-secgw [EAL options] --
-p PORTMASK -P -u PORTMASK -j FRAMESIZE
-l -w REPLAY_WINOW_SIZE -e -a
-c SAD_CACHE_SIZE
@@ -245,7 +239,7 @@ The mapping of lcores to port/queues is similar to other l3fwd applications.
For example, given the following command line to run application in poll mode::
- ./build/ipsec-secgw -l 20,21 -n 4 --socket-mem 0,2048 \
+ ./<build_dir>/examples/dpdk-ipsec-secgw -l 20,21 -n 4 --socket-mem 0,2048 \
--vdev "crypto_null" -- -p 0xf -P -u 0x3 \
--config="(0,0,20),(1,0,20),(2,0,21),(3,0,21)" \
-f /path/to/config_file --transfer-mode poll \
@@ -297,7 +291,7 @@ where each option means:
Similarly for example, given the following command line to run application in
event app mode::
- ./build/ipsec-secgw -c 0x3 -- -P -p 0x3 -u 0x1 \
+ ./<build_dir>/examples/dpdk-ipsec-secgw -c 0x3 -- -P -p 0x3 -u 0x1 \
-f /path/to/config_file --transfer-mode event \
--event-schedule-type parallel \
@@ -336,7 +330,7 @@ For example, something like the following command line:
.. code-block:: console
- ./build/ipsec-secgw -l 20,21 -n 4 --socket-mem 0,2048 \
+ ./<build_dir>/examples/dpdk-ipsec-secgw -l 20,21 -n 4 --socket-mem 0,2048 \
-w 81:00.0 -w 81:00.1 -w 81:00.2 -w 81:00.3 \
--vdev "crypto_aesni_mb" --vdev "crypto_null" \
-- \
@@ -50,7 +50,7 @@ The application has a number of command line options:
.. code-block:: console
- ./build/ipv4_multicast [EAL options] -- -p PORTMASK [-q NQ]
+ ./<build_dir>/examples/dpdk-ipv4_multicast [EAL options] -- -p PORTMASK [-q NQ]
where,
@@ -67,7 +67,7 @@ Typically, to run the IPv4 Multicast sample application, issue the following com
.. code-block:: console
- ./build/ipv4_multicast -l 0-3 -n 3 -- -p 0x3 -q 1
+ ./<build_dir>/examples/dpdk-ipv4_multicast -l 0-3 -n 3 -- -p 0x3 -q 1
In this command:
@@ -49,7 +49,7 @@ The application has a number of command line options:
.. code-block:: console
- ./build/l2fwd-keepalive [EAL options] \
+ ./<build_dir>/examples/dpdk-l2fwd-keepalive [EAL options] \
-- -p PORTMASK [-q NQ] [-K PERIOD] [-T PERIOD]
where,
@@ -68,7 +68,7 @@ To run the application in linux environment with 4 lcores, 16 ports
.. code-block:: console
- ./build/l2fwd-keepalive -l 0-3 -n 4 -- -q 8 -p ffff -K 10
+ ./<build_dir>/examples/dpdk-l2fwd-keepalive -l 0-3 -n 4 -- -q 8 -p ffff -K 10
Refer to the *DPDK Getting Started Guide* for general information on
running applications and the Environment Abstraction Layer (EAL)
@@ -96,7 +96,7 @@ The ``kni`` example application requires a number of command line options:
.. code-block:: console
- kni [EAL options] -- -p PORTMASK --config="(port,lcore_rx,lcore_tx[,lcore_kthread,...])[,(port,lcore_rx,lcore_tx[,lcore_kthread,...])]" [-P] [-m]
+ dpdk-kni [EAL options] -- -p PORTMASK --config="(port,lcore_rx,lcore_tx[,lcore_kthread,...])[,(port,lcore_rx,lcore_tx[,lcore_kthread,...])]" [-P] [-m]
Where:
@@ -168,8 +168,8 @@ interface ``vEth1_0`` with the kernel thread bound to lcore 9.
.. code-block:: console
# rmmod rte_kni
- # insmod kmod/rte_kni.ko kthread_mode=multiple
- # ./build/kni -l 4-7 -n 4 -- -P -p 0x3 -m --config="(0,4,6,8),(1,5,7,9)"
+ # insmod <build_dir>/kernel/linux/kni/rte_kni.ko kthread_mode=multiple
+ # ./<build-dir>/examples/dpdk-kni -l 4-7 -n 4 -- -P -p 0x3 -m --config="(0,4,6,8),(1,5,7,9)"
The following example is identical, except an additional ``lcore_kthread``
core is specified per physical port. In this case, ``kni`` will create
@@ -186,8 +186,8 @@ The kernel thread for each interface will be bound as follows:
.. code-block:: console
# rmmod rte_kni
- # insmod kmod/rte_kni.ko kthread_mode=multiple
- # ./build/kni -l 4-7 -n 4 -- -P -p 0x3 -m --config="(0,4,6,8,10),(1,5,7,9,11)"
+ # insmod <build_dir>/kernel/linux/kni/rte_kni.ko kthread_mode=multiple
+ # ./<build-dir>/examples/dpdk-kni -l 4-7 -n 4 -- -P -p 0x3 -m --config="(0,4,6,8,10),(1,5,7,9,11)"
The following example can be used to test the interface between the ``kni``
test application and the ``rte_kni`` kernel module. In this example,
@@ -206,8 +206,8 @@ disabled by **not** specifying the ``-m`` flag to ``kni``:
.. code-block:: console
# rmmod rte_kni
- # insmod kmod/rte_kni.ko lo_mode=lo_mode_fifo carrier=on
- # ./build/kni -l 4-7 -n 4 -- -P -p 0x3 --config="(0,4,6,8),(1,5,7,9)"
+ # insmod <build_dir>/kernel/linux/kni/rte_kni.ko lo_mode=lo_mode_fifo carrier=on
+ # ./<build-dir>/examples/dpdk-kni -l 4-7 -n 4 -- -P -p 0x3 --config="(0,4,6,8),(1,5,7,9)"
KNI Operations
--------------
@@ -70,13 +70,13 @@ To run the example in a ``linux`` environment and enable CAT on cpus 0-2:
.. code-block:: console
- ./build/l2fwd-cat -l 1 -n 4 -- --l3ca="0x3@(0-2)"
+ ./<build_dir>/examples/dpdk-l2fwd-cat -l 1 -n 4 -- --l3ca="0x3@(0-2)"
or to enable CAT and CDP on cpus 1,3:
.. code-block:: console
- ./build/l2fwd-cat -l 1 -n 4 -- --l3ca="(0x00C00,0x00300)@(1,3)"
+ ./<build_dir>/examples/dpdk-l2fwd-cat -l 1 -n 4 -- --l3ca="(0x00C00,0x00300)@(1,3)"
If CDP is not supported it will fail with following error message:
@@ -39,7 +39,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/l2fwd-crypto [EAL options] -- [-p PORTMASK] [-q NQ] [-s] [-T PERIOD] /
+ ./<build_dir>/examples/dpdk-l2fwd-crypto [EAL options] -- [-p PORTMASK] [-q NQ] [-s] [-T PERIOD] /
[--cdev_type HW/SW/ANY] [--chain HASH_CIPHER/CIPHER_HASH/CIPHER_ONLY/HASH_ONLY/AEAD] /
[--cipher_algo ALGO] [--cipher_op ENCRYPT/DECRYPT] [--cipher_key KEY] /
[--cipher_key_random_size SIZE] [--cipher_iv IV] [--cipher_iv_random_size SIZE] /
@@ -162,7 +162,7 @@ To run the application in linux environment with 2 lcores, 2 ports and 2 crypto
.. code-block:: console
- $ ./build/l2fwd-crypto -l 0-1 -n 4 --vdev "crypto_aesni_mb0" \
+ $ ./<build_dir>/examples/dpdk-l2fwd-crypto -l 0-1 -n 4 --vdev "crypto_aesni_mb0" \
--vdev "crypto_aesni_mb1" -- -p 0x3 --chain CIPHER_HASH \
--cipher_op ENCRYPT --cipher_algo aes-cbc \
--cipher_key 00:01:02:03:04:05:06:07:08:09:0a:0b:0c:0d:0e:0f \
@@ -52,7 +52,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/l2fwd-event [EAL options] -- -p PORTMASK [-q NQ] --[no-]mac-updating --mode=MODE --eventq-sched=SCHED_MODE
+ ./<build_dir>/examples/dpdk-l2fwd-event [EAL options] -- -p PORTMASK [-q NQ] --[no-]mac-updating --mode=MODE --eventq-sched=SCHED_MODE
where,
@@ -75,20 +75,20 @@ issue the command:
.. code-block:: console
- ./build/l2fwd-event -l 0-3 -n 4 -- -q 8 -p ffff --mode=poll
+ ./<build_dir>/examples/dpdk-l2fwd-event -l 0-3 -n 4 -- -q 8 -p ffff --mode=poll
Eventdev mode with 4 lcores, 16 ports , sched method ordered and MAC address updating enabled,
issue the command:
.. code-block:: console
- ./build/l2fwd-event -l 0-3 -n 4 -- -p ffff --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l2fwd-event -l 0-3 -n 4 -- -p ffff --eventq-sched=ordered
or
.. code-block:: console
- ./build/l2fwd-event -l 0-3 -n 4 -- -q 8 -p ffff --mode=eventdev --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l2fwd-event -l 0-3 -n 4 -- -q 8 -p ffff --mode=eventdev --eventq-sched=ordered
Refer to the *DPDK Getting Started Guide* for general information on running
applications and the Environment Abstraction Layer (EAL) options.
@@ -105,7 +105,7 @@ scheduler. Following is the sample command:
.. code-block:: console
- ./build/l2fwd-event -l 0-7 -s 0-3 -n 4 --vdev event_sw0 -- -q 8 -p ffff --mode=eventdev --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l2fwd-event -l 0-7 -s 0-3 -n 4 --vdev event_sw0 -- -q 8 -p ffff --mode=eventdev --eventq-sched=ordered
Explanation
-----------
@@ -81,7 +81,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/l2fwd-jobstats [EAL options] -- -p PORTMASK [-q NQ] [-l]
+ ./<build_dir>/examples/dpdk-l2fwd-jobstats [EAL options] -- -p PORTMASK [-q NQ] [-l]
where,
@@ -96,7 +96,7 @@ thousands separator printing, issue the command:
.. code-block:: console
- $ ./build/l2fwd-jobstats -l 0-3 -n 4 -- -q 8 -p ffff -l
+ $ ./<build_dir>/examples/dpdk-l2fwd-jobstats -l 0-3 -n 4 -- -q 8 -p ffff -l
Refer to the *DPDK Getting Started Guide* for general information on running applications
and the Environment Abstraction Layer (EAL) options.
@@ -91,7 +91,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/l2fwd [EAL options] -- -p PORTMASK
+ ./<build_dir>/examples/dpdk-l2fwd [EAL options] -- -p PORTMASK
[-q NQ]
--[no-]mac-updating
[--portmap="(port, port)[,(port, port)]"]
@@ -111,7 +111,7 @@ updating enabled, issue the command:
.. code-block:: console
- $ ./build/l2fwd -l 0-3 -n 4 -- -q 8 -p ffff
+ $ ./<build_dir>/examples/dpdk-l2fwd -l 0-3 -n 4 -- -q 8 -p ffff
To run the application in linux environment with 4 lcores, 4 ports, 8 RX queues
per lcore, to forward RX traffic of ports 0 & 1 on ports 2 & 3 respectively and
@@ -119,7 +119,7 @@ vice versa, issue the command:
.. code-block:: console
- $ ./build/l2fwd -l 0-3 -n 4 -- -q 8 -p f --portmap="(0,2)(1,3)"
+ $ ./<build_dir>/examples/dpdk-l2fwd -l 0-3 -n 4 -- -q 8 -p f --portmap="(0,2)(1,3)"
Refer to the *DPDK Getting Started Guide* for general information on running applications
and the Environment Abstraction Layer (EAL) options.
@@ -51,7 +51,7 @@ Running the Application
The application has a number of command line options::
- ./l3fwd [EAL options] -- -p PORTMASK
+ ./dpdk-l3fwd [EAL options] -- -p PORTMASK
[-P]
[-E]
[-L]
@@ -111,7 +111,7 @@ To enable L3 forwarding between two ports, assuming that both ports are in the s
.. code-block:: console
- ./build/l3fwd -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)"
+ ./<build_dir>/examples/dpdk-l3fwd -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)"
In this command:
@@ -138,13 +138,13 @@ Following is the sample command:
.. code-block:: console
- ./build/l3fwd -l 0-3 -n 4 -w <event device> -- -p 0x3 --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l3fwd -l 0-3 -n 4 -w <event device> -- -p 0x3 --eventq-sched=ordered
or
.. code-block:: console
- ./build/l3fwd -l 0-3 -n 4 -w <event device> -- -p 0x03 --mode=eventdev --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l3fwd -l 0-3 -n 4 -w <event device> -- -p 0x03 --mode=eventdev --eventq-sched=ordered
In this command:
@@ -166,7 +166,7 @@ scheduler. Following is the sample command:
.. code-block:: console
- ./build/l3fwd -l 0-7 -s 0xf0000 -n 4 --vdev event_sw0 -- -p 0x3 --mode=eventdev --eventq-sched=ordered
+ ./<build_dir>/examples/dpdk-l3fwd -l 0-7 -s 0xf0000 -n 4 --vdev event_sw0 -- -p 0x3 --mode=eventdev --eventq-sched=ordered
In case of eventdev mode, *--config* option is not used for ethernet port
configuration. Instead each ethernet port will be configured with mentioned
@@ -184,7 +184,7 @@ Packet 2 matches Rule 2 and is forwarded to port 1.
Packet 3 matches Rule 3 and is forwarded to port 0.
For more details on the rule file format,
-please refer to rule_ipv4.db and rule_ipv6.db files (inside <RTE_SDK>/examples/l3fwd-acl/).
+please refer to rule_ipv4.db and rule_ipv6.db files (inside dpdk/examples/l3fwd-acl/).
Application Phases
~~~~~~~~~~~~~~~~~~
@@ -236,7 +236,7 @@ The application has a number of command line options:
.. code-block:: console
- ./build/l3fwd-acl [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] --rule_ipv4 FILENAME rule_ipv6 FILENAME [--scalar] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
+ ./<build_dir>/examples/dpdk-l3fwd-acl [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] --rule_ipv4 FILENAME rule_ipv6 FILENAME [--scalar] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
where,
@@ -268,7 +268,7 @@ To enable L3 forwarding between two ports, assuming that both ports are in the s
.. code-block:: console
- ./build/l3fwd-acl -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)" --rule_ipv4="./rule_ipv4.db" -- rule_ipv6="./rule_ipv6.db" --scalar
+ ./<build_dir>/examples/dpdk-l3fwd-acl -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)" --rule_ipv4="./rule_ipv4.db" -- rule_ipv6="./rule_ipv6.db" --scalar
In this command:
@@ -44,7 +44,7 @@ Running the Application
The application has a number of command line options similar to l3fwd::
- ./l3fwd-graph [EAL options] -- -p PORTMASK
+ ./dpdk-l3fwd-graph [EAL options] -- -p PORTMASK
[-P]
--config(port,queue,lcore)[,(port,queue,lcore)]
[--eth-dest=X,MM:MM:MM:MM:MM:MM]
@@ -79,7 +79,7 @@ To enable L3 forwarding between two ports, assuming that both ports are in the s
.. code-block:: console
- ./build/l3fwd-graph -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)"
+ ./<build_dir>/examples/dpdk-l3fwd-graph -l 1,2 -n 4 -- -p 0x3 --config="(0,0,1),(1,0,2)"
In this command:
@@ -88,7 +88,7 @@ The application has a number of command line options:
.. code-block:: console
- ./build/l3fwd_power [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
+ ./<build_dir>/examples/dpdk-l3fwd_power [EAL options] -- -p PORTMASK [-P] --config(port,queue,lcore)[,(port,queue,lcore)] [--enable-jumbo [--max-pkt-len PKTLEN]] [--no-numa]
where,
@@ -378,7 +378,7 @@ See :doc:`Power Management<../prog_guide/power_man>` chapter in the DPDK Program
.. code-block:: console
- ./l3fwd-power -l xxx -n 4 -w 0000:xx:00.0 -w 0000:xx:00.1 -- -p 0x3 -P --config="(0,0,xx),(1,0,xx)" --empty-poll="0,0,0" -l 14 -m 9 -h 1
+ ./<build_dir>/examples/dpdk-l3fwd-power -l xxx -n 4 -w 0000:xx:00.0 -w 0000:xx:00.1 -- -p 0x3 -P --config="(0,0,xx),(1,0,xx)" --empty-poll="0,0,0" -l 14 -m 9 -h 1
Where,
@@ -407,7 +407,7 @@ app with the training flag set to “1”, and the other parameters set to
.. code-block:: console
- ./examples/l3fwd-power/build/l3fwd-power -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --empty-poll "1,0,0" –P
+ ./<build_dir>/examples/dpdk-l3fwd-power -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --empty-poll "1,0,0" –P
This will run the training algorithm for x seconds on each core (cores 2
and 3), and then print out the recommended threshold values for those
@@ -432,7 +432,7 @@ then be started without the training mode so traffic can start immediately.
.. code-block:: console
- ./examples/l3fwd-power/build/l3fwd-power -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --empty-poll "0,340000,540000" –P
+ ./<build_dir>/examples/dpdk-l3fwd-power -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --empty-poll "0,340000,540000" –P
Telemetry Mode
--------------
@@ -449,13 +449,9 @@ cycles it took is measured and compared with minimum and maximum
reference cycles and accordingly busy rate is set to either 0% or
50% or 100%.
- .. Note::
-
- * The CONFIG_RTE_LIBRTE_TELEMETRY should be set in order to get the stats in DPDK telemetry.
-
.. code-block:: console
- ./examples/l3fwd-power/build/l3fwd-power --telemetry -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --telemetry
+ ./<build_dir>/examples/dpdk-l3fwd-power --telemetry -l 1-3 -- -p 0x0f --config="(0,0,2),(0,1,3)" --telemetry
The new stats ``empty_poll`` , ``full_poll`` and ``busy_percent`` can be viewed by running the script
``/usertools/dpdk-telemetry-client.py`` and selecting the menu option ``Send for global Metrics``.
@@ -39,7 +39,7 @@ The application requires a number of command line options:
.. code-block:: console
- ./build/link_status_interrupt [EAL options] -- -p PORTMASK [-q NQ][-T PERIOD]
+ ./<build_dir>/examples/dpdk-link_status_interrupt [EAL options] -- -p PORTMASK [-q NQ][-T PERIOD]
where,
@@ -54,7 +54,7 @@ issue the command:
.. code-block:: console
- $ ./build/link_status_interrupt -l 0-3 -n 4-- -q 8 -p ffff
+ $ ./<build_dir>/examples/dpdk-link_status_interrupt -l 0-3 -n 4-- -q 8 -p ffff
Refer to the *DPDK Getting Started Guide* for general information on running applications
and the Environment Abstraction Layer (EAL) options.
@@ -41,7 +41,7 @@ passing at least two cores in the coremask/corelist, as follows:
.. code-block:: console
- ./build/simple_mp -l 0-1 -n 4 --proc-type=primary
+ ./<build_dir>/examples/dpdk-simple_mp -l 0-1 -n 4 --proc-type=primary
For the first DPDK process run, the proc-type flag can be omitted or set to auto,
since all DPDK processes will default to being a primary instance,
@@ -50,7 +50,7 @@ The process should start successfully and display a command prompt as follows:
.. code-block:: console
- $ ./build/simple_mp -l 0-1 -n 4 --proc-type=primary
+ $ ./<build_dir>/examples/dpdk-simple_mp -l 0-1 -n 4 --proc-type=primary
EAL: coremask set to 3
EAL: Detected lcore 0 on socket 0
EAL: Detected lcore 1 on socket 0
@@ -78,7 +78,7 @@ again run the same binary setting at least two cores in the coremask/corelist:
.. code-block:: console
- ./build/simple_mp -l 2-3 -n 4 --proc-type=secondary
+ ./<build_dir>/examples/dpdk-simple_mp -l 2-3 -n 4 --proc-type=secondary
When running a secondary process such as that shown above, the proc-type parameter can again be specified as auto.
However, omitting the parameter altogether will cause the process to try and start as a primary rather than secondary process.
@@ -184,10 +184,10 @@ the following commands can be used (assuming run as root):
.. code-block:: console
- # ./build/symmetric_mp -l 1 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=0
- # ./build/symmetric_mp -l 2 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=1
- # ./build/symmetric_mp -l 3 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=2
- # ./build/symmetric_mp -l 4 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=3
+ # ./<build_dir>/examples/dpdk-symmetric_mp -l 1 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=0
+ # ./<build_dir>/examples/dpdk-symmetric_mp -l 2 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=1
+ # ./<build_dir>/examples/dpdk-symmetric_mp -l 3 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=2
+ # ./<build_dir>/examples/dpdk-symmetric_mp -l 4 -n 4 --proc-type=auto -- -p 3 --num-procs=4 --proc-id=3
.. note::
@@ -284,9 +284,9 @@ the following commands could be used:
.. code-block:: console
- # ./mp_server/build/mp_server -l 1-2 -n 4 -- -p 3 -n 2
- # ./mp_client/build/mp_client -l 3 -n 4 --proc-type=auto -- -n 0
- # ./mp_client/build/mp_client -l 4 -n 4 --proc-type=auto -- -n 1
+ # ./<build_dir>/examples/dpdk-mp_server -l 1-2 -n 4 -- -p 3 -n 2
+ # ./<build_dir>/examples/dpdk-mp_client -l 3 -n 4 --proc-type=auto -- -n 0
+ # ./<build_dir>/examples/dpdk-mp_client -l 4 -n 4 --proc-type=auto -- -n 1
.. note::
@@ -32,7 +32,7 @@ The only available options are the standard ones for the EAL:
.. code-block:: console
- ./build/ntb_fwd -c 0xf -n 6 -- -i
+ ./<build_dir>/examples/dpdk-ntb -c 0xf -n 6 -- -i
Refer to the *DPDK Getting Started Guide* for general information on
running applications and the Environment Abstraction Layer (EAL)
@@ -43,7 +43,8 @@ The application execution command line is:
.. code-block:: console
- ./packet_ordering [EAL options] -- -p PORTMASK [--disable-reorder] [--insight-worker]
+ ./<build_dir>/examples/dpdk-packet_ordering [EAL options] -- -p PORTMASK /
+ [--disable-reorder] [--insight-worker]
The -c EAL CPU_COREMASK option has to contain at least 3 CPU cores.
The first CPU core in the core mask is the master core and would be assigned to
@@ -55,7 +55,7 @@ Running the Application
The application has a number of command line options::
- ./build/l3fwd-thread [EAL options] --
+ ./<build_dir>/examples/dpdk-l3fwd-thread [EAL options] --
-p PORTMASK [-P]
--rx(port,queue,lcore,thread)[,(port,queue,lcore,thread)]
--tx(lcore,thread)[,(lcore,thread)]
@@ -141,14 +141,14 @@ in ``--rx/--tx`` are used to affinitize threads to the selected scheduler.
For example, the following places every l-thread on different lcores::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)"
The following places RX l-threads on lcore 0 and TX l-threads on lcore 1 and 2
and so on::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,0,1)" \
--tx="(1,0)(2,1)"
@@ -164,7 +164,7 @@ place every RX and TX thread on different lcores.
For example, the following places every EAL thread on different lcores::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)" \
--no-lthreads
@@ -176,7 +176,7 @@ parameter is used.
The following places RX EAL threads on lcore 0 and TX EAL threads on lcore 1
and 2 and so on::
- l3fwd-thread -l 0-7 -n 2 --lcores="(0,1)@0,(2,3)@1" -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 --lcores="(0,1)@0,(2,3)@1" -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)" \
--no-lthreads
@@ -190,13 +190,13 @@ and its corresponding EAL threads command line can be realized as follows:
a) Start every thread on different scheduler (1:1)::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)"
EAL thread equivalent::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)" \
--no-lthreads
@@ -205,13 +205,13 @@ b) Start all threads on one core (N:1).
Start 4 L-threads on lcore 0::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,0,1)" \
--tx="(0,0)(0,1)"
Start 4 EAL threads on cpu-set 0::
- l3fwd-thread -l 0-7 -n 2 --lcores="(0-3)@0" -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 --lcores="(0-3)@0" -- -P -p 3 \
--rx="(0,0,0,0)(1,0,0,1)" \
--tx="(2,0)(3,1)" \
--no-lthreads
@@ -220,14 +220,14 @@ c) Start threads on different cores (N:M).
Start 2 L-threads for RX on lcore 0, and 2 L-threads for TX on lcore 1::
- l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 -- -P -p 3 \
--rx="(0,0,0,0)(1,0,0,1)" \
--tx="(1,0)(1,1)"
Start 2 EAL threads for RX on cpu-set 0, and 2 EAL threads for TX on
cpu-set 1::
- l3fwd-thread -l 0-7 -n 2 --lcores="(0-1)@0,(2-3)@1" -- -P -p 3 \
+ dpdk-l3fwd-thread -l 0-7 -n 2 --lcores="(0-1)@0,(2-3)@1" -- -P -p 3 \
--rx="(0,0,0,0)(1,0,1,1)" \
--tx="(2,0)(3,1)" \
--no-lthreads
@@ -1146,33 +1146,15 @@ in the performance-thread folder
To build and run the pthread shim example
-#. Go to the example applications folder
-
- .. code-block:: console
-
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}/examples/performance-thread/pthread_shim
-
-
-#. Set the target (a default target is used if not specified). For example:
-
- .. code-block:: console
-
- export RTE_TARGET=x86_64-native-linux-gcc
-
- See the DPDK Getting Started Guide for possible RTE_TARGET values.
-
#. Build the application:
- .. code-block:: console
-
- make
+ To compile the sample application see :doc:`compiling`.
#. To run the pthread_shim example
.. code-block:: console
- lthread-pthread-shim -c core_mask -n number_of_channels
+ dpdk-pthread-shim -c core_mask -n number_of_channels
.. _lthread_diagnostics:
@@ -57,13 +57,6 @@ To compile the sample application see :doc:`compiling`.
The application is located in the ``ptpclient`` sub-directory.
-.. note::
- To compile the application edit the ``config/common_linux`` configuration file to enable IEEE1588
- and then recompile DPDK:
-
- .. code-block:: console
-
- CONFIG_RTE_LIBRTE_IEEE1588=y
Running the Application
-----------------------
@@ -72,7 +65,7 @@ To run the example in a ``linux`` environment:
.. code-block:: console
- ./build/ptpclient -l 1 -n 4 -- -p 0x1 -T 0
+ ./<build_dir>/examples/dpdk-ptpclient -l 1 -n 4 -- -p 0x1 -T 0
Refer to *DPDK Getting Started Guide* for general information on running
applications and the Environment Abstraction Layer (EAL) options.
@@ -48,7 +48,7 @@ The application execution command line is as below:
.. code-block:: console
- ./qos_meter [EAL options] -- -p PORTMASK
+ ./dpdk-qos_meter [EAL options] -- -p PORTMASK
The application is constrained to use a single core in the EAL core mask and 2 ports only in the application port mask
(first port from the port mask is used for RX and the other port in the core mask is used for TX).
@@ -42,8 +42,8 @@ The application is located in the ``qos_sched`` sub-directory.
.. note::
To get statistics on the sample app using the command line interface as described in the next section,
- DPDK must be compiled defining *CONFIG_RTE_SCHED_COLLECT_STATS*,
- which can be done by changing the configuration file for the specific target to be compiled.
+ DPDK must be compiled defining *RTE_SCHED_COLLECT_STATS*, which can be done by changing the relevant
+ entry in the ``config/rte_config.h`` file.
Running the Application
-----------------------
@@ -57,7 +57,7 @@ The application has a number of command line options:
.. code-block:: console
- ./qos_sched [EAL options] -- <APP PARAMS>
+ ./<build_dir>/examples/dpdk-qos_sched [EAL options] -- <APP PARAMS>
Mandatory application parameters include:
@@ -315,7 +315,7 @@ The following is an example command with a single packet flow configuration:
.. code-block:: console
- ./qos_sched -l 1,5,7 -n 4 -- --pfc "3,2,5,7" --cfg ./profile.cfg
+ ./<build_dir>/examples/dpdk-qos_sched -l 1,5,7 -n 4 -- --pfc "3,2,5,7" --cfg ./profile.cfg
This example uses a single packet flow configuration which creates one RX thread on lcore 5 reading
from port 3 and a worker thread on lcore 7 writing to port 2.
@@ -324,7 +324,7 @@ Another example with 2 packet flow configurations using different ports but shar
.. code-block:: console
- ./qos_sched -l 1,2,6,7 -n 4 -- --pfc "3,2,2,6,7" --pfc "1,0,2,6,7" --cfg ./profile.cfg
+ ./<build_dir>/examples/dpdk-qos_sched -l 1,2,6,7 -n 4 -- --pfc "3,2,2,6,7" --pfc "1,0,2,6,7" --cfg ./profile.cfg
Note that independent cores for the packet flow configurations for each of the RX, WT and TX thread are also supported,
providing flexibility to balance the work.
@@ -25,13 +25,6 @@ To compile the sample application see :doc:`compiling`.
The application is located in the ``rxtx_callbacks`` sub-directory.
-The callbacks feature requires that the ``CONFIG_RTE_ETHDEV_RXTX_CALLBACKS``
-setting is on in the ``config/common_`` config file that applies to the
-target. This is generally on by default:
-
-.. code-block:: console
-
- CONFIG_RTE_ETHDEV_RXTX_CALLBACKS=y
Running the Application
-----------------------
@@ -40,7 +33,7 @@ To run the example in a ``linux`` environment:
.. code-block:: console
- ./build/rxtx_callbacks -l 1 -n 4 -- [-t]
+ ./<build_dir>/examples/dpdk-rxtx_callbacks -l 1 -n 4 -- [-t]
Use -t to enable hardware timestamping. If not supported by the NIC, an error
will be displayed.
@@ -93,7 +93,7 @@ and the back-end node.
The frontend server (server) has the following command line options::
- ./server [EAL options] -- -p PORTMASK -n NUM_NODES -f NUM_FLOWS
+ ./<build_dir>/examples/dpdk-server [EAL options] -- -p PORTMASK -n NUM_NODES -f NUM_FLOWS
Where,
@@ -20,26 +20,9 @@ is application specific, and not a part of the service cores API.
Compiling the Application
-------------------------
-#. Go to the example directory:
+To compile the sample application see :doc:`compiling`.
- .. code-block:: console
-
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}/examples/service_cores
-
-#. Set the target (a default target is used if not specified). For example:
-
- .. code-block:: console
-
- export RTE_TARGET=x86_64-native-linux-gcc
-
- See the *DPDK Getting Started* Guide for possible RTE_TARGET values.
-
-#. Build the application:
-
- .. code-block:: console
-
- make
+The application is located in the ``service_cores`` sub-directory.
Running the Application
-----------------------
@@ -50,7 +33,7 @@ pass a service core-mask as an EAL argument at startup time.
.. code-block:: console
- $ ./build/service_cores
+ $ ./<build_dir>/examples/dpdk-service_cores
Explanation
@@ -25,7 +25,7 @@ To run the example in a ``linux`` environment:
.. code-block:: console
- ./build/basicfwd -l 1 -n 4
+ ./<build_dir>/examples/dpdk-skeleton -l 1 -n 4
Refer to *DPDK Getting Started Guide* for general information on running
applications and the Environment Abstraction Layer (EAL) options.
@@ -90,36 +90,17 @@ The example in this section have been validated with the following distributions
* Fedora* 20
-Compiling the Sample Code
--------------------------
-
-To enable vhost, turn on vhost library in the configure file
-``config/common_linux``.
-
- .. code-block:: console
-
- CONFIG_RTE_LIBRTE_VHOST=y
-
-Then following the to compile the sample application shown in
-:doc:`compiling`.
Running the Sample Code
-----------------------
-#. Go to the examples directory:
+Run the tep_termination sample code:
- .. code-block:: console
-
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}/examples/tep_termination
-
-#. Run the tep_termination sample code:
-
- .. code-block:: console
+.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
- -p 0x1 --dev-basename tep-termination --nb-devices 4
- --udp-port 4789 --filter-type 1
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ -p 0x1 --dev-basename tep-termination --nb-devices 4
+ --udp-port 4789 --filter-type 1
.. note::
@@ -139,7 +120,7 @@ The default value is 2.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 2
**Tunneling UDP port.**
@@ -149,7 +130,7 @@ The default value is 4789.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 2 --udp-port 4789
**Filter Type.**
@@ -160,7 +141,7 @@ The default value is 1, which means the filter type of inner MAC and tenant ID i
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 2 --udp-port 4789 --filter-type 1
**TX Checksum.**
@@ -170,7 +151,7 @@ The default value is 0, which means the checksum offload is disabled.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 2 --tx-checksum
**TCP segment size.**
@@ -180,7 +161,7 @@ The default value is 0, which means TSO offload is disabled.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--tx-checksum --tso-segsz 800
**Decapsulation option.**
@@ -190,7 +171,7 @@ The default value is 1.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 4 --udp-port 4789 --decap 1
**Encapsulation option.**
@@ -200,7 +181,7 @@ The default value is 1.
.. code-block:: console
- user@target:~$ ./build/app/tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
+ user@target:~$ ./<build_dir>/examples/dpdk-tep_termination -l 0-3 -n 4 --huge-dir /mnt/huge --
--nb-devices 4 --udp-port 4789 --encap 1
@@ -32,7 +32,7 @@ Compiling the Application
-------------------------
To compile the sample application see :doc:`compiling`
-The application is located in the ``$RTE_SDK/app/test-pipeline`` directory.
+The application is located in the ``dpdk/<build_dir>/app`` directory.
Running the Application
@@ -45,7 +45,7 @@ The application execution command line is:
.. code-block:: console
- ./test-pipeline [EAL options] -- -p PORTMASK --TABLE_TYPE
+ ./dpdk-test-pipeline [EAL options] -- -p PORTMASK --TABLE_TYPE
The -c or -l EAL CPU coremask/corelist option has to contain exactly 3 CPU cores.
The first CPU core in the core mask is assigned for core A, the second for core B and the third for core C.
@@ -21,7 +21,7 @@ To run the example in linux environment:
.. code-block:: console
- $ ./build/timer -l 0-3 -n 4
+ $ ./<build_dir>/examples/dpdk-timer -l 0-3 -n 4
Refer to the *DPDK Getting Started Guide* for general information on running applications and
the Environment Abstraction Layer (EAL) options.
@@ -29,7 +29,7 @@ Start the vdpa example
.. code-block:: console
- ./vdpa [EAL options] -- [--client] [--interactive|-i] or [--iface SOCKET_PATH]
+ ./dpdk-vdpa [EAL options] -- [--client] [--interactive|-i] or [--iface SOCKET_PATH]
where
@@ -51,7 +51,7 @@ Take IFCVF driver for example:
.. code-block:: console
- ./vdpa -c 0x2 -n 4 --socket-mem 1024,1024 \
+ ./dpdk-vdpa -c 0x2 -n 4 --socket-mem 1024,1024 \
-w 0000:06:00.3,vdpa=1 -w 0000:06:00.4,vdpa=1 \
-- --interactive
@@ -38,7 +38,7 @@ Start the vswitch example
.. code-block:: console
- ./vhost-switch -l 0-3 -n 4 --socket-mem 1024 \
+ ./dpdk-vhost-switch -l 0-3 -n 4 --socket-mem 1024 \
-- --socket-file /tmp/sock0 --client \
...
@@ -78,13 +78,13 @@ could be done by:
.. code-block:: console
modprobe uio_pci_generic
- $RTE_SDK/usertools/dpdk-devbind.py -b uio_pci_generic 0000:00:04.0
+ dpdk/usertools/dpdk-devbind.py -b uio_pci_generic 0000:00:04.0
Then start testpmd for packet forwarding testing.
.. code-block:: console
- ./x86_64-native-gcc/app/testpmd -l 0-1 -- -i
+ ./<build_dir>/app/dpdk-testpmd -l 0-1 -- -i
> start tx_first
Inject packets
@@ -192,11 +192,6 @@ Common Issues
max queue number is larger than 128, device start will fail due to
insufficient mbuf.
- Change the default number to make it work as below, just set the number
- according to the NIC's property. ::
-
- make EXTRA_CFLAGS="-DMAX_QUEUES=320"
-
* Option "builtin-net-driver" is incompatible with QEMU
QEMU vhost net device start will fail if protocol feature is not negotiated.
@@ -36,7 +36,7 @@ Start the vhost_blk example
.. code-block:: console
- ./vhost_blk -m 1024
+ ./dpdk-vhost_blk -m 1024
.. _vhost_blk_app_run_vm:
@@ -28,7 +28,7 @@ Start the vhost_crypto example
.. code-block:: console
- ./vhost_crypto [EAL options] --
+ ./dpdk-vhost_crypto [EAL options] --
--config (lcore,cdev-id,queue-id)[,(lcore,cdev-id,queue-id)]
--socket-file lcore,PATH
[--zero-copy]
@@ -245,26 +245,23 @@ To build just the ``vm_power_manager`` application using ``make``:
.. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
- export RTE_TARGET=build
- cd ${RTE_SDK}/examples/vm_power_manager/
+ cd dpdk/examples/vm_power_manager/
make
-The resulting binary is ``${RTE_SDK}/build/examples/vm_power_manager``.
+The resulting binary is ``dpdk/build/examples/vm_power_manager``.
To build just the ``vm_power_manager`` application using ``meson``/``ninja``:
.. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}
+ cd dpdk
meson build
cd build
ninja
meson configure -Dexamples=vm_power_manager
ninja
-The resulting binary is ``${RTE_SDK}/build/examples/dpdk-vm_power_manager``.
+The resulting binary is ``dpdk/build/examples/dpdk-vm_power_manager``.
Running the Host Application
~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -274,7 +271,7 @@ than the EAL options:
.. code-block:: console
- ./build/vm_power_mgr [EAL options]
+ ./<build_dir>/examples/dpdk-vm_power_mgr [EAL options]
The application requires exactly two cores to run. One core for the CLI
and the other for the channel endpoint monitor. For example, to run on
@@ -282,7 +279,7 @@ cores 0 and 1 on a system with four memory channels, issue the command:
.. code-block:: console
- ./build/vm_power_mgr -l 0-1 -n 4
+ ./<build_dir>/examples/dpdk-vm_power_mgr -l 0-1 -n 4
After successful initialization, the VM Power Manager CLI prompt appears:
@@ -462,12 +459,10 @@ the following commands:
.. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
- export RTE_TARGET=build
- cd ${RTE_SDK}/examples/vm_power_manager/guest_cli/
+ cd dpdk/examples/vm_power_manager/guest_cli/
make
-The resulting binary is ``${RTE_SDK}/build/examples/guest_cli``.
+The resulting binary is ``dpdk/build/examples/guest_cli``.
**Note**: This sample application conditionally links in the Jansson JSON
library. Consequently, if you are using a multilib or cross-compile
@@ -498,15 +493,14 @@ To build just the ``vm_power_manager`` application using ``meson``/``ninja``:
.. code-block:: console
- export RTE_SDK=/path/to/rte_sdk
- cd ${RTE_SDK}
+ cd dpdk
meson build
cd build
ninja
meson configure -Dexamples=vm_power_manager/guest_cli
ninja
-The resulting binary is ``${RTE_SDK}/build/examples/guest_cli``.
+The resulting binary is ``dpdk/build/examples/guest_cli``.
Running the Guest Application
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
@@ -515,14 +509,14 @@ The standard EAL command line parameters are necessary:
.. code-block:: console
- ./build/vm_power_mgr [EAL options] -- [guest options]
+ ./<build_dir>/examples/dpdk-vm_power_mgr [EAL options] -- [guest options]
The guest example uses a channel for each lcore enabled. For example, to
run on cores 0, 1, 2 and 3:
.. code-block:: console
- ./build/guest_vm_power_mgr -l 0-3
+ ./<build_dir>/examples/dpdk-guest_vm_power_mgr -l 0-3
.. _sending_policy:
@@ -593,7 +587,7 @@ host, use a command like the following:
.. code-block:: console
- ./build/guest_vm_power_mgr -l 0-3 -n 4 -- --vm-name=ubuntu --policy=BRANCH_RATIO --vcpu-list=2-4
+ ./<build_dir>/examples/dpdk-guest_vm_power_mgr -l 0-3 -n 4 -- --vm-name=ubuntu --policy=BRANCH_RATIO --vcpu-list=2-4
Once the VM Power Manager Guest CLI appears, issuing the 'send_policy now' command
will send the policy to the host:
@@ -707,7 +701,7 @@ To start the application and configure the power policy, and send it to the host
.. code-block:: console
- ./build/guest_vm_power_mgr -l 0-3 -n 4 -- --vm-name=ubuntu --policy=BRANCH_RATIO --vcpu-list=2-4
+ ./<build_dir>/examples/dpdk-guest_vm_power_mgr -l 0-3 -n 4 -- --vm-name=ubuntu --policy=BRANCH_RATIO --vcpu-list=2-4
Once the VM Power Manager Guest CLI appears, issuing the 'send_policy now' command
will send the policy to the host:
@@ -26,13 +26,13 @@ multiple queues. When run with 8 threads, that is, with the -c FF option, each t
As supplied, the sample application configures the VMDQ feature to have 32 pools with 4 queues each as indicated in :numref:`figure_vmdq_dcb_example`.
The Intel® 82599 10 Gigabit Ethernet Controller NIC also supports the splitting of traffic into 16 pools of 8 queues. While the
Intel® X710 or XL710 Ethernet Controller NICs support many configurations of VMDQ pools of 4 or 8 queues each. For simplicity, only 16
-or 32 pools is supported in this sample. And queues numbers for each VMDQ pool can be changed by setting CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM
-in config/common_* file.
+or 32 pools is supported in this sample. And queues numbers for each VMDQ pool can be changed by setting RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM
+in config/rte_config.h file.
The nb-pools, nb-tcs and enable-rss parameters can be passed on the command line, after the EAL parameters:
.. code-block:: console
- ./build/vmdq_dcb [EAL options] -- -p PORTMASK --nb-pools NP --nb-tcs TC --enable-rss
+ ./<build_dir>/examples/dpdk-vmdq_dcb [EAL options] -- -p PORTMASK --nb-pools NP --nb-tcs TC --enable-rss
where, NP can be 16 or 32, TC can be 4 or 8, rss is disabled by default.
@@ -72,7 +72,7 @@ To run the example in a linux environment:
.. code-block:: console
- user@target:~$ ./build/vmdq_dcb -l 0-3 -n 4 -- -p 0x3 --nb-pools 32 --nb-tcs 4
+ user@target:~$ ./<build_dir>/examples/dpdk-vmdq_dcb -l 0-3 -n 4 -- -p 0x3 --nb-pools 32 --nb-tcs 4
Refer to the *DPDK Getting Started Guide* for general information on running applications and
the Environment Abstraction Layer (EAL) options.
@@ -24,13 +24,13 @@ multiple queues. When run with 8 threads, that is, with the -c FF option, each t
As supplied, the sample application configures the VMDq feature to have 32 pools with 4 queues each.
The Intel® 82599 10 Gigabit Ethernet Controller NIC also supports the splitting of traffic into 16 pools of 2 queues.
While the Intel® X710 or XL710 Ethernet Controller NICs support many configurations of VMDq pools of 4 or 8 queues each.
-And queues numbers for each VMDq pool can be changed by setting CONFIG_RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM
-in config/common_* file.
+And queues numbers for each VMDq pool can be changed by setting RTE_LIBRTE_I40E_QUEUE_NUM_PER_VM
+in config/rte_config.h file.
The nb-pools and enable-rss parameters can be passed on the command line, after the EAL parameters:
.. code-block:: console
- ./build/vmdq_app [EAL options] -- -p PORTMASK --nb-pools NP --enable-rss
+ ./<build_dir>/examples/dpdk-vmdq [EAL options] -- -p PORTMASK --nb-pools NP --enable-rss
where, NP can be 8, 16 or 32, rss is disabled by default.
@@ -56,7 +56,7 @@ To run the example in a Linux environment:
.. code-block:: console
- user@target:~$ ./build/vmdq_app -l 0-3 -n 4 -- -p 0x3 --nb-pools 16
+ user@target:~$ ./<build_dir>/examples/dpdk-vmdq -l 0-3 -n 4 -- -p 0x3 --nb-pools 16
Refer to the *DPDK Getting Started Guide* for general information on running applications and
the Environment Abstraction Layer (EAL) options.