sfence before enabling paging
This commit is contained in:
parent
29ce3161f8
commit
581bc4cbd1
|
@ -61,7 +61,12 @@ kvminit(void)
|
|||
void
|
||||
kvminithart()
|
||||
{
|
||||
// wait for any previous writes to the page table memory to finish.
|
||||
sfence_vma();
|
||||
|
||||
w_satp(MAKE_SATP(kernel_pagetable));
|
||||
|
||||
// flush stale entries from the TLB.
|
||||
sfence_vma();
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue