diff --git a/qemu/run-sbl.sh b/qemu/run-sbl.sh index 1925516..ae6c5d6 100755 --- a/qemu/run-sbl.sh +++ b/qemu/run-sbl.sh @@ -13,6 +13,13 @@ if [ ! -f "$IMG" ]; then exit 1 fi shift 2>/dev/null || true +# timeout для тестовых прогонов (0 = без ограничения) +T=${T:-15} +if [ "$T" != "0" ]; then + exec timeout "$T" "$QEMU" -M saimaa,sbl1="fw/img/patch/img0_${B}.elf",sblmain=0x802f63f \ + -m 512 -display none -monitor none -serial file:uart.log \ + -drive file="$IMG",if=sd,format=raw "$@" 2>&1 +fi exec "$QEMU" -M saimaa,sbl1="fw/img/patch/img0_${B}.elf",sblmain=0x802f63f \ -m 512 -display none -monitor none -serial file:uart.log \ -drive file="$IMG",if=sd,format=raw "$@" 2>&1