On Wed, Mar 24, 2010 at 06:41:38AM -0700, Chuck Silvers wrote:
> > > fix copy{in,out}{,str}() to return the error returned by uvm_fault().
> > > fixes PR 41813.
> >
> > Do you know if/how this will affect PR 11904? What happens now on EIO
> > in a memory-mapped file?
>
> this change doesn't affect application mappings, only kernel mappings.
> the user-mode equivalent of the kernel-mode pcb_onfault stuff is
> to install a signal handler for SIGSEGV, as you described in the PR.
Well... yes, but I guess I don't understand how the read() in the PR
would end up trapping in copyin/copyout. Presumably there's a uiomove
in there somewhere, but I would have thought it wouldn't reach it at
all if the I/O failed.
I suppose I ought to wade through genfs_getpages in more detail
sometime...
> hmm, there's an si_errno field in struct siginfo, but it looks like
> we currently only use it for emulations... we could put the errno
> returned from uvm_fault() in there too so that applications could
> print a more specific error message.
That would be handy for tail, indeed.
--
David A. Holland
[email protected]