HomeFreeBSD

Fix handling of KVA in kmem_bootstrap_free().

Description

Fix handling of KVA in kmem_bootstrap_free().

Do not use vm_map_remove() to release KVA back to the system. Because
kernel map entries do not have an associated VM object, with r336030
the vm_map_remove() call will not update the kernel page tables. Avoid
relying on the vm_map layer and instead update the pmap and release KVA
to the kernel arena directly in kmem_bootstrap_free().

Because the pmap updates will generally result in superpage demotions,
modify pmap_init() to insert PTPs shadowed by superpage mappings into
the kernel pmap's radix tree.

While here, port r329171 to i386.

Reported by: alc
Reviewed by: alc, kib
X-MFC with: r336505
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D16426

Details

Provenance
markjAuthored on Jul 27 2018, 3:46 PM
Parents
rG45ed991d964f: On amd64, enable workarounds for several Ryzen erratas as described in
Branches
Unknown
Tags
Unknown

Event Timeline