gfs2 filesystem and dlm development
 help / color / mirror / Atom feed
* [PATCH v2 0/4] gfs2: stop using struct page in the log code
@ 2026-11-24 21:04 Tal Zussman
  2026-11-24 21:04 ` [PATCH v2 1/4] gfs2: make the log page pool per superblock Tal Zussman
                   ` (3 more replies)
  0 siblings, 4 replies; 8+ messages in thread
From: Tal Zussman @ 2026-11-24 21:04 UTC (permalink / raw)
  To: Andreas Gruenbacher
  Cc: gfs2, linux-kernel, Matthew Wilcox (Oracle), Tal Zussman

This series gets rid of the remaining struct page usage in the gfs2 log
code.

The log headers, descriptors, revoke blocks, and escaped block copies
are allocated as pages from a mempool, and they end up in the same bios
as the page cache buffers being journaled. The completion handler then
calls page_folio() on every segment to figure out which kind it is
looking at. That won't work once memdescs land and those pool pages are
no longer folios.

Patch 1 gives each superblock its own mempool for these blocks in place
of the global one. Patch 2 moves the blocks over to block-sized kmalloc
buffers from that pool, with their own bios and completion handler. As a
result each descriptor block is now submitted as its own bio, so patch 3
adds a plug around the log flush to let the block layer merge them back
together. Patch 4 cleans up the leftover page references in the log
code.

Tested with fio 4K write+fsync on gfs2 over virtio-blk and null_blk.
Without an I/O scheduler, patch 2 adds one write request per log flush
(196.7k to 229.5k for 32k fsyncs) and ~10 us to the p99.9 fsync latency
on null_blk (41 us to 51 us); the plug in patch 3 merges them and
restores both performance numbers to the baseline. With mq-deadline
nothing changes.

With a 1k block size on 4k pages the result is the same. Patch 1 changes
nothing by itself, patch 2 takes the write requests for 32k fsyncs from
199.5k to 232.3k, and patch 3 brings them back to 199.5k.

---
Changes in v2:
- Patch 1 (new): Make the mempool per-superblock, per Andreas.
- Patch 2: Make the per-superblock mempool be block-sized, rather than
  page-sized, per Andreas.
- Link to v1: https://patch.msgid.link/20261117-gfs2-log-folio-v1-0-35db3db42e35@columbia.edu

---
Tal Zussman (4):
      gfs2: make the log page pool per superblock
      gfs2: stop using pages for log buffers
      gfs2: plug the log writes of a flush
      gfs2: remove the remaining page references in the log code

 fs/gfs2/bmap.h       |   1 -
 fs/gfs2/incore.h     |   2 +
 fs/gfs2/log.c        |  19 ++---
 fs/gfs2/lops.c       | 222 +++++++++++++++++++++++++++++++--------------------
 fs/gfs2/lops.h       |   6 +-
 fs/gfs2/main.c       |   8 --
 fs/gfs2/ops_fstype.c |   6 ++
 fs/gfs2/util.c       |   1 -
 fs/gfs2/util.h       |   3 -
 9 files changed, 157 insertions(+), 111 deletions(-)
---
base-commit: a009501c151f7d19519312ccfa2070d30d62b249
change-id: 20261014-gfs2-log-folio-274b84f5cc07

Best regards,
--  
Tal Zussman <tz2294@columbia.edu>


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

end of thread, other threads:[~2026-11-24 21:55 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-11-24 21:04 [PATCH v2 0/4] gfs2: stop using struct page in the log code Tal Zussman
2026-11-24 21:04 ` [PATCH v2 1/4] gfs2: make the log page pool per superblock Tal Zussman
2026-11-24 21:16   ` sashiko-bot
2026-11-24 21:55     ` Tal Zussman
2026-11-24 21:04 ` [PATCH v2 2/4] gfs2: stop using pages for log buffers Tal Zussman
2026-11-24 21:21   ` sashiko-bot
2026-11-24 21:04 ` [PATCH v2 3/4] gfs2: plug the log writes of a flush Tal Zussman
2026-11-24 21:04 ` [PATCH v2 4/4] gfs2: remove the remaining page references in the log code Tal Zussman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox