From: Matthew Wilcox <willy@infradead.org>
To: Christoph Hellwig <hch@infradead.org>
Cc: Luis Chamberlain <mcgrof@kernel.org>,
brauner@kernel.org, akpm@linux-foundation.org,
linux-fsdevel@vger.kernel.org, linux-block@vger.kernel.org,
linux-mm@kvack.org, gost.dev@samsung.com, p.raghav@samsung.com,
da.gomez@samsung.com
Subject: Re: [PATCH] swapfile: disable swapon for bs > ps devices
Date: Mon, 5 May 2025 15:40:40 +0100 [thread overview]
Message-ID: <aBjN6Bm3pwK_0WNO@casper.infradead.org> (raw)
In-Reply-To: <aBhZx_-qZCGoR7Ez@infradead.org>
On Sun, May 04, 2025 at 11:25:11PM -0700, Christoph Hellwig wrote:
> On Fri, May 02, 2025 at 04:13:09PM -0700, Luis Chamberlain wrote:
> > Devices which have a requirement for bs > ps cannot be supported for
> > swap as swap still needs work.
>
> This should work just fine for swap through intelligent enough file
> systems not using the generic ->bmap based swap path, although
> performance would still be horrible.
"intelligent enough" is doing a lot of heavy lifting there. Setting
aside that only netfs (nfs and cifs) implement ->swap_rw today, a
block fs which wanted to support sub-block-size swap accesses would
need to pad writes (not a huge problem), but on reads, it'd need to
either discard the extra data somewhere or (better) bring the other
pages into the swap cache.
Really, I think it needs a major rethink of the swap system, which is
happening anyway.
next prev parent reply other threads:[~2025-05-05 14:40 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-05-02 23:13 [PATCH] swapfile: disable swapon for bs > ps devices Luis Chamberlain
2025-05-05 6:25 ` Christoph Hellwig
2025-05-05 14:40 ` Matthew Wilcox [this message]
2025-05-05 14:21 ` Christian Brauner
2025-05-05 19:35 ` [PATCH v2] " Luis Chamberlain
2025-05-06 8:46 ` Christian Brauner
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=aBjN6Bm3pwK_0WNO@casper.infradead.org \
--to=willy@infradead.org \
--cc=akpm@linux-foundation.org \
--cc=brauner@kernel.org \
--cc=da.gomez@samsung.com \
--cc=gost.dev@samsung.com \
--cc=hch@infradead.org \
--cc=linux-block@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=mcgrof@kernel.org \
--cc=p.raghav@samsung.com \
/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).