public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Namhyung Kim <namhyung@gmail.com>
To: Al Viro <viro@zeniv.linux.org.uk>
Cc: Andreas Gruenbacher <agruen@suse.de>, linux-kernel@vger.kernel.org
Subject: [PATCH 3/3] mbcache: update comments
Date: Tue,  7 Dec 2010 19:08:56 +0900	[thread overview]
Message-ID: <1291716536-10285-3-git-send-email-namhyung@gmail.com> (raw)
In-Reply-To: <1291716536-10285-1-git-send-email-namhyung@gmail.com>

Add missing arguments in some function comments and update
description of mb_cache_entry_free() because it refers obsolete
mb_cache_entry_takeout().

Signed-off-by: Namhyung Kim <namhyung@gmail.com>
---
 fs/mbcache.c |   17 +++++++++++++++--
 1 files changed, 15 insertions(+), 2 deletions(-)

diff --git a/fs/mbcache.c b/fs/mbcache.c
index c0cfc42..ab73fff 100644
--- a/fs/mbcache.c
+++ b/fs/mbcache.c
@@ -298,6 +298,8 @@ mb_cache_shrink(struct block_device *bdev)
  * Shrinks the cache to its minimum possible size (hopefully 0 entries),
  * and then destroys it. If this was the last mbcache, un-registers the
  * mbcache from kernel memory management.
+ *
+ * @cache: cache to be destroyed
  */
 void
 mb_cache_destroy(struct mb_cache *cache)
@@ -339,6 +341,9 @@ mb_cache_destroy(struct mb_cache *cache)
  * and thus cannot be looked up yet. It should be filled with data, and
  * then inserted into the cache using mb_cache_entry_insert(). Returns NULL
  * if no more memory was available.
+ *
+ * @cache: cache the cache entry to be allocated from
+ * @gfp_flags: memory allocation flags
  */
 struct mb_cache_entry *
 mb_cache_entry_alloc(struct mb_cache *cache, gfp_t gfp_flags)
@@ -380,6 +385,7 @@ mb_cache_entry_alloc(struct mb_cache *cache, gfp_t gfp_flags)
  * already (this may happen after a failed lookup, but when another process
  * has inserted the same cache entry in the meantime).
  *
+ * @ce: cache entry to be inserted
  * @bdev: device the cache entry belongs to
  * @block: block number
  * @key: lookup key
@@ -422,6 +428,8 @@ out:
  * Release a handle to a cache entry. When the last handle to a cache entry
  * is released it is either freed (if it is invalid) or otherwise inserted
  * in to the lru list.
+ *
+ * @ce: cache entry to be released
  */
 void
 mb_cache_entry_release(struct mb_cache_entry *ce)
@@ -434,8 +442,9 @@ mb_cache_entry_release(struct mb_cache_entry *ce)
 /*
  * mb_cache_entry_free()
  *
- * This is equivalent to the sequence mb_cache_entry_takeout() --
- * mb_cache_entry_release().
+ * Release a handle to a cache entry and free it.
+ *
+ * @ce: cache entry to be freed
  */
 void
 mb_cache_entry_free(struct mb_cache_entry *ce)
@@ -454,6 +463,10 @@ mb_cache_entry_free(struct mb_cache_entry *ce)
  * in the cache per device and block.) Returns NULL if no such cache entry
  * exists. The returned cache entry is locked for exclusive access ("single
  * writer").
+ *
+ * @cache: cache to search
+ * @bdev: device the cache entry should belong to
+ * @block: block number
  */
 struct mb_cache_entry *
 mb_cache_entry_get(struct mb_cache *cache, struct block_device *bdev,
-- 
1.7.0.4


      parent reply	other threads:[~2010-12-07 10:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-12-07 10:08 [PATCH 1/3] mbcache: use list_for_each_entry* Namhyung Kim
2010-12-07 10:08 ` [PATCH 2/3] mbcache: remove unnecessary conditionals Namhyung Kim
2010-12-07 10:08 ` Namhyung Kim [this message]

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=1291716536-10285-3-git-send-email-namhyung@gmail.com \
    --to=namhyung@gmail.com \
    --cc=agruen@suse.de \
    --cc=linux-kernel@vger.kernel.org \
    --cc=viro@zeniv.linux.org.uk \
    /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