[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <ZHDDFoXs51Be8FcZ@casper.infradead.org>
Date: Fri, 26 May 2023 15:32:54 +0100
From: Matthew Wilcox <willy@...radead.org>
To: Luis Chamberlain <mcgrof@...nel.org>
Cc: hughd@...gle.com, akpm@...ux-foundation.org, brauner@...nel.org,
djwong@...nel.org, p.raghav@...sung.com, da.gomez@...sung.com,
rohan.puri@...sung.com, rpuri.linux@...il.com,
a.manzanares@...sung.com, dave@...olabs.net, yosryahmed@...gle.com,
keescook@...omium.org, hare@...e.de, kbusch@...nel.org,
patches@...ts.linux.dev, linux-block@...r.kernel.org,
linux-fsdevel@...r.kernel.org, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: Re: [RFC v2 2/8] shmem: convert to use is_folio_hwpoison()
On Fri, May 26, 2023 at 12:55:46AM -0700, Luis Chamberlain wrote:
> The PageHWPoison() call can be converted over to the respective folio
> call is_folio_hwpoison(). This introduces no functional changes.
Yes, it very much does!
> @@ -4548,7 +4548,7 @@ struct page *shmem_read_mapping_page_gfp(struct address_space *mapping,
> return &folio->page;
>
> page = folio_file_page(folio, index);
> - if (PageHWPoison(page)) {
> + if (is_folio_hwpoison(folio)) {
> folio_put(folio);
Imagine you have an order-9 folio and one of the pages in it gets
HWPoison. Before, you can read the other 511 pages in the folio.
After your patch, you can't read any of them. You've effectively
increased the blast radius of any hwerror, and I don't think that's an
acceptable change.
Powered by blists - more mailing lists