1
0
mirror of https://github.com/rcore-os/rCore.git synced 2024-11-22 08:06:17 +04:00

riscv: use -bios option for QEMU 4.1

And remove prebuilt OpenSBI for virt, since it's included in QEMU.
Ref: https://qemu.weilnetz.de/doc/qemu-doc.html#Deprecated-features B.1.15
This commit is contained in:
Runji Wang 2019-09-23 00:51:58 +08:00
parent 7d1a37a7bf
commit 915ef6f95e
5 changed files with 5 additions and 8 deletions

View File

@ -21,7 +21,7 @@ Supported architectures and boards:
* [Rust](https://www.rust-lang.org) toolchain * [Rust](https://www.rust-lang.org) toolchain
* Cargo tools: [cargo-xbuild](https://github.com/rust-osdev/cargo-xbuild), [cargo-binutils](https://github.com/rust-embedded/cargo-binutils) * Cargo tools: [cargo-xbuild](https://github.com/rust-osdev/cargo-xbuild), [cargo-binutils](https://github.com/rust-embedded/cargo-binutils)
* [QEMU](https://www.qemu.org) >= 3.1.0 * [QEMU](https://www.qemu.org) >= 4.1.0
* [musl-based GCC toolchains](https://musl.cc/) (only for building [user programs](https://github.com/rcore-os/rcore-user)) * [musl-based GCC toolchains](https://musl.cc/) (only for building [user programs](https://github.com/rcore-os/rcore-user))
Setup on Linux or macOS: Setup on Linux or macOS:

View File

@ -118,7 +118,7 @@ else ifeq ($(arch), riscv32)
qemu_opts += \ qemu_opts += \
-machine virt \ -machine virt \
-serial mon:stdio \ -serial mon:stdio \
-kernel ../tools/opensbi/virt_rv32.elf \ -bios default \
-device loader,addr=0x80400000,file=$(kernel_img) \ -device loader,addr=0x80400000,file=$(kernel_img) \
-drive file=$(USER_QCOW2),format=qcow2,id=sfs \ -drive file=$(USER_QCOW2),format=qcow2,id=sfs \
-device virtio-blk-device,drive=sfs \ -device virtio-blk-device,drive=sfs \
@ -133,13 +133,13 @@ ifeq ($(board), u540)
qemu_opts += \ qemu_opts += \
-machine virt \ -machine virt \
-serial mon:stdio \ -serial mon:stdio \
-kernel ../tools/opensbi/fu540.elf \ -bios ../tools/opensbi/fu540.elf \
-device loader,addr=0x80200000,file=$(kernel_img) -device loader,addr=0x80200000,file=$(kernel_img)
else else
qemu_opts += \ qemu_opts += \
-machine virt \ -machine virt \
-serial mon:stdio \ -serial mon:stdio \
-kernel ../tools/opensbi/virt_rv64.elf \ -bios default \
-device loader,addr=0x80200000,file=$(kernel_img) \ -device loader,addr=0x80200000,file=$(kernel_img) \
-drive file=$(USER_QCOW2),format=qcow2,id=sfs \ -drive file=$(USER_QCOW2),format=qcow2,id=sfs \
-device virtio-blk-device,drive=sfs \ -device virtio-blk-device,drive=sfs \

View File

@ -1,9 +1,6 @@
# OpenSBI # OpenSBI
These are binary release of OpenSBI v0.4. These are binary release of OpenSBI v0.3.
- virt_rv32.elf: opensbi-0.4-rv32-bin/platform/qemu/virt/firmware/fw_jump.elf
- virt_rv64.elf: opensbi-0.4-rv64-bin/platform/qemu/virt/firmware/fw_jump.elf
NOTE: The [official v0.3 release](https://github.com/riscv/opensbi/releases/tag/v0.3) has bug on serial interrupt. Also, Rocket-Chip based CPUs (including SiFive Unleashed) seem to have unintended behavior on NOTE: The [official v0.3 release](https://github.com/riscv/opensbi/releases/tag/v0.3) has bug on serial interrupt. Also, Rocket-Chip based CPUs (including SiFive Unleashed) seem to have unintended behavior on

Binary file not shown.

Binary file not shown.