From: Andreas Dilger <adilger@sun.com>
To: Josef Bacik <jbacik@redhat.com>
Cc: linux-ext4@vger.kernel.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] jbd: fix assertion failure in journal_next_log_block
Date: Thu, 31 Jan 2008 12:35:43 -0700 [thread overview]
Message-ID: <20080131193543.GS23836@webber.adilger.int> (raw)
In-Reply-To: <20080131161417.GA29679@unused.rdu.redhat.com>
On Jan 31, 2008 11:14 -0500, Josef Bacik wrote:
[snip excellent analysis]
> So you get into this situation where
> t_nr_buffers (the actual number of buffers that are on the transaction) is
> greater than the number of buffers accounted for via t_outstanding_credits.
> This presents a problem since as we loop through writting buffers to the
> journal, we decrement t_outstanding_credits, and if t_nr_buffers is more than
> t_outstanding_credits then we end up with a negative number for
> t_outstanding_credits
>
> Signed-off-by: Josef Bacik <jbacik@redhat.com>
Do you know what kernel this problem was introduced in, or is this a
long standing problem? Presumably the same is needed for jbd2?
Once we have some decent amount of testing going on with ext4, I think
it makes sense to merge the jbd2 changes back into jbd and return to
a single code base, since there is nothing in the jbd2 code that ext3
can't also work with (i.e. all of the changes are properly isolated
with compatibility flags and such).
> @@ -1056,7 +1056,7 @@ static inline int jbd_space_needed(journal_t *journal)
> int nblocks = journal->j_max_transaction_buffers;
> if (journal->j_committing_transaction)
> nblocks += journal->j_committing_transaction->
> - t_outstanding_credits;
> + t_nr_buffers;
(trivial) this can be moved back onto the previous line.
> @@ -1168,7 +1168,7 @@ static inline int jbd_space_needed(journal_t *journal)
> int nblocks = journal->j_max_transaction_buffers;
> if (journal->j_committing_transaction)
> nblocks += journal->j_committing_transaction->
> - t_outstanding_credits;
> + t_nr_buffers;
Same...
Cheers, Andreas
--
Andreas Dilger
Sr. Staff Engineer, Lustre Group
Sun Microsystems of Canada, Inc.
next prev parent reply other threads:[~2008-01-31 19:36 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2008-01-31 16:14 [PATCH] jbd: fix assertion failure in journal_next_log_block Josef Bacik
2008-01-31 19:35 ` Andreas Dilger [this message]
2008-01-31 21:52 ` Josef Bacik
2008-02-01 0:50 ` Mingming Cao
2008-02-05 17:27 ` Jan Kara
2008-02-05 18:59 ` Josef Bacik
2008-02-06 11:06 ` Jan Kara
2008-02-06 18:47 ` Mingming Cao
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=20080131193543.GS23836@webber.adilger.int \
--to=adilger@sun.com \
--cc=jbacik@redhat.com \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-kernel@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