aboutsummaryrefslogtreecommitdiffstats
path: root/dpdk-tests/dpdk_scripts/init_dpdk.sh
diff options
context:
space:
mode:
authorTibor Frank <tifrank@cisco.com>2017-02-10 09:24:00 +0100
committerPeter Mikus <pmikus@cisco.com>2017-04-03 09:46:36 +0000
commitec059708c78fe3563bc89507739a2712adc062f3 (patch)
tree1cf1805603919c3b5cf941f53bffa056bdeb7e10 /dpdk-tests/dpdk_scripts/init_dpdk.sh
parentc95798bd9e803a7ad98ed9056e6ddb1a8bbd2dc1 (diff)
Add x710 and xl710 tests for testpmd
10ge2p1x710-eth-l2xcbase-ndrdisc 40ge2p1xl710-eth-l2xcbase-ndrdisc Change-Id: Iea411182fd41e1ae9ed9b5a17f540befc247adb9 Signed-off-by: Tibor Frank <tifrank@cisco.com>
Diffstat (limited to 'dpdk-tests/dpdk_scripts/init_dpdk.sh')
-rwxr-xr-xdpdk-tests/dpdk_scripts/init_dpdk.sh32
1 files changed, 25 insertions, 7 deletions
diff --git a/dpdk-tests/dpdk_scripts/init_dpdk.sh b/dpdk-tests/dpdk_scripts/init_dpdk.sh
index b0bd426021..9870f49f42 100755
--- a/dpdk-tests/dpdk_scripts/init_dpdk.sh
+++ b/dpdk-tests/dpdk_scripts/init_dpdk.sh
@@ -1,17 +1,35 @@
#!/bin/bash
+set -x
+
+# Setting variables
+DPDK_VERSION=dpdk-17.02
ROOTDIR=/tmp/openvpp-testing
PWDDIR=$(pwd)
+cd ${ROOTDIR}/${DPDK_VERSION}/
-cd ${ROOTDIR}/dpdk-16.07/
modprobe uio
+echo "RC = $?"
+
lsmod | grep igb_uio
-if [ $? -eq 1 ];
+if [ $? -ne 1 ];
+then
+ rmmod igb_uio || \
+ echo "Failed to remove igb_uio module" || exit 1
+fi
+
+lsmod | grep uio_pci_generic
+if [ $? -ne 1 ];
then
- insmod ./x86_64-native-linuxapp-gcc/kmod/igb_uio.ko || exit 1
-else
- rmmod igb_uio
- insmod ./x86_64-native-linuxapp-gcc/kmod/igb_uio.ko || exit 1
+ rmmod uio_pci_generic || \
+ echo "Failed to remove uio_pci_generic module" || exit 1
fi
-./tools/dpdk-devbind.py -b igb_uio $1 $2
+
+insmod ./x86_64-native-linuxapp-gcc/kmod/igb_uio.ko || \
+ echo "Failed to insert igb_uio module" || exit 1
+
+# Binding
+./usertools/dpdk-devbind.py -b igb_uio $1 $2 || \
+ echo "Failed to bind interface $1 and $2 to igb_uio" || exit 1
+
cd ${PWDDIR}