From 4c6be9cb63ff66ce49a6f733c1e00d1889f2c95f Mon Sep 17 00:00:00 2001 From: Kimplul Date: Sun, 10 Apr 2022 20:37:51 +0300 Subject: add basic ubsan and fix issues reported by it --- arch/riscv64/config.h | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'arch') diff --git a/arch/riscv64/config.h b/arch/riscv64/config.h index 707c0b9..957f848 100644 --- a/arch/riscv64/config.h +++ b/arch/riscv64/config.h @@ -17,12 +17,12 @@ #define VM_DMAP (0xffffffc000000000) /* testing for now */ #define VM_KERN (VM_DMAP + SZ_256K) #define TMP_PTE (-SZ_2G) -#define ROOT_PTE (0) +#define ROOT_PTE (0UL) #define ROOT_REGION (SZ_4K) -#define IO_PAGE 511 -#define KSTART_PAGE 256 -#define CSTACK_PAGE 255 +#define IO_PAGE 511UL +#define KSTART_PAGE 256UL +#define CSTACK_PAGE 255UL /* assume Sv39, probably wouldn't be too difficult to use runtime parameters * instead. First 4K is reserved for NULL, but I suppose it could be mapped -- cgit v1.3