aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorbehlendo <behlendo@7e1ea52c-4ff2-0310-8f11-9dd32ca42a1c>2008-08-12 05:18:41 +0000
committerbehlendo <behlendo@7e1ea52c-4ff2-0310-8f11-9dd32ca42a1c>2008-08-12 05:18:41 +0000
commite73187714d0a6b726d059e3aef426bc7a8efeea4 (patch)
treeb30629fe8caf8635d62d3032f1676cc98ecf2b26
parent25557fd8842deca017f8da05da22e1352389f736 (diff)
Minor tweak to handle systems with restrictive udev rules
or older systems which are not using udev at all. git-svn-id: https://outreach.scidac.gov/svn/spl/trunk@158 7e1ea52c-4ff2-0310-8f11-9dd32ca42a1c
-rwxr-xr-xscripts/check.sh16
1 files changed, 15 insertions, 1 deletions
diff --git a/scripts/check.sh b/scripts/check.sh
index 3029bf895..81f2fdde3 100755
--- a/scripts/check.sh
+++ b/scripts/check.sh
@@ -44,7 +44,21 @@ echo "Loading ${spl_module}"
echo "Loading ${splat_module}"
/sbin/insmod ${splat_module} || die "Unable to load ${splat_module}"
-while [ ! -c /dev/splatctl ]; do sleep 0.1; done
+# Wait a maximum of 3 seconds for udev to detect the new splatctl
+# device, if we do not see the character device file created assume
+# udev is not running and manually create the character device.
+for i in `seq 1 50`; do
+ sleep 0.1
+
+ if [ -c /dev/splatctl ]; then
+ break
+ fi
+
+ if [ $i -eq 50 ]; then
+ mknod /dev/splatctl c 229 0
+ fi
+done
+
$splat_cmd $tests $verbose
echo "Unloading ${splat_module}"