mirror of
https://github.com/riscv-software-src/opensbi.git
synced 2025-08-24 23:41:23 +01:00

The privileged spec specifies that on a trap to HS-mode, hstatus.GVA should be set to 1 if stval is written with a guest virtual address, and to 0 otherwise. Implement this by setting hstatus.GVA to trap->gva when redirecting traps to HS-mode. Signed-off-by: Vivian Wang <dramforever@live.com> Reviewed-by: Andrew Jones <ajones@ventanamicro.com> Reviewed-by: Anup Patel <anup@brainfault.org>