diff options
author | Deepak Gupta <debug@rivosinc.com> | 2024-10-08 15:49:54 -0700 |
---|---|---|
committer | Alistair Francis <alistair.francis@wdc.com> | 2024-10-30 11:22:08 +1000 |
commit | 53309be15619096b4ff2f05ec5e5d9b9bb6b6a82 (patch) | |
tree | 26059a7f829b82acee9d6e1a2bc67e71195e7f83 /rust/qemu-api-macros/src | |
parent | 4923f672e3d751cd8b7a10e32e09328c8f85ba1d (diff) | |
download | qemu-53309be15619096b4ff2f05ec5e5d9b9bb6b6a82.zip qemu-53309be15619096b4ff2f05ec5e5d9b9bb6b6a82.tar.gz qemu-53309be15619096b4ff2f05ec5e5d9b9bb6b6a82.tar.bz2 |
target/riscv: save and restore elp state on priv transitions
elp state is recorded in *status on trap entry (less privilege to higher
privilege) and restored in elp from *status on trap exit (higher to less
privilege).
Additionally this patch introduces a forward cfi helper function to
determine if current privilege has forward cfi is enabled or not based on
*envcfg (for U, VU, S, VU, HS) or mseccfg csr (for M).
Signed-off-by: Deepak Gupta <debug@rivosinc.com>
Co-developed-by: Jim Shu <jim.shu@sifive.com>
Co-developed-by: Andy Chiu <andy.chiu@sifive.com>
Reviewed-by: Richard Henderson <richard.henderson@linaro.org>
Reviewed-by: Alistair Francis <alistair.francis@wdc.com>
Message-ID: <20241008225010.1861630-5-debug@rivosinc.com>
Signed-off-by: Alistair Francis <alistair.francis@wdc.com>
Diffstat (limited to 'rust/qemu-api-macros/src')
0 files changed, 0 insertions, 0 deletions