1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-22 11:17:19 +00:00

Don't allow pmap_change_attr() to be applied to the recursive mapping.

This commit is contained in:
Alan Cox 2008-07-28 04:59:48 +00:00
parent cc1ec88f72
commit b0c139d336
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=180872

View File

@ -4365,8 +4365,11 @@ pmap_change_attr(vm_offset_t va, vm_size_t size, int mode)
offset = va & PAGE_MASK;
size = roundup(offset + size, PAGE_SIZE);
/* Only supported on kernel virtual addresses. */
if (base <= VM_MAXUSER_ADDRESS)
/*
* Only supported on kernel virtual addresses, including the direct
* map but excluding the recursive map.
*/
if (base < DMAP_MIN_ADDRESS)
return (EINVAL);
/*