From: Damien Le Moal <dlemoal@kernel.org>
To: Christoph Hellwig <hch@infradead.org>,
Matthew Wilcox <willy@infradead.org>
Cc: "Darrick J. Wong" <djwong@kernel.org>,
Johannes Thumshirn <jth@kernel.org>,
linux-fsdevel@vger.kernel.org,
Johannes Thumshirn <johannes.thumshirn@wdc.com>
Subject: Re: [PATCH] zonefs: move super block reading from page to folio
Date: Wed, 5 Jun 2024 07:30:29 +0900 [thread overview]
Message-ID: <492e475b-d829-42fe-a0ca-7f32f630a06a@kernel.org> (raw)
In-Reply-To: <Zl6nKsdp09Yrrpdh@infradead.org>
On 6/4/24 14:33, Christoph Hellwig wrote:
> On Sat, Jun 01, 2024 at 06:51:45PM +0100, Matthew Wilcox wrote:
>> On Fri, May 31, 2024 at 10:28:50AM +0900, Damien Le Moal wrote:
>>>>> This will stop working at some point. It'll return NULL once we get
>>>>> to the memdesc future (because the memdesc will be a slab, not a folio).
>>>>
>>>> Hmmm, xfs_buf.c plays a similar trick here for sub-page buffers. I'm
>>>> assuming that will get ported to ... whatever the memdesc future holds?
>>
>> I don't think it does, exactly? Are you referring to kmem_to_page()?
>> That will continue to work. You're not trying to get a folio from a
>> slab allocation; that will start to fail.
>
> The point is that we doing block I/O on a slab allocation is heavily
> used, and zonefs does this. If you dislike going through the folio
> we can just keep using pages in zonefs for now.
>
> Eventually I'll get around lifting the logic to greedily build a bio
> from arbitrary kernel virtual addresses from various places in XFS
> into common code and we can convert to that.
>
>> I think you should use read_mapping_folio() for now instead of
>> complicating zonefs. Once there's a grand new buffer cache, switch to
>> that, but I don't think you're introducing a significant vulnerability
>> by using the block device's page cache.
>
> Please don't add pointless uses of the bdev page cache for users that
> don't need caching. This just creates more headaches later on to
> untangle it again.
OK. Will drop this patch then.
--
Damien Le Moal
Western Digital Research
prev parent reply other threads:[~2024-06-04 22:30 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-05-14 15:22 [PATCH] zonefs: move super block reading from page to folio Johannes Thumshirn
2024-05-14 19:12 ` Bill O'Donnell
2024-05-23 1:41 ` Matthew Wilcox
2024-05-23 9:54 ` Johannes Thumshirn
2024-05-23 11:48 ` Matthew Wilcox
2024-05-23 11:49 ` Johannes Thumshirn
2024-05-31 1:16 ` Darrick J. Wong
2024-05-31 1:28 ` Damien Le Moal
2024-06-01 17:51 ` Matthew Wilcox
2024-06-03 0:30 ` Damien Le Moal
2024-06-04 5:33 ` Christoph Hellwig
2024-06-04 22:30 ` Damien Le Moal [this message]
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=492e475b-d829-42fe-a0ca-7f32f630a06a@kernel.org \
--to=dlemoal@kernel.org \
--cc=djwong@kernel.org \
--cc=hch@infradead.org \
--cc=johannes.thumshirn@wdc.com \
--cc=jth@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=willy@infradead.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 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).