Commit fef394f7 authored by Jeff Mahoney's avatar Jeff Mahoney Committed by David Sterba

btrfs: drop unused extent_op arg from btrfs_add_delayed_data_ref

btrfs_add_delayed_data_ref is always called with a NULL extent_op,
so let's drop the argument.
Signed-off-by: default avatarJeff Mahoney <jeffm@suse.com>
Reviewed-by: default avatarDavid Sterba <dsterba@suse.com>
Signed-off-by: default avatarDavid Sterba <dsterba@suse.com>
parent 694a0dee
...@@ -829,15 +829,13 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info, ...@@ -829,15 +829,13 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info,
struct btrfs_trans_handle *trans, struct btrfs_trans_handle *trans,
u64 bytenr, u64 num_bytes, u64 bytenr, u64 num_bytes,
u64 parent, u64 ref_root, u64 parent, u64 ref_root,
u64 owner, u64 offset, u64 reserved, int action, u64 owner, u64 offset, u64 reserved, int action)
struct btrfs_delayed_extent_op *extent_op)
{ {
struct btrfs_delayed_data_ref *ref; struct btrfs_delayed_data_ref *ref;
struct btrfs_delayed_ref_head *head_ref; struct btrfs_delayed_ref_head *head_ref;
struct btrfs_delayed_ref_root *delayed_refs; struct btrfs_delayed_ref_root *delayed_refs;
struct btrfs_qgroup_extent_record *record = NULL; struct btrfs_qgroup_extent_record *record = NULL;
BUG_ON(extent_op && !extent_op->is_data);
ref = kmem_cache_alloc(btrfs_delayed_data_ref_cachep, GFP_NOFS); ref = kmem_cache_alloc(btrfs_delayed_data_ref_cachep, GFP_NOFS);
if (!ref) if (!ref)
return -ENOMEM; return -ENOMEM;
...@@ -859,7 +857,7 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info, ...@@ -859,7 +857,7 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info,
} }
} }
head_ref->extent_op = extent_op; head_ref->extent_op = NULL;
delayed_refs = &trans->transaction->delayed_refs; delayed_refs = &trans->transaction->delayed_refs;
spin_lock(&delayed_refs->lock); spin_lock(&delayed_refs->lock);
......
...@@ -250,8 +250,7 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info, ...@@ -250,8 +250,7 @@ int btrfs_add_delayed_data_ref(struct btrfs_fs_info *fs_info,
struct btrfs_trans_handle *trans, struct btrfs_trans_handle *trans,
u64 bytenr, u64 num_bytes, u64 bytenr, u64 num_bytes,
u64 parent, u64 ref_root, u64 parent, u64 ref_root,
u64 owner, u64 offset, u64 reserved, int action, u64 owner, u64 offset, u64 reserved, int action);
struct btrfs_delayed_extent_op *extent_op);
int btrfs_add_delayed_extent_op(struct btrfs_fs_info *fs_info, int btrfs_add_delayed_extent_op(struct btrfs_fs_info *fs_info,
struct btrfs_trans_handle *trans, struct btrfs_trans_handle *trans,
u64 bytenr, u64 num_bytes, u64 bytenr, u64 num_bytes,
......
...@@ -2089,7 +2089,7 @@ int btrfs_inc_extent_ref(struct btrfs_trans_handle *trans, ...@@ -2089,7 +2089,7 @@ int btrfs_inc_extent_ref(struct btrfs_trans_handle *trans,
ret = btrfs_add_delayed_data_ref(fs_info, trans, bytenr, ret = btrfs_add_delayed_data_ref(fs_info, trans, bytenr,
num_bytes, parent, root_objectid, num_bytes, parent, root_objectid,
owner, offset, 0, owner, offset, 0,
BTRFS_ADD_DELAYED_REF, NULL); BTRFS_ADD_DELAYED_REF);
} }
return ret; return ret;
} }
...@@ -7244,7 +7244,7 @@ int btrfs_free_extent(struct btrfs_trans_handle *trans, ...@@ -7244,7 +7244,7 @@ int btrfs_free_extent(struct btrfs_trans_handle *trans,
num_bytes, num_bytes,
parent, root_objectid, owner, parent, root_objectid, owner,
offset, 0, offset, 0,
BTRFS_DROP_DELAYED_REF, NULL); BTRFS_DROP_DELAYED_REF);
} }
return ret; return ret;
} }
...@@ -8194,8 +8194,7 @@ int btrfs_alloc_reserved_file_extent(struct btrfs_trans_handle *trans, ...@@ -8194,8 +8194,7 @@ int btrfs_alloc_reserved_file_extent(struct btrfs_trans_handle *trans,
ret = btrfs_add_delayed_data_ref(fs_info, trans, ins->objectid, ret = btrfs_add_delayed_data_ref(fs_info, trans, ins->objectid,
ins->offset, 0, ins->offset, 0,
root_objectid, owner, offset, root_objectid, owner, offset,
ram_bytes, BTRFS_ADD_DELAYED_EXTENT, ram_bytes, BTRFS_ADD_DELAYED_EXTENT);
NULL);
return ret; return ret;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment