aboutsummaryrefslogtreecommitdiff
path: root/DEPENDENCIES
diff options
context:
space:
mode:
authorMatias Elo <matias.elo@nokia.com>2016-02-15 12:49:51 +0200
committerMaxim Uvarov <maxim.uvarov@linaro.org>2016-03-04 13:24:48 +0300
commitb97cab6a87a769111aae1849a2285573f5b5670f (patch)
tree6182b97edbf26c0945842a0b2caa3b962cf2bcb1 /DEPENDENCIES
parentf97bdbab49d4ff94ce7cf7427783cdf4e2abfcbd (diff)
linux-generic: pktio: add dpdk pktio build support
Add initial support for building ODP with DPDK pktio. Reviewed-by: Petri Savolainen <petri.savolainen@nokia.com> Signed-off-by: Matias Elo <matias.elo@nokia.com> Signed-off-by: Maxim Uvarov <maxim.uvarov@linaro.org>
Diffstat (limited to 'DEPENDENCIES')
-rw-r--r--DEPENDENCIES54
1 files changed, 54 insertions, 0 deletions
diff --git a/DEPENDENCIES b/DEPENDENCIES
index c2711d544..fe7df4091 100644
--- a/DEPENDENCIES
+++ b/DEPENDENCIES
@@ -154,6 +154,60 @@ Prerequisites for building the OpenDataPlane (ODP) API
netmap kernel module is loaded. If socket I/O is desired instead, it can be
activated by setting the environment variable ODP_PKTIO_DISABLE_NETMAP.
+3.4 DPDK (optional)
+
+ Use DPDK for ODP packet I/O.
+
+3.4.1 Building DPDK
+
+ DPDK packet I/O has been tested to work with DPDK v2.2.0.
+
+ # Checkout DPDK code
+ $ git clone http://dpdk.org/git/dpdk
+ $ cd dpdk
+ $ git checkout v2.2.0
+
+ # Make and edit DPDK configuration
+ $ make config T=x86_64-native-linuxapp-gcc O=x86_64-native-linuxapp-gcc
+ $ cd x86_64-native-linuxapp-gcc
+ $ sed -ri 's,(CONFIG_RTE_BUILD_COMBINE_LIBS=).*,\1y,' .config
+ # To use I/O without DPDK supported NIC's enable pcap pmd:
+ $ sed -ri 's,(CONFIG_RTE_LIBRTE_PMD_PCAP=).*,\1y,' .config
+ $ cd ..
+
+ # Build DPDK
+ $ make install T=x86_64-native-linuxapp-gcc EXTRA_CFLAGS="-fPIC"
+
+3.4.2 Setup system
+
+ # Load DPDK modules
+ $ sudo /sbin/modprobe uio
+ $ cd <dpdk-dir>
+ $ sudo insmod x86_64-native-linuxapp-gcc/kmod/igb_uio.ko
+
+ Reserve and mount hugepages and bind supported interfaces to DPDK modules
+ following the DPDK documentation. ODP DPDK packet I/O has been tested with
+ 512 x 2MB hugepages. All this can be done with the DPDK setup script
+ (<dpdk-dir>/tools/setup.sh).
+
+3.4.3 Building ODP
+
+ $ cd <odp_dir>
+ $ ./bootstrap
+ $ ./configure --with-dpdk-path=<dpdk_dir>/x86_64-native-linuxapp-gcc
+ $ make
+
+3.4.4 Running ODP with DPDK I/O
+
+ ODP applications will try use DPDK for packet I/O by default. If some other
+ I/O type is desired instead, DPDK I/O can be disabled by setting the
+ environment variable ODP_PKTIO_DISABLE_DPDK.
+
+ DPDK interfaces are accessed using indices. For example, two first DPDK
+ interfaces can be used with the odp_l2fwd example as follows:
+ $ cd <odp_dir>
+ $ sudo ./test/performance/odp_l2fwd -i 0,1 -c 2 -m 0
+
4.0 Packages needed to build API tests
Cunit test framework version 2.1-3 is required