From d1bb5c7512957b3bc4c1cf5956526182ddbfe254 Mon Sep 17 00:00:00 2001 From: David Harris Date: Tue, 21 Nov 2023 21:52:11 -0800 Subject: [PATCH] Imperas fix for satp modes supported --- linux/Makefile | 3 ++- sim/imperas.ic | 3 +++ 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/linux/Makefile b/linux/Makefile index 520c7cd44..a2cded5ea 100644 --- a/linux/Makefile +++ b/linux/Makefile @@ -39,6 +39,7 @@ Image: # source ../setup.sh; $(MAKE) disassemble install: + sudo rm -rf $(RISCV)/$(BUILDROOT) sudo mv $(BUILDROOT) $(RISCV)/$(BUILDROOT) # Temp rule for debugging @@ -62,10 +63,10 @@ $(RISCV): disassemble: + rm -rf $(BUILDROOT)/output/images/disassembly find $(BUILDROOT)/output/build/linux-* -maxdepth 1 -name "vmlinux" | xargs cp -t $(BUILDROOT)/output/images/ mkdir -p $(DIS) make -j $(OBJDUMPS) - make -j $(OBJDUMPS).addr $(DIS)/%.objdump: $(IMAGES)/%.elf riscv64-unknown-elf-objdump -DS $< >> $@ diff --git a/sim/imperas.ic b/sim/imperas.ic index 4106968ed..be6b7cca6 100644 --- a/sim/imperas.ic +++ b/sim/imperas.ic @@ -32,6 +32,9 @@ --override cpu/Svpbmt=T --override cpu/Svnapot_page_mask=65536 +# SV39 and SV48 supported +--override cpu/Sv_modes=768 + # clarify #--override refRoot/cpu/mtvec_sext=F