From: Nikolay Borisov <nborisov@suse.com>
To: linux-btrfs@vger.kernel.org
Cc: dsterba@suse.cz, Nikolay Borisov <nborisov@suse.com>
Subject: [PATCH] btrfs: Remove unused variables from btrfs_async_reclaim_metadata_space
Date: Fri, 14 Jul 2017 11:46:24 +0300 [thread overview]
Message-ID: <1500021984-10079-1-git-send-email-nborisov@suse.com> (raw)
The ret from flush_space is ignored so no point in assigning it to a variable.
The ticket variable was used in the initial version of the ticketed ENOSPC
work, however Wang Xiaoguang detected a problem with this and fixed it in
ce129655c9d9 ("btrfs: introduce tickets_id to determine whether asynchronous
metadata reclaim work makes progress").
Signed-off-by: Nikolay Borisov <nborisov@suse.com>
---
fs/btrfs/extent-tree.c | 7 +------
1 file changed, 1 insertion(+), 6 deletions(-)
diff --git a/fs/btrfs/extent-tree.c b/fs/btrfs/extent-tree.c
index d57f1f161fa2..31924c834049 100644
--- a/fs/btrfs/extent-tree.c
+++ b/fs/btrfs/extent-tree.c
@@ -5057,10 +5057,7 @@ static void btrfs_async_reclaim_metadata_space(struct work_struct *work)
flush_state = FLUSH_DELAYED_ITEMS_NR;
do {
- struct reserve_ticket *ticket;
- int ret;
-
- ret = flush_space(fs_info, space_info, to_reclaim, to_reclaim,
+ flush_space(fs_info, space_info, to_reclaim, to_reclaim,
flush_state);
spin_lock(&space_info->lock);
if (list_empty(&space_info->tickets)) {
@@ -5071,8 +5068,6 @@ static void btrfs_async_reclaim_metadata_space(struct work_struct *work)
to_reclaim = btrfs_calc_reclaim_metadata_size(fs_info,
space_info,
false);
- ticket = list_first_entry(&space_info->tickets,
- struct reserve_ticket, list);
if (last_tickets_id == space_info->tickets_id) {
flush_state++;
} else {
--
2.7.4
next reply other threads:[~2017-07-14 8:46 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-07-14 8:46 Nikolay Borisov [this message]
2017-07-21 16:18 ` [PATCH] btrfs: Remove unused variables from btrfs_async_reclaim_metadata_space David Sterba
2017-07-25 14:48 ` [PATCH] btrfs: Make flush_space return void Nikolay Borisov
2017-07-26 17:31 ` David Sterba
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=1500021984-10079-1-git-send-email-nborisov@suse.com \
--to=nborisov@suse.com \
--cc=dsterba@suse.cz \
--cc=linux-btrfs@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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).