1 .. SPDX-License-Identifier: BSD-3-Clause
2 Copyright(c) 2020 Intel Corporation.
10 This application showcases the features of the Software Switch (SWX) pipeline that is aligned with the P4 language.
12 Each pipeline is created using a specification file that can either be manually developed or generated using a P4 compiler.
14 Each pipeline is built through the CLI, either by invoking commands one by one, or through a CLI script.
15 The CLI can also be used to update the pipeline tables or poll the pipeline statistics.
17 Each pipeline is mapped to a specific application thread. Multiple pipelines can be mapped to the same thread.
19 Running the application
20 -----------------------
22 The application startup command line is::
24 dpdk-pipeline [EAL_ARGS] -- [-s SCRIPT_FILE] [-h HOST] [-p PORT]
26 The application startup arguments are:
32 * Default: Not present
34 * Argument: Path to the CLI script file to be run at application startup.
35 No CLI script file will run at startup if this argument is not present.
41 * Default: ``0.0.0.0``
43 * Argument: IP Address of the host running the application to be used by
44 remote TCP based client (telnet, netcat, etc.) for connection.
52 * Argument: TCP port number at which the application is running.
53 This port number should be used by remote TCP client (such as telnet, netcat, etc.) to connect to host application.
55 Refer to *DPDK Getting Started Guide* for general information on running applications and the Environment Abstraction Layer (EAL) options.
57 The following is an example command to run the application configured for the VXLAN encapsulation example:
59 .. code-block:: console
61 $ ./<build_dir>/examples/dpdk-pipeline -c 0x3 -- -s examples/vxlan.cli
63 The application should start successfully and display as follows:
65 .. code-block:: console
67 EAL: Detected 40 lcore(s)
68 EAL: Detected 2 NUMA nodes
69 EAL: Multi-process socket /var/run/.rte_unix
70 EAL: Probing VFIO support...
71 EAL: PCI device 0000:02:00.0 on NUMA socket 0
72 EAL: probe driver: 8086:10fb net_ixgbe
75 To run remote client (e.g. telnet) to communicate with the application:
77 .. code-block:: console
81 When running a telnet client as above, command prompt is displayed:
83 .. code-block:: console
87 Escape character is '^]'.
93 Once application and telnet client start running, messages can be sent from client to application.
102 During this stage, EAL layer is initialised and application specific arguments are parsed. Furthermore, the data structures
103 for application objects are initialized. In case of any initialization error, an error message is displayed and the application
109 The main thread is creating and managing all the application objects based on CLI input.
111 Each data plane thread runs one or several pipelines previously assigned to it in round-robin order. Each data plane thread
112 executes two tasks in time-sharing mode:
114 1. *Packet processing task*: Process bursts of input packets read from the pipeline input ports.
116 2. *Message handling task*: Periodically, the data plane thread pauses the packet processing task and polls for request
117 messages send by the main thread. Examples: add/remove pipeline to/from current data plane thread, add/delete rules
118 to/from given table of a specific pipeline owned by the current data plane thread, read statistics, etc.