Re: [PATCH] Fix bad data from non-direct-io read after direct-io write

!MAILaRCHIVE_VOTE_RePLACE
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]
To: Linus Torvalds <torvalds@...>
Cc: Karl Schendel <kschendel@...>, Benjamin LaHaise <bcrl@...>, Andrew Morton <akpm@...>, Linux Kernel Mailing List <linux-kernel@...>, Nick Piggin <nickpiggin@...>, Leonid Ananiev <leonid.i.ananiev@...>, Chris Mason <chris.mason@...>
Date: Friday, October 26, 2007 - 7:38 pm

Linus Torvalds wrote:

Sure thing.  It looks like Karl just sent out the patch I had in mind,
so I'll run it through the tests on Monday.  I assume everyone can
handle waiting that long.


It's disappointingly easy to trigger with ext3 and ordered extending
writes.  The invalidation can race with jbd pinning the bhs while it
commits the transaction.  It happens that ext3 returns failure from
->releasepage if jbd is committing the transaction.

http://git.kernel.org/?p=linux/kernel/git/zab/aio-dio-regress.git;a=blob;f=c/aio-dio-i...


dio will definitely bring the page in with get_user_pages() but I'd like
to think that that pinned page could be safely invalidated out of the
page cache while dio holds a page reference.  I've never tried it, though.

- z
-
Previous message: [thread] [date] [author]
Next message: [thread] [date] [author]

Messages in current thread:
Re: [PATCH] Fix bad data from non-direct-io read after direc..., Zach Brown, (Fri Oct 26, 7:38 pm)