diff options
author | David Sterba <dsterba@suse.com> | 2017-03-28 12:06:05 +0200 |
---|---|---|
committer | David Sterba <dsterba@suse.com> | 2017-06-19 18:26:01 +0200 |
commit | 4b5faeac4688174fd523f2a22b7d70d5a96842fb (patch) | |
tree | c0eedea1162f9b1f9c23dc4dc12b67928e5c7477 /fs/btrfs/ctree.h | |
parent | btrfs: scrub: embed scrub_wr_ctx into scrub context (diff) | |
download | linux-4b5faeac4688174fd523f2a22b7d70d5a96842fb.tar.xz linux-4b5faeac4688174fd523f2a22b7d70d5a96842fb.zip |
btrfs: use generic slab for for btrfs_transaction
Observing the number of slab objects of btrfs_transaction, there's just
one active on an almost quiescent filesystem, and the number of objects
goes to about ten when sync is in progress. Then the nubmer goes down to
1. This matches the expectations of the transaction lifetime.
For such use the separate slab cache is not justified, as we do not
reuse objects frequently. For the shortlived transaction, the generic
slab (size 512) should be ok. We can optimistically expect that the 512
slabs are not all used (fragmentation) and there are free slots to take
when we do the allocation, compared to potentially allocating a whole new
page for the separate slab.
We'll lose the stats about the object use, which could be added later if
we really need them.
Signed-off-by: David Sterba <dsterba@suse.com>
Diffstat (limited to 'fs/btrfs/ctree.h')
-rw-r--r-- | fs/btrfs/ctree.h | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/fs/btrfs/ctree.h b/fs/btrfs/ctree.h index 388f1128544e..f0f5f28784b6 100644 --- a/fs/btrfs/ctree.h +++ b/fs/btrfs/ctree.h @@ -48,7 +48,6 @@ struct btrfs_trans_handle; struct btrfs_transaction; struct btrfs_pending_snapshot; extern struct kmem_cache *btrfs_trans_handle_cachep; -extern struct kmem_cache *btrfs_transaction_cachep; extern struct kmem_cache *btrfs_bit_radix_cachep; extern struct kmem_cache *btrfs_path_cachep; extern struct kmem_cache *btrfs_free_space_cachep; |