MCPcopy Create free account
hub / github.com/F-Stack/f-stack / pmap_change_attr

Function pmap_change_attr

freebsd/amd64/amd64/pmap.c:9149–9159  ·  view source on GitHub ↗

* Changes the specified virtual address range's memory type to that given by * the parameter "mode". The specified virtual address range must be * completely contained within either the direct map or the kernel map. If * the virtual address range is contained within the kernel map, then the * memory type for each of the corresponding ranges of the direct map is also * changed. (The corresp

Source from the content-addressed store, hash-verified

9147 * virtual address range or the direct map.
9148 */
9149int
9150pmap_change_attr(vm_offset_t va, vm_size_t size, int mode)
9151{
9152 int error;
9153
9154 PMAP_LOCK(kernel_pmap);
9155 error = pmap_change_props_locked(va, size, PROT_NONE, mode,
9156 MAPDEV_FLUSHCACHE);
9157 PMAP_UNLOCK(kernel_pmap);
9158 return (error);
9159}
9160
9161/*
9162 * Changes the specified virtual address range's protections to those

Callers 3

pmap_initFunction · 0.70
pmap_page_set_memattrFunction · 0.70
pmap_large_mapFunction · 0.70

Calls 1

pmap_change_props_lockedFunction · 0.85

Tested by

no test coverage detected