linux-ext4.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Yuanhan Liu <yliu.null@gmail.com>
To: akpm@linux-foundation.org
Cc: linux-ext4@vger.kernel.org, Yuanhan Liu <yliu.null@gmail.com>
Subject: [PATCH 1/2] jbd: rename get_transaction to init_transaction
Date: Mon, 25 Jun 2012 17:06:47 +0800	[thread overview]
Message-ID: <1340615207-20548-1-git-send-email-yliu.null@gmail.com> (raw)

get_transaction() does nothing but initialization. So, rename it and
also fix the comments.

Signed-off-by: Yuanhan Liu <yliu.null@gmail.com>
---
 fs/jbd/transaction.c |   17 +++++++----------
 1 files changed, 7 insertions(+), 10 deletions(-)

diff --git a/fs/jbd/transaction.c b/fs/jbd/transaction.c
index febc10d..82f8a7a 100644
--- a/fs/jbd/transaction.c
+++ b/fs/jbd/transaction.c
@@ -31,12 +31,12 @@
 static void __journal_temp_unlink_buffer(struct journal_head *jh);
 
 /*
- * get_transaction: obtain a new transaction_t object.
+ * init_transaction: Initialise a new transaction_t object.
  *
- * Simply allocate and initialise a new transaction.  Create it in
- * RUNNING state and add it to the current journal (which should not
- * have an existing running transaction: we only make a new transaction
- * once we have started to commit the old one).
+ * Simply initialise a new transaction. initialise it in RUNNING state
+ * and add it to the current journal (which should not have an existing
+ * running transaction: we only make a new transaction once we have
+ * started to commit the old one).
  *
  * Preconditions:
  *	The journal MUST be locked.  We don't perform atomic mallocs on the
@@ -46,8 +46,7 @@ static void __journal_temp_unlink_buffer(struct journal_head *jh);
  * Called under j_state_lock
  */
 
-static transaction_t *
-get_transaction(journal_t *journal, transaction_t *transaction)
+static void init_transaction(journal_t *journal, transaction_t *transaction)
 {
 	transaction->t_journal = journal;
 	transaction->t_state = T_RUNNING;
@@ -63,8 +62,6 @@ get_transaction(journal_t *journal, transaction_t *transaction)
 
 	J_ASSERT(journal->j_running_transaction == NULL);
 	journal->j_running_transaction = transaction;

                 reply	other threads:[~2012-06-25  9:06 UTC|newest]

Thread overview: [no followups] expand[flat|nested]  mbox.gz  Atom feed

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=1340615207-20548-1-git-send-email-yliu.null@gmail.com \
    --to=yliu.null@gmail.com \
    --cc=akpm@linux-foundation.org \
    --cc=linux-ext4@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).