]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: change the ordered tree to use a spinlock instead of a mutex
authorJosef Bacik <josef@redhat.com>
Tue, 2 Feb 2010 21:48:28 +0000 (21:48 +0000)
committerChris Mason <chris.mason@oracle.com>
Mon, 15 Mar 2010 15:00:12 +0000 (11:00 -0400)
commit8b0962f522735fa45f36a3382f4ce2a80a0dff7f
tree4a29e47c0935375968971450a2f2949bbd3cdd43
parent06358e1b9b38b428264b5f581f493f468236cafc
Btrfs: change the ordered tree to use a spinlock instead of a mutex

The ordered tree used to need a mutex, but currently all we use it for is to
protect the rb_tree, and a spin_lock is just fine for that.  Using a spin_lock
instead makes dbench run a little faster, 58 mb/s instead of 51 mb/s, and have
less latency, 3445.138 ms instead of 3820.633 ms.

Signed-off-by: Josef Bacik <josef@redhat.com>
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/ordered-data.c
fs/btrfs/ordered-data.h