From: Qu Wenruo <wqu@suse.com>
To: linux-btrfs@vger.kernel.org
Subject: [PATCH 0/2] btrfs: defrag related to corncer case handling
Date: Tue, 17 Nov 2026 07:59:02 +1030 [thread overview]
Message-ID: <cover.1794864101.git.wqu@suse.com> (raw)
The first one is a Sashiko report that we can step into the next inode
and continue looping unnecessarily. Fix it by re-ordering the checks.
The second one is another minor corner case where if the defrag range
starts inside the last extent, we may skip a valid defrag target.
Fix it by doing the backward search properly.
Qu Wenruo (2):
btrfs: defrag: break the loop early in defrag_get_extent()
btrfs: defrag: fix missed extent when the lookup lands on the next
inode
fs/btrfs/defrag.c | 25 +++++++++++++++++--------
1 file changed, 17 insertions(+), 8 deletions(-)
--
2.56.0
next reply other threads:[~2026-11-16 21:29 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-11-16 21:29 Qu Wenruo [this message]
2026-11-16 21:29 ` [PATCH 1/2] btrfs: defrag: break the loop early in defrag_get_extent() Qu Wenruo
2026-11-16 21:29 ` [PATCH 2/2] btrfs: defrag: fix missed extent when the lookup lands on the next inode Qu Wenruo
2026-11-17 15:49 ` [PATCH 0/2] btrfs: defrag related to corncer case handling Filipe Manana
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=cover.1794864101.git.wqu@suse.com \
--to=wqu@suse.com \
--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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.