Skip to content
Commit a8f6f619 authored by Sidong Yang's avatar Sidong Yang Committed by David Sterba
Browse files

btrfs: qgroup: remove duplicated check in adding qgroup relations



Removes duplicated check when adding qgroup relations.
btrfs_add_qgroup_relations function adds relations by calling
add_relation_rb(). add_relation_rb() checks that member/parentid exists
in current qgroup_tree. But it already checked before calling the
function. It seems that we don't need to double check.

Add new function __add_relation_rb() that adds relations with
qgroup structures and makes old function use the new one. And it makes
btrfs_add_qgroup_relation() function work without double checks by
calling the new function.

Signed-off-by: default avatarSidong Yang <realwakka@gmail.com>
Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
[ add comments ]
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent dc4a4bdb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment