]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: pass NULL as trans to btrfs_search_slot if we only want to search
authorMarcos Paulo de Souza <mpdesouza@suse.com>
Tue, 20 Jul 2021 18:02:47 +0000 (15:02 -0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 23 Aug 2021 11:19:00 +0000 (13:19 +0200)
commit01d1607166d3e6e461bfcb88a182293f6d86101f
tree0d1ed1dacd98fbc2e12a3e34dd5a60f2eeb9cda7
parentf3d484991dd0e35da012bd4a945f8ce9b897a4c9
btrfs: pass NULL as trans to btrfs_search_slot if we only want to search

Using a transaction in btrfs_search_slot is only useful when we are
searching to add or modify the tree. When the function is used for
searching, insert length and mod arguments are 0, there is no need to
use a transaction.

No functional changes, changing for consistency.

Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Marcos Paulo de Souza <mpdesouza@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/backref.c
fs/btrfs/extent-tree.c