Subject: Re: ubc and nfs file truncation
To: YAMAMOTO Takashi <yamt@mwd.biglobe.ne.jp>
From: Chuck Silvers <chuq@chuq.com>
List: tech-kern
Date: 12/13/2004 05:55:53
On Sat, Dec 11, 2004 at 12:35:27PM +0900, YAMAMOTO Takashi wrote:
> 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?
>
> how about the attached diff? (after diff.ubc-novp)
yea, that looks good, I incorporated that in my tree. the remaining issue
after that is to bring back the optional unmap in ubc_release() to avoid
hosing the PMAP_CACHE_VIVT platforms. there's a new diff at
ftp://ftp.netbsd.org/pub/NetBSD/misc/chs/diff.ubc-novp.4
do you see anything else that it needs? (besides putting the new flag into
a manpage.)
-Chuck