Btrfs: Optimize locking in btrfs_next_leaf()
commit8e73f275011b3264a87339fd9f1690e944e381c9
authorChris Mason <chris.mason@oracle.com>
Fri, 3 Apr 2009 14:14:18 +0000 (3 10:14 -0400)
committerChris Mason <chris.mason@oracle.com>
Fri, 3 Apr 2009 14:14:18 +0000 (3 10:14 -0400)
tree865900b191ed0e01f10d2f87e28c9e2ed56e5722
parentc8c42864f6193638eed136e0243f426a0b7f4bc2
Btrfs: Optimize locking in btrfs_next_leaf()

btrfs_next_leaf was using blocking locks when it could have been using
faster spinning ones instead.  This adds a few extra checks around
the pieces that block and switches over to spinning locks.

Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/ctree.c