Hello, I am trying to build sculpt for virt_qemu_riscv. As I could not find the "virt_qemu_riscv" directory inside genode. So I cloned the riscv inside repos under genode from " https://github.com/genodelabs/genode-riscv/". Earlier while executing the command: > make run/log BOARD=virt_qemu_riscv KERNEL=hw I got this error.:
genode build completed
using 'ld-hw.lib.so' as 'ld.lib.so'
core link address is 0xffffffc000000000
spawn qemu-system-riscv64 -nographic -serial mon:stdio -kernel var/run/log/boot/image.elf -m 512 -machine virt -cpu rv64,priv_spec=v1.10.0 -bios default -global virtio-mmio.force-legacy=false -device virtio-net-device,bus=virtio-mmio-bus.0,netdev=net0 -device virtio-mouse-device -device virtio-keyboard-device -device virtio-gpu-device -netdev user,id=net0
qemu-system-riscv64: Unable to load the RISC-V firmware "opensbi-riscv64-virt-fw_jump.bin"
Aborting, received EOF
Log step failed, retry.
I had raised this issue then and I would like to answer your questions.
- qemu-system-riscv64 --version QEMU emulator version 4.2.1 (Debian 1:4.2-3ubuntu6.24) Copyright (c) 2003-2019 Fabrice Bellard and the QEMU Project developers
I could not fix qemu so I downloaded the RISC-V firmware "opensbi-riscv64-virt-fw_jump.bin" and used it explicitly to run the elf file generated. I got this output
Platform Name : QEMU Virt Machine Platform HART Features : RV64ACDFIMSU Platform Max HARTs : 8 Current Hart : 0 Firmware Base : 0x80000000 Firmware Size : 120 KB Runtime SBI Version : 0.2
MIDELEG : 0x0000000000000222 MEDELEG : 0x000000000000b109 PMP0 : 0x0000000080000000-0x000000008001ffff (A) PMP1 : 0x0000000000000000-0xffffffffffffffff (A,R,W,X)
kernel initialized ROM modules: ROM: [00000000803ed000,00000000803ed156) config ROM: [00000000801d3000,00000000801d4000) core_log ROM: [000000008039b000,00000000803e5120) init ROM: [00000000802ff000,000000008039a920) ld.lib.so ROM: [0000000080146000,0000000080147000) platform_info ROM: [00000000803e6000,00000000803ec460) test-log
Genode 22.11-7-g83ac80460 <local changes> 507 MiB RAM and 64533 caps assigned to init [init -> test-log] hex range: [0e00,1680) [init -> test-log] empty hex range: [0abc0000,0abc0000) (empty!) [init -> test-log] hex range to limit: [f8,ff] [init -> test-log] invalid hex range: [f8,08) (overflow!) [init -> test-log] negative hex char: 0xfe [init -> test-log] positive hex char: 0x02 [init -> test-log] floating point: 1.70 [init -> test-log] multiarg string: "parent -> child.7" [init -> test-log] String(Hex(3)): 0x3 [init -> test-log] Very long messages: [init -> test-log -> log] 1.....................................................................................................................................................................................................................................2 [init -> test-log] 3.....................................................................................................................................................................................................................................4 [init -> test-log] 5.....................................................................................................................................................................................................................................6 [init -> test-log] [init -> test-log] Test done.
and, Qemu popped up with a text "*Guest has not initialized the display yet* ".
Please tell me if this is all what I should expect from 'make run/log' or if I have done something wrong ?
------------------------------------------------------------------------------------------------------
So, Now I am trying to build sculpt using:
make run/sculpt BOARD=virt_qemu_riscv KERNEL=hw
I have added the virt_qemu platform in sculpt.run file. I have added a driver configuration file under *'repos/gems/sculpt/drivers' and added a **default-virt_qemu_arm_riscv.sculpt file under 'repos/gems/sculpt'.*
I am getting this error:
including /home/pranab/MTP/r5/genode/tool/run/power_on/qemu including /home/pranab/MTP/r5/genode/tool/run/log/qemu including /home/pranab/MTP/r5/genode/tool/run/boot_dir/hw including /home/pranab/MTP/r5/genode/repos/gems/run/sculpt.run update depot: /home/pranab/MTP/r5/genode/tool/depot/create genodelabs/bin/riscv/base-hw-virt_qemu_riscv genodelabs/bin/riscv/event_filter genodelabs/bin/riscv/init genodelabs/bin/riscv/nitpicker genodelabs/bin/riscv/platform_drv genodelabs/bin/riscv/rom_reporter genodelabs/bin/riscv/virt_qemu_drivers genodelabs/bin/riscv/virtdev_rom genodelabs/bin/riscv/virtio_fb_drv genodelabs/bin/riscv/virtio_input_drv genodelabs/bin/riscv/virtio_nic_drv genodelabs/pkg/riscv/drivers_interactive-virt_riscv genodelabs/pkg/riscv/sculpt genodelabs/raw/drivers_interactive-virt_riscv CROSS_DEV_PREFIX=/usr/local/genode/tool/21.05/bin/genode-riscv- DEPOT_DIR=/home/pranab/MTP/r5/genode/depot UPDATE_VERSIONS=1 FORCE=1 REBUILD=
*make[1]: Entering directory '/home/pranab/MTP/r5/genode/build/riscv'Error: incomplete or missing recipe (genodelabs/pkg/drivers_interactive-virt_riscv genodelabs/raw/drivers_interactive-virt_riscv)make[2]: *** [/home/pranab/MTP/r5/genode/tool/depot/mk/extract_post_dependencies.inc:29: checked_versions_defined] Error 1make[1]: *** [/home/pranab/MTP/r5/genode/tool/depot/create:41: extract] Error 2make[1]: Leaving directory '/home/pranab/MTP/r5/genode/build/riscv'child process exited abnormally*
.
.
P.S. *- *The drivers_interactive package for this platform (riscv), is not in *'repos/os/recipes/raw/' .... *rather its present in* 'genode/repos/riscv/recipes/raw'.*
All recipes related to riscv was not with genode, I had to add it into *'genode/repos/' *from github.
Please let me know What I can configure to execute this command sucessfully.
Hi Pranab,
On 13.02.23 17:32, Pranab Kumar Rout cs21m045 wrote:
[init -> test-log] Test done.
and, Qemu popped up with a text "*Guest has not initialized the display yet*".
Please tell me if this is all what I should expect from 'make run/log' or if I have done something wrong ?
Yes, this can be considered a successful run of the log test. Why you had to download the firmware and run the image manually is out of my scope of knowledge.
P.S. /- /The drivers_interactive package for this platform (riscv), is not in /'repos/os/recipes/raw/' .... /rather its present in/'genode/repos/riscv/recipes/raw'./
On branch genodelabs/master the archives are located here:
repos/riscv/recipes/pkg/drivers_interactive-virt_qemu_riscv repos/riscv/recipes/raw/drivers_interactive-virt_qemu_riscv
I assume the problem is that your Sculpt configuration references the wrong recipe names (drivers_interactive-virt_riscv instead of drivers_interactive-virt_qemu_riscv).
All recipes related to riscv was not with genode, I had to add it into /'genode/repos/' /from github.
This is normal. the genodelabs repo contains only the basic OS framework. Other platforms like RISC-V have their own repository. In the end this is transparent to the build system because all repositories you select are seen like "combined" as a single source tree. You don't have to move stuff around from one repo to another!
I hope that helped?
Cheers, Martin