btrfs: add btrfs_delete_ref_head helper
authorJosef Bacik <jbacik@fb.com>
Mon, 3 Dec 2018 15:20:29 +0000 (10:20 -0500)
committerDavid Sterba <dsterba@suse.com>
Mon, 17 Dec 2018 13:51:46 +0000 (14:51 +0100)
commitd7baffdaf9f9df8c9715aa507e3be2f409347c74
tree58158397803e1a19f9fb44f8f9b82a696b75c792
parentfdb1e121803433775d1e6f79b21a13add8b22f57
btrfs: add btrfs_delete_ref_head helper

We do this dance in cleanup_ref_head and check_ref_cleanup, unify it
into a helper and cleanup the calling functions.

Reviewed-by: Omar Sandoval <osandov@fb.com>
Reviewed-by: Nikolay Borisov <nborisov@suse.com>
Signed-off-by: Josef Bacik <jbacik@fb.com>
Reviewed-by: David Sterba <dsterba@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/delayed-ref.c
fs/btrfs/delayed-ref.h
fs/btrfs/extent-tree.c