From: Andi Kleen <andi@firstfloor.org>
To: jim owens <owens6336@gmail.com>
Cc: Andi Kleen <andi@firstfloor.org>,
linux-btrfs <linux-btrfs@vger.kernel.org>
Subject: Re: [PATCH V3 17/18] Btrfs: Full direct I/O and AIO read implementation.
Date: Thu, 25 Mar 2010 10:41:19 +0100 [thread overview]
Message-ID: <20100325094119.GJ20695@one.firstfloor.org> (raw)
In-Reply-To: <4BAAD397.8060408@gmail.com>
On Wed, Mar 24, 2010 at 11:08:07PM -0400, jim owens wrote:
> Andi Kleen wrote:
> > > On Tue, Mar 23, 2010 at 05:40:00PM -0400, jim owens wrote:
> >> >> Andi Kleen wrote:
> >> >>
> >> >> With checksums enabled, uncompressed reads aligned on the 4k block
> >> >> are classic direct IO to user memory except at EOF.
> > >
> > > Hmm, but what happens if the user modifies the memory in parallel?
> > > Would spurious checksum failures be reported then?
>
> It does put a warning in the log but it does not fail the read
> because I circumvent that by doing the failed-checksum-retry as
> a buffered read and retest. The checksum passes and we copy
> the data to the user memory (where they can then trash it again).
Ok. That will work I guess.
> I was going to put a comment about that but felt my comment
> density was already over the btrfs style guide limit. :)
Hehe.
>
> > > Same for writing I guess (data end up on disk with wrong checksum)?
>
> Well we don't have any code done yet for writing and that was
> just one interesting challenge that needed to be solved.
>
> > > Those both would seem like serious flaws to me.
>
> Agree, so the write design needs to prevent bad checksums.
How? Do you have a plan for that?
>
> Read is already correct and if people do not want a log warning
> that the application is misbehaving that can be eliminated.
I guess if it's strictly rate limitted it might be ok.
-Andi
--
ak@linux.intel.com -- Speaking for myself only.
next prev parent reply other threads:[~2010-03-25 9:41 UTC|newest]
Thread overview: 9+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-03-22 3:34 [PATCH V3 17/18] Btrfs: Full direct I/O and AIO read implementation jim owens
2010-03-23 5:49 ` Andi Kleen
2010-03-23 21:40 ` jim owens
2010-03-24 0:57 ` Chris Mason
2010-03-24 2:37 ` Andi Kleen
2010-03-25 3:08 ` jim owens
2010-03-25 9:41 ` Andi Kleen [this message]
2010-03-25 22:38 ` jim owens
2010-03-23 21:44 ` jim owens
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=20100325094119.GJ20695@one.firstfloor.org \
--to=andi@firstfloor.org \
--cc=linux-btrfs@vger.kernel.org \
--cc=owens6336@gmail.com \
/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;
as well as URLs for NNTP newsgroup(s).