iscsi/iscsiroot.sh: handle firmware in online queue

otherwise it does not get called, if no netroot is set
Harald Hoyer 2015-08-25 11:14:38 +02:00
parent 35f40b75e4
commit 3bd3bbec31
1 changed files with 15 additions and 17 deletions

View File

@ -238,9 +238,15 @@ if [ "$netif" = "timeout" ] && all_ifaces_up; then
sleep 2 sleep 2
fi fi


# loop over all netroot parameter if [ "$netif" = "online" ]; then
netroot=$(getarg netroot) if getargbool 0 rd.iscsi.firmware -d -y iscsi_firmware ; then
if [ $? -eq 0 ] && [ "$netroot" != "dhcp" ]; then handle_firmware
ret=$?
fi
else
# loop over all netroot parameter
nroot=$(getarg netroot)
if [ $? -eq 0 ] && [ "$nroot" != "dhcp" ]; then
for nroot in $(getargs netroot); do for nroot in $(getargs netroot); do
[ "${nroot%%:*}" = "iscsi" ] || continue [ "${nroot%%:*}" = "iscsi" ] || continue
nroot="${nroot##iscsi:}" nroot="${nroot##iscsi:}"
@ -249,18 +255,10 @@ if [ $? -eq 0 ] && [ "$netroot" != "dhcp" ]; then
ret=$(($ret + $?)) ret=$(($ret + $?))
fi fi
done done
if getargbool 0 rd.iscsi.firmware -d -y iscsi_firmware ; then else
handle_firmware
ret=$(($ret + $?))
fi
else
if [ -n "$iroot" ]; then if [ -n "$iroot" ]; then
handle_netroot "$iroot" handle_netroot "$iroot"
ret=$? ret=$?
else
if getargbool 0 rd.iscsi.firmware -d -y iscsi_firmware ; then
handle_firmware
ret=$?
fi fi
fi fi
fi fi