diff options
Diffstat (limited to 'core/rootfs/rootfs-stage31/data/inc/network.functions')
-rw-r--r-- | core/rootfs/rootfs-stage31/data/inc/network.functions | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/core/rootfs/rootfs-stage31/data/inc/network.functions b/core/rootfs/rootfs-stage31/data/inc/network.functions index 94957be2..853c0cb3 100644 --- a/core/rootfs/rootfs-stage31/data/inc/network.functions +++ b/core/rootfs/rootfs-stage31/data/inc/network.functions @@ -2,9 +2,11 @@ wait_for_iface() { local DEVICE=$1 - local TIMEOUT="$(( "$2" * 2 ))" + local TIMEOUT=10 local state laststate - echo -n "Waiting for interface $DEVICE: " + [ -n "$2" ] && TIMEOUT="$2" + echo -n "Waiting ${TIMEOUT}s for interface $DEVICE: " + TIMEOUT="$(( TIMEOUT * 2 ))" # Some systems don't have operstate. Seems to be hardware dependent [ -e "/sys/class/net/${DEVICE}/operstate" ] || sleep 1 if [ -e "/sys/class/net/${DEVICE}/operstate" ]; then |