summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthew Veety <mveety@gmail.com>2014-02-14 00:11:11 -0500
committerMatthew Veety <mveety@gmail.com>2014-02-14 00:11:11 -0500
commit3f9d92c1a83d6b0fdb49d3986ef5a4cd2a892a57 (patch)
tree0d32d311602c5e9592015646d7d4fe02a4c495a3
parent1d64be19849086dc1152ef952b1ab32612e2e94c (diff)
downloadplan9front-3f9d92c1a83d6b0fdb49d3986ef5a4cd2a892a57.tar.xz
similar to my last commit, but combined the two waits for the usb devices. still configurable, but with usbwait. If usbwait is not defined then it defaults to the original 2 seconds.
-rwxr-xr-xsys/src/9/boot/bootrc10
-rwxr-xr-xsys/src/9/boot/net.rc3
2 files changed, 7 insertions, 6 deletions
diff --git a/sys/src/9/boot/bootrc b/sys/src/9/boot/bootrc
index c9f2af30e..6af8046bb 100755
--- a/sys/src/9/boot/bootrc
+++ b/sys/src/9/boot/bootrc
@@ -58,8 +58,6 @@ fn ask {
}
mt=()
-. /rc/lib/net.rc
-. /rc/lib/local.rc
fn main{
mp=()
@@ -169,7 +167,13 @@ if(test -x /bin/nusbrc && ! test -e /env/nousbrc)
nusbrc
# wait for devices to settle down
-sleep 2
+if(~ $#usbwait 1)
+ sleep $usbwait
+if(~ $#usbwait 0)
+ sleep 2
+
+. /rc/lib/net.rc
+. /rc/lib/local.rc
# add partitions and binds
configlocal
diff --git a/sys/src/9/boot/net.rc b/sys/src/9/boot/net.rc
index 3809d6581..461564747 100755
--- a/sys/src/9/boot/net.rc
+++ b/sys/src/9/boot/net.rc
@@ -1,9 +1,6 @@
#!/bin/rc
fn confignet{
- if(~ $#netwait 1)
- sleep $netwait
-
must ip/ipconfig -p $*
if(~ $#fs 0)
fs=`{awk -F'=' '/fs=/{print $2; exit}' /net/ndb}