Date: Sat, 2 Jul 2011 23:34:47 +0000 (UTC) From: Alan Cox <alc@FreeBSD.org> To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org Subject: svn commit: r223729 - head/sys/vm Message-ID: <201107022334.p62NYlmc060082@svn.freebsd.org>
next in thread | raw e-mail | index | archive | help
Author: alc Date: Sat Jul 2 23:34:47 2011 New Revision: 223729 URL: http://svn.freebsd.org/changeset/base/223729 Log: Initialize marker pages as held rather than fictitious/wired. Marking the page as held is more useful as a safety precaution in case someone forgets to check for PG_MARKER. Reviewed by: kib Modified: head/sys/vm/vm_pageout.c Modified: head/sys/vm/vm_pageout.c ============================================================================== --- head/sys/vm/vm_pageout.c Sat Jul 2 20:58:33 2011 (r223728) +++ head/sys/vm/vm_pageout.c Sat Jul 2 23:34:47 2011 (r223729) @@ -216,15 +216,21 @@ static void vm_req_vmdaemon(int req); #endif static void vm_pageout_page_stats(void); +/* + * Initialize a dummy page for marking the caller's place in the specified + * paging queue. In principle, this function only needs to set the flag + * PG_MARKER. Nonetheless, it sets the flag VPO_BUSY and initializes the hold + * count to one as safety precautions. + */ static void vm_pageout_init_marker(vm_page_t marker, u_short queue) { bzero(marker, sizeof(*marker)); - marker->flags = PG_FICTITIOUS | PG_MARKER; + marker->flags = PG_MARKER; marker->oflags = VPO_BUSY; marker->queue = queue; - marker->wire_count = 1; + marker->hold_count = 1; } /*
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201107022334.p62NYlmc060082>