From: Vishal Moola <vishal.moola@gmail.com>
To: Matthew Wilcox <willy@infradead.org>
Cc: linux-mm@kvack.org, linux-fsdevel@vger.kernel.org,
linux-kernel@vger.kernel.org, linux-ext4@vger.kernel.org,
akpm@linux-foundation.org, naoya.horiguchi@nec.com,
tytso@mit.edu
Subject: Re: [PATCH 1/4] ext4: Convert move_extent_per_page() to use folios
Date: Wed, 16 Nov 2022 11:49:40 -0800 [thread overview]
Message-ID: <CAOzc2pxAG2-y7eNTbhDzh6X_Aqzj4o7BVkzudmhdkTy6rghU7A@mail.gmail.com> (raw)
In-Reply-To: <Y3SaskD7QurUVJFr@casper.infradead.org>
On Wed, Nov 16, 2022 at 12:09 AM Matthew Wilcox <willy@infradead.org> wrote:
>
> On Tue, Nov 15, 2022 at 06:10:08PM -0800, Vishal Moola (Oracle) wrote:
> > {
> > struct inode *orig_inode = file_inode(o_filp);
> > struct page *pagep[2] = {NULL, NULL};
> > + struct folio *folio[2] = {NULL, NULL};
>
> I have a feeling that mext_page_double_lock() should also be converted
> to use folios. But this makes me nervous:
>
> int blocks_per_page = PAGE_SIZE >> orig_inode->i_blkbits;
>
> and I'm not sure what will happen if one or both of the orig_page
> and donor_page is large -- possibly different sizes of large.
>
> Obviously ext4 doesn't allow large folios today, but it would be good to
> get some reasoning about why this isn't laying a trap for later (or at
> least assertions that neither folio is large so that there's an obvious
> scream instead of silent data corruption).
I had thought once mext_page_mkuptodate() and block_commit_write()
were converted to folios, large folios wouldn't be a problem. I hadn't
considered
that the folios may be of different sizes. I can add assertions about both
folios being large and the same size in v2.
next prev parent reply other threads:[~2022-11-16 19:49 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2022-11-16 2:10 [PATCH 0/4] Removing the try_to_release_page() wrapper Vishal Moola (Oracle)
2022-11-16 2:10 ` [PATCH 1/4] ext4: Convert move_extent_per_page() to use folios Vishal Moola (Oracle)
2022-11-16 8:09 ` Matthew Wilcox
2022-11-16 19:49 ` Vishal Moola [this message]
2022-11-16 2:10 ` [PATCH 2/4] khugepage: Replace try_to_release_page() with filemap_release_folio() Vishal Moola (Oracle)
2022-11-16 2:10 ` [PATCH 3/4] memory-failure: Convert truncate_error_page() to use folio Vishal Moola (Oracle)
2022-11-17 5:49 ` HORIGUCHI NAOYA(堀口 直也)
2022-11-16 2:10 ` [PATCH 4/4] folio-compat: Remove try_to_release_page() Vishal Moola (Oracle)
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=CAOzc2pxAG2-y7eNTbhDzh6X_Aqzj4o7BVkzudmhdkTy6rghU7A@mail.gmail.com \
--to=vishal.moola@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=linux-ext4@vger.kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=naoya.horiguchi@nec.com \
--cc=tytso@mit.edu \
--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