From: Pankaj Raghav <p.raghav@samsung.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: Jens Axboe <axboe@kernel.dk>, Christoph Hellwig <hch@lst.de>,
<linux-block@vger.kernel.org>,
Tetsuo Handa <penguin-kernel@i-love.sakura.ne.jp>,
Hannes Reinecke <hare@suse.de>
Subject: Re: brd in a memdesc world
Date: Wed, 13 Mar 2024 19:36:01 +0100 [thread overview]
Message-ID: <4605ebb7-2fcf-4570-b849-7aaa80a21954@samsung.com> (raw)
In-Reply-To: <ZfHwXLr54bWl1fns@casper.infradead.org>
>>> Currently brd uses page->index as a debugging check. In the memdesc
>>> future, struct page has no members (you could store a small amount of
>>> information in it, but I'm not willing to commit to more than a few bits).
>>>
>>
>> Shouldn't we change brd to use folios? Once we do that, this will not
>> be a problem any more right?
>
> We certainly could change brd to use folios. But why would we want to?
> Hannes' work always allocates memory of a fixed size (a fixed multiple
> of PAGE_SIZE). Folios are a medium-weight data structure (probably
> about 80 bytes once we get to memdescs). They support a lot of things,
> eg belonging to an inode, having an index, being mappable to userspace,
> being lockable, accountable to memcgs, allowing extra private data,
> knowing their own size, ...
>
Got it! Probably moving to folios just for the sake of retaining the
debugging checks is not enough.
> None of those things are needed for brd's uses. All brd needs is to
> be able to allocate, kmap and free chunks of memory. Unless there are
> plans to do more than this.
>
I remember he mentioned he wanted to support bigger logical block sizes
in brd, in which case moving to folios might be justified.
next prev parent reply other threads:[~2024-03-13 18:36 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20240312174020eucas1p29cf41360c934c674fd1f36a808078e25@eucas1p2.samsung.com>
2024-03-12 17:40 ` brd in a memdesc world Matthew Wilcox
2024-03-13 17:15 ` Pankaj Raghav
2024-03-13 18:28 ` Matthew Wilcox
2024-03-13 18:36 ` Pankaj Raghav [this message]
2024-03-13 19:17 ` Matthew Wilcox
2024-03-14 11:11 ` Hannes Reinecke
2024-03-14 14:15 ` Matthew Wilcox
2024-03-13 19:40 ` Jens Axboe
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=4605ebb7-2fcf-4570-b849-7aaa80a21954@samsung.com \
--to=p.raghav@samsung.com \
--cc=axboe@kernel.dk \
--cc=hare@suse.de \
--cc=hch@lst.de \
--cc=linux-block@vger.kernel.org \
--cc=penguin-kernel@i-love.sakura.ne.jp \
--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