From 6dcfa49f61b6fa9d4160fcf554b12f65fb64de2f Mon Sep 17 00:00:00 2001 From: Michal Berger Date: Tue, 26 Jan 2021 11:44:10 +0100 Subject: [PATCH] qat_setup: Don't use absolute path to igb_uio driver This driver is now built by vm_setup.sh and installed under /lib/modules. Signed-off-by: Michal Berger Change-Id: Icea6b96e60390932c14ff49405614c186e61a99b Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/6099 Community-CI: Broadcom CI Tested-by: SPDK CI Jenkins Reviewed-by: Karol Latecki Reviewed-by: Jim Harris Reviewed-by: Tomasz Zawadzki --- scripts/qat_setup.sh | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) diff --git a/scripts/qat_setup.sh b/scripts/qat_setup.sh index fa3aa4b49..0b5ae4bc0 100755 --- a/scripts/qat_setup.sh +++ b/scripts/qat_setup.sh @@ -2,7 +2,6 @@ shopt -s nullglob rootdir=$(readlink -f $(dirname $0))/.. -igb_driverdir=$rootdir/dpdk/build-tmp/kernel/linux/igb_uio/ allowed_drivers=("igb_uio" "uio_pci_generic") reload_intel_qat() { @@ -50,8 +49,7 @@ reload_intel_qat() { modprobe -a intel_qat "${h[@]}" } -# This script requires an igb_uio kernel module binary located at $igb_driverdir/igb_uio.ko -# Please also note that this script is not intended to be comprehensive or production quality. +# Please note that this script is not intended to be comprehensive or production quality. # It supports configuring a single card (the Intel QAT 8970) for use with the SPDK bad_driver=true @@ -123,11 +121,9 @@ modprobe uio # Insert the dpdk uio kernel module. if [ $driver_to_bind == "igb_uio" ]; then - if ! lsmod | grep -q igb_uio; then - if ! insmod $igb_driverdir/igb_uio.ko; then - echo "Unable to insert the igb_uio kernel module. Aborting." - exit 1 - fi + if ! modprobe igb_uio; then + echo "Unable to insert the igb_uio kernel module. Aborting." + exit 1 fi elif [ "$driver_to_bind" == "uio_pci_generic" ]; then modprobe uio_pci_generic