x86_64: lock task address space while performing a demand page-map
This commit is contained in:
@@ -364,7 +364,12 @@ kern_status_t pmap_handle_fault(
|
|||||||
struct task *task = current_task();
|
struct task *task = current_task();
|
||||||
struct vm_region *space = task->t_address_space;
|
struct vm_region *space = task->t_address_space;
|
||||||
|
|
||||||
return vm_region_demand_map(space, fault_addr, flags);
|
unsigned long lock_flags;
|
||||||
|
vm_region_lock_irqsave(space, &lock_flags);
|
||||||
|
kern_status_t status = vm_region_demand_map(space, fault_addr, flags);
|
||||||
|
vm_region_unlock_irqrestore(space, lock_flags);
|
||||||
|
|
||||||
|
return status;
|
||||||
}
|
}
|
||||||
|
|
||||||
kern_status_t pmap_add(
|
kern_status_t pmap_add(
|
||||||
|
|||||||
Reference in New Issue
Block a user