Lines 263-268
vm_fault(vm_map_t map, vm_offset_t vaddr, vm_prot_t fault_type,
Link Here
|
263 |
int result; |
263 |
int result; |
264 |
|
264 |
|
265 |
td = curthread; |
265 |
td = curthread; |
|
|
266 |
if ((td->td_pflags & TDP_NOFAULTING) != 0) printf("pid %d kpf 1\n", curproc->p_pid); |
266 |
if ((td->td_pflags & TDP_NOFAULTING) != 0) |
267 |
if ((td->td_pflags & TDP_NOFAULTING) != 0) |
267 |
return (KERN_PROTECTION_FAILURE); |
268 |
return (KERN_PROTECTION_FAILURE); |
268 |
#ifdef KTRACE |
269 |
#ifdef KTRACE |
Lines 425-430
fast_failed:
Link Here
|
425 |
*/ |
426 |
*/ |
426 |
if (fs.object->flags & OBJ_DEAD) { |
427 |
if (fs.object->flags & OBJ_DEAD) { |
427 |
unlock_and_deallocate(&fs); |
428 |
unlock_and_deallocate(&fs); |
|
|
429 |
printf("pid %d kpf 2\n", curproc->p_pid); |
428 |
return (KERN_PROTECTION_FAILURE); |
430 |
return (KERN_PROTECTION_FAILURE); |
429 |
} |
431 |
} |
430 |
|
432 |
|
Lines 506-511
fast_failed:
Link Here
|
506 |
fs.object == fs.first_object) { |
508 |
fs.object == fs.first_object) { |
507 |
if (fs.pindex >= fs.object->size) { |
509 |
if (fs.pindex >= fs.object->size) { |
508 |
unlock_and_deallocate(&fs); |
510 |
unlock_and_deallocate(&fs); |
|
|
511 |
printf("pid %d kpf 3 %jd %jd\n", curproc->p_pid, (uintmax_t)fs.pindex, (uintmax_t)fs.object->size); |
509 |
return (KERN_PROTECTION_FAILURE); |
512 |
return (KERN_PROTECTION_FAILURE); |
510 |
} |
513 |
} |
511 |
|
514 |
|
Lines 698-703
vnode_locked:
Link Here
|
698 |
vm_page_unlock(fs.m); |
701 |
vm_page_unlock(fs.m); |
699 |
fs.m = NULL; |
702 |
fs.m = NULL; |
700 |
unlock_and_deallocate(&fs); |
703 |
unlock_and_deallocate(&fs); |
|
|
704 |
if (rv != VM_PAGER_ERROR) printf("pid %d kpf 4\n", curproc->p_pid); |
701 |
return ((rv == VM_PAGER_ERROR) ? KERN_FAILURE : KERN_PROTECTION_FAILURE); |
705 |
return ((rv == VM_PAGER_ERROR) ? KERN_FAILURE : KERN_PROTECTION_FAILURE); |
702 |
} |
706 |
} |
703 |
if (fs.object != fs.first_object) { |
707 |
if (fs.object != fs.first_object) { |