Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/tls-maxphys]: src/sys/ufs/ufs Use mnt_maxphys not MAXPHYS to limit the s...



details:   https://anonhg.NetBSD.org/src/rev/8abe2e1000a6
branches:  tls-maxphys
changeset: 852927:8abe2e1000a6
user:      bouyer <bouyer%NetBSD.org@localhost>
date:      Tue Oct 09 21:53:03 2012 +0000

description:
Use mnt_maxphys not MAXPHYS to limit the size of I/O to disk.
Now the read-ahead code does issue 512k requests to disk.

diffstat:

 sys/ufs/ufs/ufs_bmap.c |  8 ++++----
 1 files changed, 4 insertions(+), 4 deletions(-)

diffs (33 lines):

diff -r 8f4dee126886 -r 8abe2e1000a6 sys/ufs/ufs/ufs_bmap.c
--- a/sys/ufs/ufs/ufs_bmap.c    Tue Oct 09 21:37:47 2012 +0000
+++ b/sys/ufs/ufs/ufs_bmap.c    Tue Oct 09 21:53:03 2012 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: ufs_bmap.c,v 1.49 2011/03/06 17:08:39 bouyer Exp $     */
+/*     $NetBSD: ufs_bmap.c,v 1.49.14.1 2012/10/09 21:53:03 bouyer Exp $        */
 
 /*
  * Copyright (c) 1989, 1991, 1993
@@ -37,7 +37,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: ufs_bmap.c,v 1.49 2011/03/06 17:08:39 bouyer Exp $");
+__KERNEL_RCSID(0, "$NetBSD: ufs_bmap.c,v 1.49.14.1 2012/10/09 21:53:03 bouyer Exp $");
 
 #include <sys/param.h>
 #include <sys/systm.h>
@@ -138,12 +138,12 @@
        if (runp) {
                /*
                 * XXX
-                * If MAXBSIZE is the largest transfer the disks can handle,
+                * If mnt_maxphys is the largest transfer the disks can handle,
                 * we probably want maxrun to be 1 block less so that we
                 * don't create a block larger than the device can handle.
                 */
                *runp = 0;
-               maxrun = MAXPHYS / mp->mnt_stat.f_iosize - 1;
+               maxrun = mp->mnt_maxphys / mp->mnt_stat.f_iosize - 1;
        }
 
        if (bn >= 0 && bn < NDADDR) {



Home | Main Index | Thread Index | Old Index