Page MenuHomeFreeBSD

D34271.diff
No OneTemporary

D34271.diff

diff --git a/sys/riscv/include/cpufunc.h b/sys/riscv/include/cpufunc.h
--- a/sys/riscv/include/cpufunc.h
+++ b/sys/riscv/include/cpufunc.h
@@ -120,13 +120,6 @@
#define cpu_icache_sync_range(a, s)
#define cpu_icache_sync_range_checked(a, s)
-static __inline void
-load_satp(uint64_t val)
-{
-
- __asm __volatile("csrw satp, %0" :: "r"(val));
-}
-
#define cpufunc_nullop() riscv_nullop()
void riscv_nullop(void);
diff --git a/sys/riscv/riscv/pmap.c b/sys/riscv/riscv/pmap.c
--- a/sys/riscv/riscv/pmap.c
+++ b/sys/riscv/riscv/pmap.c
@@ -4402,7 +4402,7 @@
pmap = vmspace_pmap(td->td_proc->p_vmspace);
if (pmap == oldpmap)
return;
- load_satp(pmap->pm_satp);
+ csr_write(satp, pmap->pm_satp);
hart = PCPU_GET(hart);
#ifdef SMP

File Metadata

Mime Type
text/plain
Expires
Wed, Sep 25, 8:25 PM (22 h, 43 s)
Storage Engine
blob
Storage Format
Raw Data
Storage Handle
12789152
Default Alt Text
D34271.diff (744 B)

Event Timeline