[kvm-unit-tests PATCH v2 01/11] riscv: sbi: Drop fwft upper bits test
Clément Léger
cleger at rivosinc.com
Thu Feb 27 06:21:13 PST 2025
On 27/02/2025 15:19, Andrew Jones wrote:
> The test should be checking for SBI_SUCCESS and that the behavior of
> feature = BIT(32) is the same as feature = 0 (MISALIGNED_EXC_DELEG).
> However, enabling MISALIGNED_EXC_DELEG doesn't always lead to traps
> in S-mode (the platform may support misaligned accesses and not
> trap at all). Drop this upper bits of feature ID test for now.
> We'll add it back with another feature that has a deterministic
> behavior (such as with the ADUE feature).
>
> Signed-off-by: Andrew Jones <andrew.jones at linux.dev>
> ---
> riscv/sbi-fwft.c | 15 ---------------
> 1 file changed, 15 deletions(-)
>
> diff --git a/riscv/sbi-fwft.c b/riscv/sbi-fwft.c
> index f73ae52e7397..f3408d8de081 100644
> --- a/riscv/sbi-fwft.c
> +++ b/riscv/sbi-fwft.c
> @@ -57,21 +57,6 @@ static void fwft_check_base(void)
> fwft_check_reserved(SBI_FWFT_GLOBAL_RESERVED_START);
> fwft_check_reserved(SBI_FWFT_GLOBAL_RESERVED_END);
>
> -#if __riscv_xlen > 32
> - /* Check id > 32 bits */
> - {
> - struct sbiret ret;
> -
> - ret = fwft_get_raw(BIT(32));
> - sbiret_report_error(&ret, SBI_ERR_INVALID_PARAM,
> - "get feature with bit 32 set error");
> -
> - ret = fwft_set_raw(BIT(32), 0, 0);
> - sbiret_report_error(&ret, SBI_ERR_INVALID_PARAM,
> - "set feature with bit 32 set error");
> - }
> -#endif
> -
> report_prefix_pop();
> }
>
Hi Andrew,
Looks good to me.
Reviewed-by: Clément Léger <cleger at rivosinc.com>
Thanks,
Clément
More information about the kvm-riscv
mailing list