All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v5 0/4] xfs: fix a couple sparse chunk alloc problems
@ 2026-10-05 12:01 Brian Foster
  2026-10-05 12:01 ` [PATCH v5 1/4] xfs: set minleft correctly for sparse chunk errortag allocation Brian Foster
                   ` (4 more replies)
  0 siblings, 5 replies; 6+ messages in thread
From: Brian Foster @ 2026-10-05 12:01 UTC (permalink / raw)
  To: linux-xfs; +Cc: Carlos Maiolino

Hi all,

Here's v5 of the series to fix the sparse chunk alloc shutdown. The
original report is available here[1].

This is mostly a convenience repost of v4 with a variable rename in
patch 4.

As a brief overview, the idea here is to rework the freelist calculation
helper to calculate a min and a max. The min is the historical min AGFL
requirement for the current allocation. The max is an optional value for
minleft allocations that perform at least one more allocation in the
same transaction and thus are susceptible to seeing the min AGFL
requirement increase due to level increases in the first allocation. The
specific fix is to carry the delta between the max and min into minleft
for such allocations so they are either guaranteed for a given AG or
fail gracefully before dirtying the transaction.

Thoughts, reviews, flames appreciated.

Brian

v5:
- Renamed params to xfs_alloc_longest_free_extent().
v4: https://lore.kernel.org/linux-xfs/20260923161524.416059-1-bfoster@redhat.com/
- Rebased to for-next and collected review tags.
v3: https://lore.kernel.org/linux-xfs/20260902174025.284387-1-bfoster@redhat.com/
- Added patch 3 to refactor xfs_alloc_min_freelist() and calculate
  min/max.
- Updated patch 4 to use the max value for space available and longest
  extent checks.
v2: https://lore.kernel.org/linux-xfs/20260814132239.271492-1-bfoster@redhat.com/
- Reworked fix logic into allocator instead of sparse inode alloc
  specific.
- Dropped Fixes: tag since this is no longer directly correlated to
  sparse inodes.
v1: https://lore.kernel.org/linux-xfs/20260731163337.152522-1-bfoster@redhat.com/

[1] https://lore.kernel.org/linux-xfs/20260717130429.1838767-1-matt@readmodwrite.com/


Brian Foster (4):
  xfs: set minleft correctly for sparse chunk errortag allocation
  xfs: support additional levels in the agfl minimum calculation
  xfs: calculate AGFL max to support multiple-alloc transactions
  xfs: incorporate increased AGFL min requirement for minleft allocs

 fs/xfs/libxfs/xfs_alloc.c  | 106 +++++++++++++++++++++++++++----------
 fs/xfs/libxfs/xfs_alloc.h  |   7 +--
 fs/xfs/libxfs/xfs_bmap.c   |   7 ++-
 fs/xfs/libxfs/xfs_ialloc.c |  14 ++---
 4 files changed, 93 insertions(+), 41 deletions(-)

-- 
2.55.0


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

end of thread, other threads:[~2026-10-08 13:32 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-10-05 12:01 [PATCH v5 0/4] xfs: fix a couple sparse chunk alloc problems Brian Foster
2026-10-05 12:01 ` [PATCH v5 1/4] xfs: set minleft correctly for sparse chunk errortag allocation Brian Foster
2026-10-05 12:01 ` [PATCH v5 2/4] xfs: support additional levels in the agfl minimum calculation Brian Foster
2026-10-05 12:01 ` [PATCH v5 3/4] xfs: calculate AGFL max to support multiple-alloc transactions Brian Foster
2026-10-05 12:01 ` [PATCH v5 4/4] xfs: incorporate increased AGFL min requirement for minleft allocs Brian Foster
2026-10-08 13:32 ` [PATCH v5 0/4] xfs: fix a couple sparse chunk alloc problems Carlos Maiolino

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.