diff options
Diffstat (limited to 'sys/vm/vm_map.c')
-rw-r--r-- | sys/vm/vm_map.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/sys/vm/vm_map.c b/sys/vm/vm_map.c index 5cb8f98..fb690e9 100644 --- a/sys/vm/vm_map.c +++ b/sys/vm/vm_map.c @@ -938,8 +938,6 @@ vm_map_simplify_entry(vm_map_t map, vm_map_entry_t entry) vm_map_entry_t next, prev; vm_size_t prevsize, esize; - GIANT_REQUIRED; - if (entry->eflags & MAP_ENTRY_IS_SUB_MAP) return; @@ -1187,7 +1185,6 @@ vm_map_protect(vm_map_t map, vm_offset_t start, vm_offset_t end, vm_map_entry_t current; vm_map_entry_t entry; - GIANT_REQUIRED; vm_map_lock(map); VM_MAP_RANGE_CHECK(map, start, end); @@ -1237,12 +1234,14 @@ vm_map_protect(vm_map_t map, vm_offset_t start, vm_offset_t end, * here -- CHECK THIS XXX */ if (current->protection != old_prot) { + mtx_lock(&Giant); #define MASK(entry) (((entry)->eflags & MAP_ENTRY_COW) ? ~VM_PROT_WRITE : \ VM_PROT_ALL) pmap_protect(map->pmap, current->start, current->end, current->protection & MASK(current)); #undef MASK + mtx_unlock(&Giant); } vm_map_simplify_entry(map, current); current = current->next; |