Subject: Re: ubc and nfs file truncation
To: None <chuq@chuq.com>
From: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
List: tech-kern
Date: 08/09/2004 07:30:06
hi,

> the diff I've been working with is at
> 	ftp://ftp.netbsd.org/pub/NetBSD/misc/chs/diff.ubc-novp
> 
> the gist of the change is that instead of limiting the getpages request
> to the vnode's size, we ask for however many pages are left in the
> mapping window.  however, genfs_getpages() trims the request to the
> vnode's size (rounded to the fs block size) anyway, so the result
> should be the same.  testing hasn't revealed any problems so far.

i don't think that the result is the exactly same.
genfs_getpages doesn't trim the request with PGO_PASTEOF,
which is set by ubc_fault, and will allocate a few extra pages.
is it intended?

> does this solve the problem that you were looking at as well?

yes, maybe.  the problem can be workarounded in nfs code anyway,
as far as it doesn't panic. :-)

YAMAMOTO Takashi