qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug 1898883] Re: qemu-system-riscv64 failed to load binary kernel into


From: Alistair Francis
Subject: [Bug 1898883] Re: qemu-system-riscv64 failed to load binary kernel into memory
Date: Tue, 27 Oct 2020 21:30:39 -0000

Just an update on this.

You can use -bios to load your image, which will load it to address
0x80000000.

In QEMU 5.1 `-bios none -kernel Image` will load the Image to
0x80020000/0x80040000 depending on XLEN.

QEMU 5.2 will now correctly load the above mentioned Image to address
0x80000000 if you don't load a firmware (`-bios none`).

-- 
You received this bug notification because you are a member of qemu-
devel-ml, which is subscribed to QEMU.
https://bugs.launchpad.net/bugs/1898883

Title:
  qemu-system-riscv64 failed to load binary kernel into memory

Status in QEMU:
  Invalid

Bug description:
  QEMU Version: 5.1.0
  Compiled in Ubuntu 20.04 for riscv64, following the guide 
https://risc-v-getting-started-guide.readthedocs.io/en/latest/linux-qemu.html.

  In qemu-system-riscv64, code at 0x80000000 will be executed by virtual CPU.
  For example, using `qemu-system-riscv64 -nographic -machine virt -bios none 
-kernel vmlinux -S -s`, my homebrew kernel(ELF file) will load at 0x80000000. 
If I strip the kernel using `riscv64-linux-gnu-objcopy -O binary vmlinux 
Image`, qemu-system-riscv64 will not load the binary machine code into the 
riscv64 load address, but `-bios Image` will.

  In `qemu-system-aarch64` compiled by Ubuntu team, I can use `qemu-
  system-aarch64 -M raspi3 -kernel Image_aarch64 -S -s` to load a
  specific machine code binary into 0x80000. And the elf kernel can be
  loaded to that address, too.

To manage notifications about this bug go to:
https://bugs.launchpad.net/qemu/+bug/1898883/+subscriptions



reply via email to

[Prev in Thread] Current Thread [Next in Thread]