]> git.baikalelectronics.ru Git - kernel.git/commit
Btrfs: do not do fast caching if we are allocating blocks for tree_root
authorJosef Bacik <josef@redhat.com>
Wed, 8 Dec 2010 14:15:11 +0000 (09:15 -0500)
committerJosef Bacik <josef@redhat.com>
Thu, 9 Dec 2010 18:57:13 +0000 (13:57 -0500)
commit0ea5b4f3d3723ca924cbe70f8905bfbdf928076e
tree418a67d8d2de13739f3b14518917c8aaadafe3b8
parent17e1e3145977d4051f5ab2e9569618fad8fa4385
Btrfs: do not do fast caching if we are allocating blocks for tree_root

Since the fast caching uses normal tree locking, we can possibly deadlock if we
get to the caching via a btrfs_search_slot() on the tree_root.  So just check to
see if the root we are on is the tree root, and just don't do the fast caching.

Reported-by: Sage Weil <sage@newdream.net>
Signed-off-by: Josef Bacik <josef@redhat.com>
fs/btrfs/extent-tree.c