diff options
| author | Mark Johnston <markj@FreeBSD.org> | 2026-03-31 13:37:43 +0000 |
|---|---|---|
| committer | Mark Johnston <markj@FreeBSD.org> | 2026-04-21 15:45:50 +0000 |
| commit | 979e645dd25e8b9df065ca2bf3059c269224fec6 (patch) | |
| tree | 5854bd1c7742189f318e5c9770d95a54ea091dfd /sys/vm/vm_map.h | |
| parent | 44077c07f19f5e60593dcd87f7c2c33ea7e5ca69 (diff) | |
pkru: Fix handling of 1GB largepage mappings
pmap_pkru_update_range() did not handle the case where a PDPE has PG_PS
set. More generally, the SET_PKRU and CLEAR_PKRU sysarch
implementations did not check whether the request covers a "boundary" vm
map entry. Fix this, add the missing PG_PS test, and add some tests.
Approved by: so
Security: FreeBSD-SA-26:11.amd64
Security: CVE-2026-6386
Reported by: Nicholas Carlini <npc@anthropic.com>
Reviewed by: kib, alc
Differential Revision: https://reviews.freebsd.org/D56184
Diffstat (limited to 'sys/vm/vm_map.h')
| -rw-r--r-- | sys/vm/vm_map.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/sys/vm/vm_map.h b/sys/vm/vm_map.h index 5d41f892e83d..66a787b0d2d8 100644 --- a/sys/vm/vm_map.h +++ b/sys/vm/vm_map.h @@ -471,6 +471,7 @@ vm_map_entry_read_succ(void *token, struct vm_map_entry *const clone, #endif /* ! _KERNEL */ #ifdef _KERNEL +bool vm_map_check_boundary(vm_map_t, vm_offset_t, vm_offset_t); boolean_t vm_map_check_protection (vm_map_t, vm_offset_t, vm_offset_t, vm_prot_t); int vm_map_delete(vm_map_t, vm_offset_t, vm_offset_t); int vm_map_find(vm_map_t, vm_object_t, vm_ooffset_t, vm_offset_t *, vm_size_t, |
