HomeFreeBSD

vm_fault: Shoot down shared mappings in vm_fault_copy_entry()

Description

vm_fault: Shoot down shared mappings in vm_fault_copy_entry()

As in vm_fault_cow(), it's possible, albeit rare, for multiple vm_maps
to share a shadow object. When copying a page from a backing object
into the shadow, all mappings of the source page must therefore be
removed. Otherwise, future operations on the object tree may detect
that the source page is fully shadowed and thus can be freed.

Approved by: so
Security: FreeBSD-SA-22:11.vm
Reviewed by: alc, kib
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D35635

(cherry picked from commit 5c50e900ad779fccbf0a230bfb6a68a3e93ccf60)
(cherry picked from commit 3ea8c7ad90f75129c52a2b64213c5578af23dc8d)

Details

Provenance
markjAuthored on Jul 25 2022, 8:53 PM
Reviewer
alc
Differential Revision
Restricted Differential Revision
Parents
rG056ffc74a769: elf_note_prpsinfo: handle more failures from proc_getargv()
Branches
Unknown
Tags
Unknown