linux-btrfs.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 0/4] Cleanup alloc_reserved_tree_block signature
@ 2018-05-21  9:27 Nikolay Borisov
  2018-05-21  9:27 ` [PATCH 1/4] btrfs: Remove fs_info argument from alloc_reserved_tree_block Nikolay Borisov
                   ` (4 more replies)
  0 siblings, 5 replies; 10+ messages in thread
From: Nikolay Borisov @ 2018-05-21  9:27 UTC (permalink / raw)
  To: linux-btrfs; +Cc: Nikolay Borisov

At the moment alloc_reserved_tree_block takes 8 friggin arguments. The irony 
is that all of those are really derived from 3 structures. This series ends up 
reducing the arguments to 3. As a result some code, private to alloc_reserved_tree_block
is moved from run_delayed_tree_ref. Patch 1 removes the fs_info argument, 
Patch 2 replaces all arguments derived from btrfs_delayed_ref_node with the 
nodes itself, Patch 3 replaces the last 2 arguments with btrfs_delayed_extent_op
and finally, Patch 4 simplifies the code a bit by removing one extra check.

All in all this doesn't provide any functional changes but makes the code 
easier to follow. Also it has survived 2 xfstest runs. 

Nikolay Borisov (4):
  btrfs: Remove fs_info argument from alloc_reserved_tree_block
  btrfs: Simplify alloc_reserved_tree_block interface
  btrfs: Pass btrfs_delayed_extent_op to alloc_reserved_tree_block
  btrfs: Streamline shared ref check in alloc_reserved_tree_block

 fs/btrfs/extent-tree.c | 76 ++++++++++++++++++++++++--------------------------
 1 file changed, 37 insertions(+), 39 deletions(-)

-- 
2.7.4


^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2018-05-22 15:29 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2018-05-21  9:27 [PATCH 0/4] Cleanup alloc_reserved_tree_block signature Nikolay Borisov
2018-05-21  9:27 ` [PATCH 1/4] btrfs: Remove fs_info argument from alloc_reserved_tree_block Nikolay Borisov
2018-05-22 15:22   ` David Sterba
2018-05-21  9:27 ` [PATCH 2/4] btrfs: Simplify alloc_reserved_tree_block interface Nikolay Borisov
2018-05-22 15:22   ` David Sterba
2018-05-21  9:27 ` [PATCH 3/4] btrfs: Pass btrfs_delayed_extent_op to alloc_reserved_tree_block Nikolay Borisov
2018-05-22 15:22   ` David Sterba
2018-05-21  9:27 ` [PATCH 4/4] btrfs: Streamline shared ref check in alloc_reserved_tree_block Nikolay Borisov
2018-05-22 15:23   ` David Sterba
2018-05-22 15:26 ` [PATCH 0/4] Cleanup alloc_reserved_tree_block signature David Sterba

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).