lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOzc2pxAG2-y7eNTbhDzh6X_Aqzj4o7BVkzudmhdkTy6rghU7A@mail.gmail.com>
Date:   Wed, 16 Nov 2022 11:49:40 -0800
From:   Vishal Moola <vishal.moola@...il.com>
To:     Matthew Wilcox <willy@...radead.org>
Cc:     linux-mm@...ck.org, linux-fsdevel@...r.kernel.org,
        linux-kernel@...r.kernel.org, linux-ext4@...r.kernel.org,
        akpm@...ux-foundation.org, naoya.horiguchi@....com, tytso@....edu
Subject: Re: [PATCH 1/4] ext4: Convert move_extent_per_page() to use folios

On Wed, Nov 16, 2022 at 12:09 AM Matthew Wilcox <willy@...radead.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.

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ