btrfs: polish names of kmem caches
authorDavid Sterba <dsterba@suse.cz>
Fri, 7 Sep 2012 09:00:48 +0000 (03:00 -0600)
committerChris Mason <chris.mason@fusionio.com>
Mon, 1 Oct 2012 19:19:16 +0000 (15:19 -0400)
Usecase:

  watch 'grep btrfs < /proc/slabinfo'

easy to watch all caches in one go.

Signed-off-by: David Sterba <dsterba@suse.cz>
fs/btrfs/delayed-inode.c
fs/btrfs/extent_io.c
fs/btrfs/extent_map.c
fs/btrfs/inode.c

index eb768c4c1358e73f208f8fae3af199dd136558c0..b26d2f9d88d74a77a2ed4e372742e998b04d70b6 100644 (file)
@@ -29,7 +29,7 @@ static struct kmem_cache *delayed_node_cache;
 
 int __init btrfs_delayed_inode_init(void)
 {
-       delayed_node_cache = kmem_cache_create("delayed_node",
+       delayed_node_cache = kmem_cache_create("btrfs_delayed_node",
                                        sizeof(struct btrfs_delayed_node),
                                        0,
                                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD,
index 4a41b17295dcc73f89895a13ef8f00e0d1f7c589..3ad84f50068714bed0cee58724ea36368ece476a 100644 (file)
@@ -64,13 +64,13 @@ tree_fs_info(struct extent_io_tree *tree)
 
 int __init extent_io_init(void)
 {
-       extent_state_cache = kmem_cache_create("extent_state",
+       extent_state_cache = kmem_cache_create("btrfs_extent_state",
                        sizeof(struct extent_state), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!extent_state_cache)
                return -ENOMEM;
 
-       extent_buffer_cache = kmem_cache_create("extent_buffers",
+       extent_buffer_cache = kmem_cache_create("btrfs_extent_buffer",
                        sizeof(struct extent_buffer), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!extent_buffer_cache)
index ac606f076eb7a7d1292d5e33bb78a9cd417db962..8d1364d385d61dd3e053731beb34998c7baeb5f8 100644 (file)
@@ -11,7 +11,7 @@ static struct kmem_cache *extent_map_cache;
 
 int __init extent_map_init(void)
 {
-       extent_map_cache = kmem_cache_create("extent_map",
+       extent_map_cache = kmem_cache_create("btrfs_extent_map",
                        sizeof(struct extent_map), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!extent_map_cache)
index 9b21cf97cdd55e0bb1ab7a288df6e671f02925da..aae55625aa59fdcd28a5aacfabba94e1210c5068 100644 (file)
@@ -7155,31 +7155,31 @@ void btrfs_destroy_cachep(void)
 
 int btrfs_init_cachep(void)
 {
-       btrfs_inode_cachep = kmem_cache_create("btrfs_inode_cache",
+       btrfs_inode_cachep = kmem_cache_create("btrfs_inode",
                        sizeof(struct btrfs_inode), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, init_once);
        if (!btrfs_inode_cachep)
                goto fail;
 
-       btrfs_trans_handle_cachep = kmem_cache_create("btrfs_trans_handle_cache",
+       btrfs_trans_handle_cachep = kmem_cache_create("btrfs_trans_handle",
                        sizeof(struct btrfs_trans_handle), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!btrfs_trans_handle_cachep)
                goto fail;
 
-       btrfs_transaction_cachep = kmem_cache_create("btrfs_transaction_cache",
+       btrfs_transaction_cachep = kmem_cache_create("btrfs_transaction",
                        sizeof(struct btrfs_transaction), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!btrfs_transaction_cachep)
                goto fail;
 
-       btrfs_path_cachep = kmem_cache_create("btrfs_path_cache",
+       btrfs_path_cachep = kmem_cache_create("btrfs_path",
                        sizeof(struct btrfs_path), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!btrfs_path_cachep)
                goto fail;
 
-       btrfs_free_space_cachep = kmem_cache_create("btrfs_free_space_cache",
+       btrfs_free_space_cachep = kmem_cache_create("btrfs_free_space",
                        sizeof(struct btrfs_free_space), 0,
                        SLAB_RECLAIM_ACCOUNT | SLAB_MEM_SPREAD, NULL);
        if (!btrfs_free_space_cachep)