[PATCH] RISC-V: Fix SBI remote HFENCE function ids

3 views
Skip to first unread message

Anup Patel

unread,
Mar 21, 2021, 11:43:44 PM3/21/21
to xvisor...@googlegroups.com, Anup Patel
The SBI remote HFENCE function ids are not matching the SBI v0.2
specification. This has been fixed in OpenSBI and Linux so let's
fix it in Xvisor RISC-V as well.

Signed-off-by: Anup Patel <an...@brainfault.org>
---
arch/riscv/cpu/generic/include/riscv_sbi.h | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/arch/riscv/cpu/generic/include/riscv_sbi.h b/arch/riscv/cpu/generic/include/riscv_sbi.h
index 7dca352a..59ff295a 100644
--- a/arch/riscv/cpu/generic/include/riscv_sbi.h
+++ b/arch/riscv/cpu/generic/include/riscv_sbi.h
@@ -62,10 +62,10 @@
#define SBI_EXT_RFENCE_REMOTE_FENCE_I 0x0
#define SBI_EXT_RFENCE_REMOTE_SFENCE_VMA 0x1
#define SBI_EXT_RFENCE_REMOTE_SFENCE_VMA_ASID 0x2
-#define SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA 0x3
-#define SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID 0x4
-#define SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA 0x5
-#define SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID 0x6
+#define SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA_VMID 0x3
+#define SBI_EXT_RFENCE_REMOTE_HFENCE_GVMA 0x4
+#define SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA_ASID 0x5
+#define SBI_EXT_RFENCE_REMOTE_HFENCE_VVMA 0x6

/* SBI function IDs for HSM extension */
#define SBI_EXT_HSM_HART_START 0x0
--
2.25.1

Anup Patel

unread,
Mar 29, 2021, 8:39:24 AM3/29/21
to Xvisor Devel
On Mon, Mar 22, 2021 at 9:13 AM Anup Patel <an...@brainfault.org> wrote:
>
> The SBI remote HFENCE function ids are not matching the SBI v0.2
> specification. This has been fixed in OpenSBI and Linux so let's
> fix it in Xvisor RISC-V as well.
>
> Signed-off-by: Anup Patel <an...@brainfault.org>

Applied this patch to the xvisor-next repo

Regards,
Anup
Reply all
Reply to author
Forward
0 new messages