From 86ad46db553100a89daec614d7ee52a53cf7360d Mon Sep 17 00:00:00 2001 From: Michal Berger Date: Tue, 7 Jun 2022 14:17:58 +0200 Subject: [PATCH] autobuild: Put DPDK's kernel drivers at proper location This is the location freebsd_update_contigmem_mod() looks up to copy the modules into right /boot directories. Signed-off-by: Michal Berger Change-Id: Ic5919cc6382433c641c4c7a8b1100a50abfc246a Reviewed-on: https://review.spdk.io/gerrit/c/spdk/spdk/+/12925 Reviewed-by: Ben Walker Tested-by: SPDK CI Jenkins Reviewed-by: Jim Harris --- test/common/autobuild_common.sh | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/test/common/autobuild_common.sh b/test/common/autobuild_common.sh index df41b13f1..9733a5dc6 100755 --- a/test/common/autobuild_common.sh +++ b/test/common/autobuild_common.sh @@ -191,6 +191,15 @@ _build_native_dpdk() { ninja -C "$external_dpdk_base_dir/build-tmp" $MAKEFLAGS ninja -C "$external_dpdk_base_dir/build-tmp" $MAKEFLAGS install + if [[ $(uname -s) == "FreeBSD" ]]; then + # Make sure kernel modules are available for freebsd_update_contigmem_mod() to fetch + mapfile -t drivers < <(find "$external_dpdk_base_dir/build-tmp" -name '*.ko') + if ((${#drivers[@]} > 0)); then + mkdir -p "$external_dpdk_dir/kmod" + cp -f "${drivers[@]}" "$external_dpdk_dir/kmod/" + fi + fi + # Save this path. In tests are run using autorun.sh then autotest.sh # script will be unaware of LD_LIBRARY_PATH and will fail tests. echo "export LD_LIBRARY_PATH=$LD_LIBRARY_PATH" > /tmp/spdk-ld-path