Commit ec07c5c1 authored by Andrew Morton's avatar Andrew Morton Committed by Linus Torvalds

[PATCH] ext3 commenting cleanup

Redo the (strange) layout of some of Roger's comments.
parent b9df0268
...@@ -212,16 +212,14 @@ do { \ ...@@ -212,16 +212,14 @@ do { \
* *
* The primary function for recovering the log contents when mounting a * The primary function for recovering the log contents when mounting a
* journaled device. * journaled device.
*/ *
int journal_recover(journal_t *journal)
{
/*
* Recovery is done in three passes. In the first pass, we look for the * Recovery is done in three passes. In the first pass, we look for the
* end of the log. In the second, we assemble the list of revoke * end of the log. In the second, we assemble the list of revoke
* blocks. In the third and final pass, we replay any un-revoked blocks * blocks. In the third and final pass, we replay any un-revoked blocks
* in the log. * in the log.
*/ */
int journal_recover(journal_t *journal)
{
int err; int err;
journal_superblock_t * sb; journal_superblock_t * sb;
...@@ -273,15 +271,13 @@ int journal_recover(journal_t *journal) ...@@ -273,15 +271,13 @@ int journal_recover(journal_t *journal)
* journal structures in memory to ignore it (presumably because the * journal structures in memory to ignore it (presumably because the
* caller has evidence that it is out of date). * caller has evidence that it is out of date).
* This function does'nt appear to be exorted.. * This function does'nt appear to be exorted..
*/ *
int journal_skip_recovery(journal_t *journal)
{
/*
* We perform one pass over the journal to allow us to tell the user how * We perform one pass over the journal to allow us to tell the user how
* much recovery information is being erased, and to let us initialise * much recovery information is being erased, and to let us initialise
* the journal transaction sequence numbers to the next unused ID. * the journal transaction sequence numbers to the next unused ID.
*/ */
int journal_skip_recovery(journal_t *journal)
{
int err; int err;
journal_superblock_t * sb; journal_superblock_t * sb;
......
...@@ -862,22 +862,23 @@ int journal_get_undo_access (handle_t *handle, struct buffer_head *bh) ...@@ -862,22 +862,23 @@ int journal_get_undo_access (handle_t *handle, struct buffer_head *bh)
} }
/** /**
* int journal_dirty_data() - mark a buffer as containing dirty data which needs to be flushed before we can commit the current transaction. * int journal_dirty_data() - mark a buffer as containing dirty data which
* needs to be flushed before we can commit the
* current transaction.
* @handle: transaction * @handle: transaction
* @bh: bufferhead to mark * @bh: bufferhead to mark
* *
* The buffer is placed on the transaction's data list and is marked as * The buffer is placed on the transaction's data list and is marked as
* belonging to the transaction. * belonging to the transaction.
* *
* Returns error number or 0 on success. * Returns error number or 0 on success.
*/ *
int journal_dirty_data (handle_t *handle, struct buffer_head *bh)
{
/*
* journal_dirty_data() can be called via page_launder->ext3_writepage * journal_dirty_data() can be called via page_launder->ext3_writepage
* by kswapd. So it cannot block. Happily, there's nothing here * by kswapd. So it cannot block. Happily, there's nothing here
* which needs lock_journal if `async' is set. * which needs lock_journal if `async' is set.
*/ */
int journal_dirty_data (handle_t *handle, struct buffer_head *bh)
{
journal_t *journal = handle->h_transaction->t_journal; journal_t *journal = handle->h_transaction->t_journal;
int need_brelse = 0; int need_brelse = 0;
struct journal_head *jh; struct journal_head *jh;
...@@ -1022,23 +1023,22 @@ int journal_dirty_data (handle_t *handle, struct buffer_head *bh) ...@@ -1022,23 +1023,22 @@ int journal_dirty_data (handle_t *handle, struct buffer_head *bh)
* @handle: transaction to add buffer to. * @handle: transaction to add buffer to.
* @bh: buffer to mark * @bh: buffer to mark
* *
* mark dirty metadata which needs to be journaled as part of the current transaction. * mark dirty metadata which needs to be journaled as part of the current
* transaction.
* *
* The buffer is placed on the transaction's metadata list and is marked * The buffer is placed on the transaction's metadata list and is marked
* as belonging to the transaction. * as belonging to the transaction.
* *
* Returns error number or 0 on success. * Returns error number or 0 on success.
*/ *
int journal_dirty_metadata (handle_t *handle, struct buffer_head *bh)
{
/*
* Special care needs to be taken if the buffer already belongs to the * Special care needs to be taken if the buffer already belongs to the
* current committing transaction (in which case we should have frozen * current committing transaction (in which case we should have frozen
* data present for that commit). In that case, we don't relink the * data present for that commit). In that case, we don't relink the
* buffer: that only gets done when the old transaction finally * buffer: that only gets done when the old transaction finally
* completes its commit. * completes its commit.
*
*/ */
int journal_dirty_metadata (handle_t *handle, struct buffer_head *bh)
{
transaction_t *transaction = handle->h_transaction; transaction_t *transaction = handle->h_transaction;
journal_t *journal = transaction->t_journal; journal_t *journal = transaction->t_journal;
struct journal_head *jh = bh2jh(bh); struct journal_head *jh = bh2jh(bh);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment