linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* Understanding ext3
@ 2006-11-11 11:15 Ratna Manoj
  0 siblings, 0 replies; only message in thread
From: Ratna Manoj @ 2006-11-11 11:15 UTC (permalink / raw)
  To: linux-ext4; +Cc: sct

---------- Forwarded message ----------
From: Ratna Manoj <manoj.br@gmail.com>
Date: Nov 11, 2006 4:35 PM
Subject: sct@redhat.com
To: linux-ext4@vger.kernel.org


Hi,


int journal_dirty_data(handle_t *handle, struct buffer_head *bh)
{
                        ..................
                        ..................

                         /*
                         * This buffer may be undergoing writeout in commit.  We
                         * can't return from here and let the caller dirty it
                         * again because that can cause the write-out loop in
                         * commit to never terminate.
                         */
                         if (buffer_dirty(bh)) {
                                 get_bh(bh);
                                 spin_unlock(&journal->j_list_lock);
                                 jbd_unlock_bh_state(bh);
                                 need_brelse = 1;
                                 sync_dirty_buffer(bh);
                                 jbd_lock_bh_state(bh);
                                 spin_lock(&journal->j_list_lock);
                                 /* The buffer may become locked again at any
                                    time if it is redirtied */
                         }
                         ..............................
                         ..............................
}


Can any body please explain how returning from the above function
cause write-out loop in commit to never terminate ?

If the current buffer is in the data_sync list of previous commiting
transaction, after returning from the journal_dirty_data,
generic_commit_write will redirty the buffer even though previous
commiting transaction commits the buffer to disk. Correct ?


-Ratna.

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2006-11-11 11:15 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-11-11 11:15 Understanding ext3 Ratna Manoj

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).