[PATCH 3/3] mbcache: update comments
From: Namhyung Kim
Date: Tue Dec 07 2010 - 05:09:17 EST
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@xxxxxxxxx>
---
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
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/