]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: switch extent_map to a rw lock
authorChris Mason <chris.mason@oracle.com>
Wed, 2 Sep 2009 20:24:52 +0000 (16:24 -0400)
committerChris Mason <chris.mason@oracle.com>
Fri, 11 Sep 2009 17:31:05 +0000 (13:31 -0400)
commitb34e7f7449999509385e99c37a67bf22716b343a
tree9d087adf7a28bb910992d07d93ea2a992e394110
parent87025e296181e1b1a58f979219af48b1464bd4a6
Btrfs: switch extent_map to a rw lock

There are two main users of the extent_map tree.  The
first is regular file inodes, where it is evenly spread
between readers and writers.

The second is the chunk allocation tree, which maps blocks from
logical addresses to phyiscal ones, and it is 99.99% reads.

The mapping tree is a point of lock contention during heavy IO
workloads, so this commit switches things to a rw lock.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/compression.c
fs/btrfs/disk-io.c
fs/btrfs/extent-tree.c
fs/btrfs/extent_io.c
fs/btrfs/extent_map.c
fs/btrfs/extent_map.h
fs/btrfs/file.c
fs/btrfs/inode.c
fs/btrfs/relocation.c
fs/btrfs/volumes.c