Some UPL images such as EDK2 may change into 64-bit mode after starting.
Avoid a crash by always using the 64-bit machine QEMU. This seems to
have no ill effects for 32-bit code.

Signed-off-by: Simon Glass <s...@chromium.org>
---

 scripts/build-qemu.sh | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/scripts/build-qemu.sh b/scripts/build-qemu.sh
index f9ee0072573..10ea99982d2 100755
--- a/scripts/build-qemu.sh
+++ b/scripts/build-qemu.sh
@@ -176,7 +176,8 @@ arm)
 x86)
        BOARD="qemu-x86"
        BIOS="u-boot.rom"
-       qemu=qemu-system-i386
+       # Use 64-bit version to allow UPL to change to 64-bit mode later
+       qemu=qemu-system-x86_64
        suffix="i386"
        if [[ "${bitness}" == "64" ]]; then
                BOARD="qemu-x86_64"
-- 
2.43.0

Reply via email to