Commit c3b5ef9c authored by Benoit Rat's avatar Benoit Rat

scripts: force to dash interpreter

Also correct bad error message when removing kernel modules
parent 6ee2da49
#!/bin/sh
#!/bin/dash
## Script to ease the installation of gateware HDL when using
## the starting kit
##
......@@ -118,6 +118,7 @@ checkdrv()
{
echo ""
echo "Checking the drivers"
for mod in "fmc" "spec" "wr-nic"; do
if [ -s /lib/modules/$(uname -r)/extra/${mod}.ko ]; then
echo "${mod}.ko found!"
......@@ -186,9 +187,8 @@ weeprom()
removemod()
{
for mod in "wr-nic" "spec" "fmc"; do
lsmod | grep ${mod} &> /dev/null
if [ "x$?" = "x0" ]; then
echo "Removing ${mod}"
if ( lsmod | grep ${mod} > /dev/null ); then
echo "Removing ${mod} kernel module..."
sudo rmmod ${mod}
fi
done
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment