Changeset View
Changeset View
Standalone View
Standalone View
sys/vm/vm_pageout.c
Show First 20 Lines • Show All 739 Lines • ▼ Show 20 Lines | recheck: | ||||
* chance. | * chance. | ||||
*/ | */ | ||||
if ((m->aflags & PGA_REQUEUE) != 0) { | if ((m->aflags & PGA_REQUEUE) != 0) { | ||||
vm_page_requeue(m); | vm_page_requeue(m); | ||||
continue; | continue; | ||||
} | } | ||||
/* | /* | ||||
* Held pages are essentially stuck in the queue. | |||||
* | |||||
* Wired pages may not be freed. Complete their removal | * Wired pages may not be freed. Complete their removal | ||||
* from the queue now to avoid needless revisits during | * from the queue now to avoid needless revisits during | ||||
* future scans. | * future scans. | ||||
*/ | */ | ||||
if (m->hold_count != 0) | |||||
continue; | |||||
if (m->wire_count != 0) { | if (m->wire_count != 0) { | ||||
vm_page_dequeue_deferred(m); | vm_page_dequeue_deferred(m); | ||||
continue; | continue; | ||||
} | } | ||||
if (object != m->object) { | if (object != m->object) { | ||||
if (object != NULL) | if (object != NULL) | ||||
VM_OBJECT_WUNLOCK(object); | VM_OBJECT_WUNLOCK(object); | ||||
▲ Show 20 Lines • Show All 650 Lines • ▼ Show 20 Lines | recheck: | ||||
* dropped, or a requeue was requested. This page gets a second | * dropped, or a requeue was requested. This page gets a second | ||||
* chance. | * chance. | ||||
*/ | */ | ||||
if ((m->aflags & (PGA_ENQUEUED | PGA_REQUEUE | | if ((m->aflags & (PGA_ENQUEUED | PGA_REQUEUE | | ||||
PGA_REQUEUE_HEAD)) != 0) | PGA_REQUEUE_HEAD)) != 0) | ||||
goto reinsert; | goto reinsert; | ||||
/* | /* | ||||
* Held pages are essentially stuck in the queue. So, | |||||
* they ought to be discounted from the inactive count. | |||||
* See the description of addl_page_shortage above. | |||||
* | |||||
* Wired pages may not be freed. Complete their removal | * Wired pages may not be freed. Complete their removal | ||||
* from the queue now to avoid needless revisits during | * from the queue now to avoid needless revisits during | ||||
* future scans. | * future scans. | ||||
*/ | */ | ||||
if (m->hold_count != 0) { | |||||
addl_page_shortage++; | |||||
goto reinsert; | |||||
} | |||||
if (m->wire_count != 0) { | if (m->wire_count != 0) { | ||||
vm_page_dequeue_deferred(m); | vm_page_dequeue_deferred(m); | ||||
continue; | continue; | ||||
} | } | ||||
if (object != m->object) { | if (object != m->object) { | ||||
if (object != NULL) | if (object != NULL) | ||||
VM_OBJECT_WUNLOCK(object); | VM_OBJECT_WUNLOCK(object); | ||||
▲ Show 20 Lines • Show All 671 Lines • Show Last 20 Lines |