Re: writepage return value check in vmscan.c

Andrew Morton (akpm@digeo.com)
Thu, 24 Oct 2002 09:12:16 -0700


Andrea Arcangeli wrote:
>
> On Thu, Oct 24, 2002 at 10:15:06AM +0100, Alan Cox wrote:
> > On Thu, 2002-10-24 at 09:36, Andrew Morton wrote:
> > > A few fixes have been discussed. One way would be to allocate
> > > the space for the page when it is first faulted into reality and
> > > deliver SIGBUS if backing store for it could not be allocated.
> >
> > You still have to handle the situation where the page goes walkies and
> > you get ENOSPC or any other ERANDOMSUPRISE from things like NFS. SIGBUS
> > appears the right thing to do.
>
> I would tend to agree SIGBUS could be the right thing to do since the
> other (current) option is silent data corruption.
>

Or at least remember the data loss within the mapping for a subsequent
msync/fsync operation.

We'd need a similar thing for detecting write I/O errors too.

write(fd, data);
sleep(60);
fsync(fd); -> doesn't report write errors.

But that's all filed under "bug fixes" and can be done after you-know-when.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/