]> git.baikalelectronics.ru Git - kernel.git/commit
btrfs: Move checks from btrfs_wq_run_delayed_node to btrfs_balance_delayed_items
authorNikolay Borisov <nborisov@suse.com>
Mon, 23 Oct 2017 10:51:49 +0000 (13:51 +0300)
committerDavid Sterba <dsterba@suse.com>
Mon, 22 Jan 2018 15:08:11 +0000 (16:08 +0100)
commited19ddd1ef2a6942550bbe7b1f1ac856e140fe29
treeea16b9b6075c751cb46d87aa7869494e76df73f1
parentbd98c91b98a8f2494c9c61f341277dec67acb2aa
btrfs: Move checks from btrfs_wq_run_delayed_node to btrfs_balance_delayed_items

btrfs_balance_delayed_items is the sole caller of
btrfs_wq_run_delayed_node and already includes one of the checks whether
the delayed inodes should be run. On the other hand
btrfs_wq_run_delayed_node duplicates that check and performs an
additional one for wq congestion.

Let's remove the duplicate check and move the congestion one in
btrfs_balance_delayed_items, leaving btrfs_wq_run_delayed_node to only
care about setting up the wq run. No functional changes.

Signed-off-by: Nikolay Borisov <nborisov@suse.com>
Reviewed-by: Qu Wenruo <wqu@suse.com>
Signed-off-by: David Sterba <dsterba@suse.com>
fs/btrfs/delayed-inode.c