Subject: Re: uvm & flushing
To: Bill Studenmund <firstname.lastname@example.org>
From: Chuck Silvers <email@example.com>
Date: 12/14/1999 16:35:42
On Fri, Dec 10, 1999 at 12:11:26PM -0800, Bill Studenmund wrote:
> On Thu, 9 Dec 1999, Chuck Silvers wrote:
> > On Wed, Dec 08, 1999 at 11:32:52AM -0800, Bill Studenmund wrote:
> > >
> > ok, so you're trying to detect the creation of dirty pages rather than
> > prevent it.
> Right. Though we're most interested in knowing if dirty pages have been
> created rather than noting when they are created. Not sure if this nit
> makes it easier. Something like a count of dirty pages would be fine.
the count of dirty pages is only possible if you know that no pages are
mapped. mapped pages can become dirty without the kernel being notified.
the concept doesn't really work very well.
> > unfortunately there's not a really good answer for this now. the best thing
> > I can think of is to synchronously flush all pages before starting the archive
> > and remember the mtime. then when the archive is done, do the flush again
> > and see if the mtime is different. if so, then some pages were dirty and
> > the archive copy is invalid.
> Actually, does the flushing use VOP_WRITE? If so, then things aren't too
> bad. If the synchronous flush will call VOP_WRITE (which invalidates the
> archiving), we just do that before we check to see if there were writes.
pre-UBC, flushing page-cache pages is done via VOP_WRITE(), yes.