hw/char: riscv_htif: Support console output via proxy syscall
commita6e13e31d5c34d59c28e908f3e51cf87bc82666f
authorBin Meng <bmeng@tinylab.org>
Thu, 29 Dec 2022 09:18:23 +0000 (29 17:18 +0800)
committerAlistair Francis <alistair.francis@wdc.com>
Fri, 20 Jan 2023 00:14:13 +0000 (20 10:14 +1000)
tree0a255972735c54ee6860f45d4d82c8ebffcb4277
parent03ef1899dd1194d58d51f41491ba24c87f901264
hw/char: riscv_htif: Support console output via proxy syscall

At present the HTIF proxy syscall is unsupported. On RV32, only
device 0 is supported so there is no console device for RV32.
The only way to implement console funtionality on RV32 is to
support the SYS_WRITE syscall.

With this commit, the Spike machine is able to boot the 32-bit
OpenSBI generic image.

Signed-off-by: Bin Meng <bmeng@tinylab.org>
Reviewed-by: Daniel Henrique Barboza <dbarboza@ventanamicro.com>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-Id: <20221229091828.1945072-8-bmeng@tinylab.org>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
hw/char/riscv_htif.c