linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
From: Daniel McNeil <daniel@osdl.org>
To: Andrew Morton <akpm@osdl.org>
Cc: Linux Kernel Mailing List <linux-kernel@vger.kernel.org>,
	linux-mm@kvack.org, "linux-aio@kvack.org" <linux-aio@kvack.org>
Subject: Re: 2.6.2-mm1 aka "Geriatric Wombat" DIO read race still fails
Date: 05 Feb 2004 16:32:35 -0800	[thread overview]
Message-ID: <1076027555.7182.122.camel@ibm-c.pdx.osdl.net> (raw)
In-Reply-To: <20040205160755.25583627.akpm@osdl.org>

On Thu, 2004-02-05 at 16:07, Andrew Morton wrote:
> Daniel McNeil <daniel@osdl.org> wrote:
> >
> > Andrew,
> > 
> > I tested 2.6.2-mm1 on an 8-proc running 6 copies of the read_under
> > test and all 6 read_under tests saw uninitialized data in less than 5
> > minutes. :(
> 
> The performance implications of synchronising behind kjournald writes for
> normal non-blocking writeback are bad.  Can you detail what you now think
> is the failure mechanism?
> 

I think the problem is that any block_write_full_page(WB_SYNC_NONE)
that hits a page that has a buffer in process of being written will
get PageWriteback cleared even though the i/o has not completed.
(The buffer will be locked, but buffer_dirty() is cleared, so
 __block_write_full_page() will SetPageWriteback(); unlock_page();
 see no buffer were submitted and call end_page_writeback())

Any subsequent filemap_write_and_wait() or filemap_fdatawrite() /
filemap_fdatawait will never wait for that i/o.  So this could
potentially be a problem for more than just DIO.

BTW: 2.4 __block_write_full_page() always did a lock_buffer(), so
it waits for i/o in flight.

I agree though, it would be best if non-sync __block_write_full_page()
would not block on buffers in flight.  Somehow we need to move the
clearing of PageWriteback() until after the buffer has been written
even for the case where ll_rw_block() is called.

Thoughts?

Daniel


--
To unsubscribe, send a message with 'unsubscribe linux-mm' in
the body to majordomo@kvack.org.  For more info on Linux MM,
see: http://www.linux-mm.org/ .
Don't email: <a href=mailto:"aart@kvack.org"> aart@kvack.org </a>

  reply	other threads:[~2004-02-06  0:32 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-02-05  9:44 2.6.2-mm1 aka "Geriatric Wombat" Andrew Morton
2004-02-05  9:52 ` [PATCH] via crypto beginnings Jeff Garzik
2004-02-05 10:11   ` Andrew Morton
2004-02-05  9:55 ` 2.6.2-mm1 aka "Geriatric Wombat" Nikita Danilov
2004-02-05 10:00 ` Russell King
2004-02-05 10:37   ` Jeff Garzik
2004-02-05 10:50     ` Russell King
2004-02-05 11:47 ` Nick Piggin
2004-02-05 16:11   ` Martin J. Bligh
2004-02-05 16:16     ` Nick Piggin
2004-02-05 16:20     ` Nikita Danilov
2004-02-05 17:58 ` John Cherry
2004-02-05 19:23 ` Deepak Saxena
2004-02-05 20:05   ` Greg KH
2004-02-05 23:31 ` 2.6.2-mm1 aka "Geriatric Wombat" DIO read race still fails Daniel McNeil
2004-02-05 23:58   ` Badari Pulavarty
2004-02-06 22:37     ` Daniel McNeil
2004-02-06  0:07   ` Andrew Morton
2004-02-06  0:32     ` Daniel McNeil [this message]
2004-02-06 18:02 ` 2.6.2-mm1 aka "Geriatric Wombat" Thomas Davis

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1076027555.7182.122.camel@ibm-c.pdx.osdl.net \
    --to=daniel@osdl.org \
    --cc=akpm@osdl.org \
    --cc=linux-aio@kvack.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mm@kvack.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox