Module Name:    src
Committed By:   uebayasi
Date:           Thu Feb 11 06:26:48 UTC 2010

Modified Files:
        src/sys/uvm [uebayasi-xip]: uvm_vnode.c

Log Message:
uvn_get: For XIP vnodes, skip read-ahead, because it's pointless.


To generate a diff of this commit:
cvs rdiff -u -r1.93 -r1.93.2.1 src/sys/uvm/uvm_vnode.c

Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.

Modified files:

Index: src/sys/uvm/uvm_vnode.c
diff -u src/sys/uvm/uvm_vnode.c:1.93 src/sys/uvm/uvm_vnode.c:1.93.2.1
--- src/sys/uvm/uvm_vnode.c:1.93	Fri Jan  8 11:35:12 2010
+++ src/sys/uvm/uvm_vnode.c	Thu Feb 11 06:26:47 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: uvm_vnode.c,v 1.93 2010/01/08 11:35:12 pooka Exp $	*/
+/*	$NetBSD: uvm_vnode.c,v 1.93.2.1 2010/02/11 06:26:47 uebayasi Exp $	*/
 
 /*
  * Copyright (c) 1997 Charles D. Cranor and Washington University.
@@ -50,7 +50,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uvm_vnode.c,v 1.93 2010/01/08 11:35:12 pooka Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uvm_vnode.c,v 1.93.2.1 2010/02/11 06:26:47 uebayasi Exp $");
 
 #include "opt_uvmhist.h"
 
@@ -177,11 +177,18 @@
 
 	UVMHIST_LOG(ubchist, "vp %p off 0x%x", vp, (int)offset, 0,0);
 
+#ifdef XIP
+	if ((vp->v_flag & VV_XIP) != 0)
+		goto uvn_get_ra_done;
+#endif
 	if ((access_type & VM_PROT_WRITE) == 0 && (flags & PGO_LOCKED) == 0) {
 		vn_ra_allocctx(vp);
 		uvm_ra_request(vp->v_ractx, advice, uobj, offset,
 		    *npagesp << PAGE_SHIFT);
 	}
+#ifdef XIP
+uvn_get_ra_done:
+#endif
 
 	error = VOP_GETPAGES(vp, offset, pps, npagesp, centeridx,
 			     access_type, advice, flags);

Reply via email to