All of lore.kernel.org
 help / color / mirror / Atom feed
From: Qu Wenruo <wqu@suse.com>
To: linux-btrfs@vger.kernel.org
Subject: [PATCH 0/3] btrfs: fsstress hang fix for large data folios
Date: Fri,  4 Apr 2025 12:17:39 +1030	[thread overview]
Message-ID: <cover.1743731232.git.wqu@suse.com> (raw)

With my local large data folios enabled btrfs, fsstress can hit a hang
where lock_delalloc_folios() fails to lock a folio.

It turns our that filemap_get_folios_contig() can return duplicated
folios, which is fatal for lock_delalloc_folios() and
unlock_delalloc_folio().

The series here is to address the annonying filemap_get_folios_contig()
behavior for large folios.

The first patch is a small cleanup to remove unnecessary early exits,
exposed during the next folio_contains() change.

The second patch uses folio_contains() to handle EOF detection for large
folios.

The final one is the fix of filemap_get_folios_contig(), by getting rid
of it.


Qu Wenruo (3):
  btrfs: remove unnecessary early exits in delalloc folio lock and
    unlock
  btrfs: use folio_contains() for EOF detection
  btrfs: get rid of filemap_get_folios_contig() calls

 fs/btrfs/compression.c           |  2 +-
 fs/btrfs/extent_io.c             | 20 +++++---------------
 fs/btrfs/tests/extent-io-tests.c |  3 +--
 3 files changed, 7 insertions(+), 18 deletions(-)

-- 
2.49.0


             reply	other threads:[~2025-04-04  1:48 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-04-04  1:47 Qu Wenruo [this message]
2025-04-04  1:47 ` [PATCH 1/3] btrfs: remove unnecessary early exits in delalloc folio lock and unlock Qu Wenruo
2025-04-04 16:04   ` Filipe Manana
2025-04-04 21:44     ` Qu Wenruo
2025-04-05 17:54       ` Filipe Manana
2025-04-04  1:47 ` [PATCH 2/3] btrfs: use folio_contains() for EOF detection Qu Wenruo
2025-04-04 16:09   ` Filipe Manana
2025-04-07 18:39   ` David Sterba
2025-04-07 21:58     ` Qu Wenruo
2025-04-08 23:12       ` David Sterba
2025-04-08 23:16         ` Qu Wenruo
2025-04-04  1:47 ` [PATCH 3/3] btrfs: get rid of filemap_get_folios_contig() calls Qu Wenruo
2025-04-04 16:38   ` Filipe Manana
2025-04-04 21:51     ` Qu Wenruo
2025-04-04 22:00       ` Qu Wenruo
2025-04-22 22:47   ` Qu Wenruo

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.1743731232.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.