Module Name:    src
Committed By:   mlelstv
Date:           Sun Feb  7 15:51:29 UTC 2010

Modified Files:
        src/sys/uvm: uvm_swap.c

Log Message:
Use filesystem blocks to address filesystem objects. f_iosize just
happens to be the same for current filesystems.


To generate a diff of this commit:
cvs rdiff -u -r1.148 -r1.149 src/sys/uvm/uvm_swap.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_swap.c
diff -u src/sys/uvm/uvm_swap.c:1.148 src/sys/uvm/uvm_swap.c:1.149
--- src/sys/uvm/uvm_swap.c:1.148	Tue Feb  2 15:00:34 2010
+++ src/sys/uvm/uvm_swap.c	Sun Feb  7 15:51:28 2010
@@ -1,4 +1,4 @@
-/*	$NetBSD: uvm_swap.c,v 1.148 2010/02/02 15:00:34 wiz Exp $	*/
+/*	$NetBSD: uvm_swap.c,v 1.149 2010/02/07 15:51:28 mlelstv Exp $	*/
 
 /*
  * Copyright (c) 1995, 1996, 1997, 2009 Matthew R. Green
@@ -30,7 +30,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: uvm_swap.c,v 1.148 2010/02/02 15:00:34 wiz Exp $");
+__KERNEL_RCSID(0, "$NetBSD: uvm_swap.c,v 1.149 2010/02/07 15:51:28 mlelstv Exp $");
 
 #include "fs_nfs.h"
 #include "opt_uvmhist.h"
@@ -872,11 +872,7 @@
 		if ((error = VOP_GETATTR(vp, &va, l->l_cred)))
 			goto bad;
 		nblocks = (int)btodb(va.va_size);
-		if ((error =
-		     VFS_STATVFS(vp->v_mount, &vp->v_mount->mnt_stat)) != 0)
-			goto bad;
-
-		sdp->swd_bsize = vp->v_mount->mnt_stat.f_iosize;
+		sdp->swd_bsize = 1 << vp->v_mount->mnt_fs_bshift;
 		/*
 		 * limit the max # of outstanding I/O requests we issue
 		 * at any one time.   take it easy on NFS servers.

Reply via email to