HomeFreeBSD

amd64: fix PKRU and swapout interaction

Description

amd64: fix PKRU and swapout interaction

When vm_map_remove() is called from vm_swapout_map_deactivate_pages()
due to swapout, PKRU attributes for the removed range must be kept
intact. Provide a variant of pmap_remove(), pmap_map_delete(), to
allow pmap to distinguish between real removes of the UVA mappings
and any other internal removes, e.g. swapout.

For non-amd64, pmap_map_delete() is stubbed by define to pmap_remove().

Reported by: andrew
Reviewed by: markj
Sponsored by: The FreeBSD Foundation
MFC after: 1 week
Differential revision: https://reviews.freebsd.org/D39556

Details

Provenance
kibAuthored on Apr 13 2023, 11:37 AM
Reviewer
markj
Differential Revision
D39556: amd64: fix PKRU and swapout interaction
Parents
rG485f783f882e: limits_test: validate CPU time used, not real time
Branches
Unknown
Tags
Unknown