Date: Wed, 24 Jun 2020 15:21:12 +0000 (UTC) From: Mitchell Horne <mhorne@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r362584 - head/sys/riscv/riscv Message-ID: <202006241521.05OFLCPT096813@repo.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: mhorne Date: Wed Jun 24 15:21:12 2020 New Revision: 362584 URL: https://svnweb.freebsd.org/changeset/base/362584 Log: Only invalidate the early DTB mapping if it exists This temporary mapping will become optional. Booting via loader(8) means that the DTB will have already been copied into the kernel's staging area, and is therefore covered by the early KVA mappings. Reviewed by: markj Differential Revision: https://reviews.freebsd.org/D24911 Modified: head/sys/riscv/riscv/pmap.c Modified: head/sys/riscv/riscv/pmap.c ============================================================================== --- head/sys/riscv/riscv/pmap.c Wed Jun 24 15:20:00 2020 (r362583) +++ head/sys/riscv/riscv/pmap.c Wed Jun 24 15:21:12 2020 (r362584) @@ -619,8 +619,8 @@ pmap_bootstrap(vm_offset_t l1pt, vm_paddr_t kernstart, * possibility of an aliased mapping in the future. */ l2p = pmap_l2(kernel_pmap, VM_EARLY_DTB_ADDRESS); - KASSERT((pmap_load(l2p) & PTE_V) != 0, ("dtpb not mapped")); - pmap_clear(l2p); + if ((pmap_load(l2p) & PTE_V) != 0) + pmap_clear(l2p); sfence_vma();
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202006241521.05OFLCPT096813>