Subject: Re: Single file system (buf) read size
To: Jason R Thorpe <>
From: =?iso-8859-1?Q?P=E5l_Halvorsen?= <>
List: tech-kern
Date: 03/15/2001 10:07:51
On Wed, 14 Mar 2001, Jason R Thorpe wrote:

> On Wed, Mar 14, 2001 at 06:29:03PM +0100, Manuel Bouyer wrote:
 > foominphys(). But it's only called for raw disk I/O I think. Block I/O
 > (especially filesystems) take another path, and are limited only by
 > the MAXPHYS constant.
>  > A yes. But for now MAXPHYS == MAXBSIZE.
>  > Not sure what would be the best. Keep MAXBSIZE as constant (enventually
>  > bump it a bit) and use min(MAXBSIZE,dev->maxphys), or drop MAXBSIZE
>  > and use only the underlying device's limit ?
> Eventually, I think we should be limited only by the device.  MAXBSIZE
> is really due to lameness in the traditional buffer cache design, and
> MAXPHYS is really just to put an upper-bound on resource usage (from what
> I can tell, anyhow...)

OK, I might have a problem getting read sizes larger than 64 KB, but
in my system (having created a zero-copy data path for streams), I
allocate my own buf structures with my own memory region. I do not use the
buffer cache - but an separate buffer manager carrying out the file system
functions. I "only" use 
	VOP_BMAP(vp, bp->b_lblkno, NULL, &bp->b_blkno, &num_ra);
to see the amount of data to read ahead and
to call the disk driver (SCSI) with my buf structure. 

In such a case, is it possible, without too much work - especially in the
driver code which I do not know much about, to get > 64 KB read