Skip to content

Add RISC-V semihosting 0.2. Finish ARM semihosting 2.0

Keith Packard qemu-arm qemu-devel qemu-riscv 1 version New

Get series with b4
b4 am [email protected]

Versions newest first

  1. v1 Latest9 patches 0 repliesNew

Patches in v1 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/9semihosting: Move ARM semihosting code to shared directoriesdefault-configs/devices/arm-softmmu.mak default-configs/targets/aarch64-linux-user.mak default-configs/targets/aarch64_be-linux-user.mak +8 more+11 -50 replies
2/9semihosting: Change common-semi API to be architecture-independenthw/semihosting/common-semi.c hw/semihosting/common-semi.h linux-user/aarch64/cpu_loop.c +4 more+59 -190 replies
3/9semihosting: Change internal common-semi interfaces to use CPUState *hw/semihosting/common-semi.c+187 -1640 replies
4/9semihosting: Support SYS_HEAPINFO when env->boot_info is not sethw/semihosting/common-semi.c+42 -10 replies
5/9riscv: Add semihosting supportdefault-configs/devices/riscv32-softmmu.mak default-configs/devices/riscv64-softmmu.mak default-configs/targets/riscv32-linux-user.mak +10 more+162 -120 replies
6/9riscv: Add semihosting support for user modelinux-user/riscv/cpu_loop.c+5 -00 replies
7/9semihosting: Implement SYS_ELAPSED and SYS_TICKFREQhw/semihosting/common-semi.c include/qemu/timer.h util/qemu-timer-common.c+22 -00 replies
8/9semihosting: Implement SYS_TMPNAMhw/semihosting/common-semi.c+19 -20 replies
9/9semihosting: Implement SYS_ISERRORhw/semihosting/common-semi.c+4 -00 replies

Reviews trailers per patch

4 of 9 patches have a Reviewed-by or Acked-by.

PatchAlistair FrancisKeith Packard
1/9R-b
2/9R-b
3/9R-b
4/9
5/9
6/9R-b
7/9
8/9
9/9

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.

Read the v1 thread

Cover letter [PATCH 0/9] Add RISC-V semihosting 0.2. Finish ARM semihosting 2.0

This series adds support for RISC-V Semihosting, version 0.2 as specified here:

https://github.com/riscv/riscv-semihosting-spec/releases/tag/0.2

This specification references the ARM semihosting release 2.0 as specified here:

	https://static.docs.arm.com/100863/0200/semihosting.pdf

That specification includes several semihosting calls which were not previously implemented. This series includes implementations for the remaining calls so that both RISC-V and ARM versions are now complete.

Tests for release 2.0 can be found in picolibc on the semihost-2.0-all branch:

https://github.com/picolibc/picolibc/tree/semihost-2.0-all

These tests uncovered a bug in the SYS_HEAPINFO implementation for ARM, which has been fixed in this series as well.

The series is structured as follows:

1. Move shared semihosting files
2. Change public common semihosting APIs
3. Change internal semihosting interfaces
4. Fix SYS_HEAPINFO crash on ARM
5-6. Add RISC-V semihosting implementation
7-9. Add missing semihosting operations from release 2.0