diff options
| author | Christian Krinitsin <mail@krinitsin.com> | 2025-05-30 14:51:13 +0000 |
|---|---|---|
| committer | Christian Krinitsin <mail@krinitsin.com> | 2025-05-30 14:51:13 +0000 |
| commit | 225caa38269323af1bfc2daadff5ec8bd930747f (patch) | |
| tree | e0a5fefde9ee100ba6f32fb36de6707490e4164e /mailinglist/output_launchpad/1898883 | |
| parent | 904141bfb8d5385b75eb3b7afec1dcda89af65a7 (diff) | |
| download | emulator-bug-study-225caa38269323af1bfc2daadff5ec8bd930747f.tar.gz emulator-bug-study-225caa38269323af1bfc2daadff5ec8bd930747f.zip | |
add mailinglist scraper results
Diffstat (limited to 'mailinglist/output_launchpad/1898883')
| -rw-r--r-- | mailinglist/output_launchpad/1898883 | 48 |
1 files changed, 48 insertions, 0 deletions
diff --git a/mailinglist/output_launchpad/1898883 b/mailinglist/output_launchpad/1898883 new file mode 100644 index 00000000..04592afd --- /dev/null +++ b/mailinglist/output_launchpad/1898883 @@ -0,0 +1,48 @@ +qemu-system-riscv64 failed to load binary kernel into memory + +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. + +On Wed, Oct 7, 2020 at 10:37 PM Azuk 443 <email address hidden> wrote: +> +> Public bug reported: +> +> 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. + +This is not a bug. As you said, please use `-bios Image` for your +special purpose. + +> +> 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. +> +> ** Affects: qemu +> Importance: Undecided +> Status: New +> + +Regards, +Bin + + +As per Bin Meng, closing as not-a-bug. + +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`). + |
