linux-fsdevel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Jan Kara <jack@suse.cz>
To: "Stephen C. Tweedie" <sct@redhat.com>
Cc: Andrew Morton <akpm@osdl.org>, linux-fsdevel@vger.kernel.org
Subject: Re: [RFC] Bug in journal_commit_transaction?
Date: Thu, 20 Apr 2006 19:51:01 +0200	[thread overview]
Message-ID: <20060420175101.GC31972@atrey.karlin.mff.cuni.cz> (raw)
In-Reply-To: <1145548837.3084.73.camel@orbit.scot.redhat.com>

  Hello,

> On Thu, 2006-04-20 at 10:47 +0200, Jan Kara wrote:
> 
> >   I've got no answer but I still think my argument was sound ;) Below
> > is a patch also with a verbose comment what it fixes and how.
> 
> Looks good to me, but it complicates the logic for this case and removes
> some useful debug checks for conditions which are almost always true.
> 
> Wouldn't it be better and safer just to make those almost-always true
> conditions always true?  We can do that pretty simply, just by
> processing the t_forget list in two passes, always doing the bitmaps
> last.  (Though this will need care, as the list is potentially moving
> under our feet...)
> 
> Actually, scratch that, because journal_unmap_buffer() can return a
> buffer to the committing transaction's forget list at any time, so we
> really cannot guarantee to do all non-bitmaps first: new non-bitmaps
> might arrive after we've started doing the bitmaps.  Ugh.
  Thanks for looking into it.  Yes, I agree that keeping that safety
check would be nicer. But I was thinking for some time if we cannot
somehow make sure that bitmaps are processed last but I didn't come up
with anything useful. One possibility might be to do some magic in
do_get_write_access() and get_create_access() if we find out we are
reallocating buffer on forget list but I'm afraid that simple solutions
(e.g. wait for commit) would harm performance which might be even
worse...

								Honza

-- 
Jan Kara <jack@suse.cz>
SuSE CR Labs

  reply	other threads:[~2006-04-20 17:51 UTC|newest]

Thread overview: 9+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-04-11 13:35 [RFC] Bug in journal_commit_transaction? Jan Kara
2006-04-12  1:27 ` Andrew Morton
2006-04-15 21:06   ` Jan Kara
2006-04-20  8:47     ` Jan Kara
2006-04-20 16:00       ` Stephen C. Tweedie
2006-04-20 17:51         ` Jan Kara [this message]
2006-04-20 14:28     ` Stephen C. Tweedie
2006-04-12  3:13 ` Stephen C. Tweedie
2006-04-15 21:08   ` Jan Kara

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=20060420175101.GC31972@atrey.karlin.mff.cuni.cz \
    --to=jack@suse.cz \
    --cc=akpm@osdl.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=sct@redhat.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).