linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Josef Bacik <jbacik@fusionio.com>
To: Josef Bacik <jbacik@fusionio.com>
Cc: <linux-btrfs@vger.kernel.org>
Subject: Re: [PATCH] Btrfs: do not complete ordered extents that are truncated
Date: Tue, 27 Aug 2013 14:54:53 -0400	[thread overview]
Message-ID: <20130827185453.GL29654@localhost.localdomain> (raw)
In-Reply-To: <1377624014-6426-1-git-send-email-jbacik@fusionio.com>

On Tue, Aug 27, 2013 at 01:20:14PM -0400, Josef Bacik wrote:
> Currently we will do the normal btrfs_finish_ordered_io if we invalidate a dirty
> page that is part of an ordered extent but hasn't yet been submitted for IO.
> The side effect of this is that when the rest of the ordered extent is completed
> it will still add its extent to the file and it's csums to the tree.  This
> usually isn't a problem since this occurs right before a truncate, so these
> csums and extents are going to be cleaned up.  However if there is an error
> doing the truncate we can leave extents that point to invalid data, and as such
> you'll get csum errors trying to read back this extent.  So to handle this just
> set a flag on the ordered extent if we are going to invalidate one of its dirty
> pages, and then once we go to do the completion stuff we skip updating the file
> extents and adding our csums, we just free everything up and exit.  This is
> preliminary work we need to have better orphan entry error handling.  Thanks,
> 
> Signed-off-by: Josef Bacik <jbacik@fusionio.com>
> ---

Ignore this, it is wrong.

Josef

      reply	other threads:[~2013-08-27 18:54 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2013-08-27 17:20 [PATCH] Btrfs: do not complete ordered extents that are truncated Josef Bacik
2013-08-27 18:54 ` Josef Bacik [this message]

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=20130827185453.GL29654@localhost.localdomain \
    --to=jbacik@fusionio.com \
    --cc=linux-btrfs@vger.kernel.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;
as well as URLs for NNTP newsgroup(s).