Skip to content

Commit

Permalink
ci: load kernel modules uio_pci_generic and nvme-tcp
Browse files Browse the repository at this point in the history
Longhorn 7672

Signed-off-by: Derek Su <[email protected]>
  • Loading branch information
derekbit committed Feb 26, 2024
1 parent 857eaf6 commit 87f6138
Showing 1 changed file with 11 additions and 0 deletions.
11 changes: 11 additions & 0 deletions scripts/test
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,17 @@ then
exit 1
fi

modules=(uio_pci_generic nvme-tcp)
for module in "${modules[@]}"
do
modprobe $module
if [ $? -ne 0 ]

Check notice on line 20 in scripts/test

View check run for this annotation

codefactor.io / CodeFactor

scripts/test#L20

Check exit code directly with e.g. 'if ! mycmd;', not indirectly with $?. (SC2181)
then
echo "Failed to load $module module"
exit 1
fi
done

mount --rbind /host/dev /dev
mount --rbind /host/sys /sys
trap "umount /dev && umount /sys" EXIT
Expand Down

0 comments on commit 87f6138

Please sign in to comment.