Subject: Re: time traveling with physio
To: Stephan Uphoff <ups@stups.com>
From: Chuck Silvers <chuq@chuq.com>
List: tech-kern
Date: 07/20/2003 08:36:08
hi,

hmm, yea, that part of the pmap_enter() interface is currently optional.
so we can either make it mandatory (which is what I'd prefer), or change
the callers to explicitly clear PG_CLEAN when the flags to pmap_enter()
include VM_PROT_WRITE.

-Chuck


On Mon, Jul 14, 2003 at 11:56:57AM -0400, Stephan Uphoff wrote:
> > the bit that should handle this is where uvm_fault() calls pmap_enter()
> > with access_type that includes VM_PROT_WRITE in the case of writable
> > wiring faults.  pmap_enter() is supposed to force the page to be
> > marked dirty in this case.  is there a bug in there somewhere?
> > 
> > -Chuck
> 
> The i386 pmap_enter() does not force the page to be marked dirty.
> 
> 	Stephan
> 
> > 
> > 
> > On Fri, Jul 11, 2003 at 02:52:26PM -0400, Stephan Uphoff wrote:
> > > 
> > > Read operations from devices using physio will not cause
> > > pages associated with the buffer to be marked dirty.
> > > Because of this changed state (data read from the device) can get 
> > > lost later.
> > > Fortunately data loss will not happen with anonymous memory as wiring releases
> > > any swap space owned by an anonymous page. (physio wires the pages)
> > > This can however cause problems for programs using device reads into
> > > mmaped files.
> > > 
> > > 
> > > 	Stephan
> > > 
> > 
>