X-Git-Url: http://git.monstr.eu/?a=blobdiff_plain;f=fs%2Fbtrfs%2Fbackref.c;h=78b202d198b8e1741690a2a10fec1955cf221440;hb=d842bc6c0579ca7643eed029beabab3ac562a335;hp=7a8a2fc195338c21f76faf7215ea34ec5954fc2a;hpb=eed0218e8cae9fcd186c30e9fcf5fe46a87e056e;p=linux-2.6-microblaze.git diff --git a/fs/btrfs/backref.c b/fs/btrfs/backref.c index 7a8a2fc19533..78b202d198b8 100644 --- a/fs/btrfs/backref.c +++ b/fs/btrfs/backref.c @@ -1488,15 +1488,15 @@ static int btrfs_find_all_roots_safe(struct btrfs_trans_handle *trans, int btrfs_find_all_roots(struct btrfs_trans_handle *trans, struct btrfs_fs_info *fs_info, u64 bytenr, u64 time_seq, struct ulist **roots, - bool ignore_offset) + bool ignore_offset, bool skip_commit_root_sem) { int ret; - if (!trans) + if (!trans && !skip_commit_root_sem) down_read(&fs_info->commit_root_sem); ret = btrfs_find_all_roots_safe(trans, fs_info, bytenr, time_seq, roots, ignore_offset); - if (!trans) + if (!trans && !skip_commit_root_sem) up_read(&fs_info->commit_root_sem); return ret; }