From patchwork Wed Dec 8 04:22:09 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Matthew Wilcox (Oracle)" X-Patchwork-Id: 12663703 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from kanga.kvack.org (kanga.kvack.org [205.233.56.17]) by smtp.lore.kernel.org (Postfix) with ESMTP id 19900C433F5 for ; Wed, 8 Dec 2021 06:22:07 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id DE3AD6B007B; Wed, 8 Dec 2021 01:19:05 -0500 (EST) Received: by kanga.kvack.org (Postfix, from userid 40) id D92BA6B0081; Wed, 8 Dec 2021 01:19:05 -0500 (EST) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id C81CF6B0082; Wed, 8 Dec 2021 01:19:05 -0500 (EST) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (relay025.a.hostedemail.com [64.99.140.25]) by kanga.kvack.org (Postfix) with ESMTP id B9E116B007B for ; Wed, 8 Dec 2021 01:19:05 -0500 (EST) Received: by unirelay09.hostedemail.com (Postfix, from userid 108) id 3063020F71; Wed, 8 Dec 2021 06:17:52 +0000 (UTC) Received: by unirelay09.hostedemail.com (Postfix, from userid 108) id 1C0EE2074E; Wed, 8 Dec 2021 05:33:53 +0000 (UTC) Received: from smtpin20.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay09.hostedemail.com (Postfix) with ESMTP id 8C2682138A for ; Wed, 8 Dec 2021 04:23:14 +0000 (UTC) X-FDA: 78893332308.20.2E731C3 Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) by imf14.hostedemail.com (Postfix) with ESMTP id 3EDE8600198A for ; Wed, 8 Dec 2021 04:23:13 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=Content-Transfer-Encoding:MIME-Version: References:In-Reply-To:Message-Id:Date:Subject:Cc:To:From:Sender:Reply-To: Content-Type:Content-ID:Content-Description; bh=5xJN0Ke/RBge8yAC47u5+/emcH/Klxeoku8OPLSI/Ow=; b=ThqWMSkjkUDbbxstIeqTv1Ubuf YwM7nhdVERRrxUd7hMYHiDCuTMAe3Qkwf2qXobZiRQ8jl7+ZpNH/k3CwZCfUe7WbJ9gK2VREnO25I NEMUuF9ffXWnT7K1N1Q6sh4/PZ6stwtg7KkYVmCIQDAzqayz2Hu3kdembJY/vlMePJiWy0ddt9luT n1UUTM07y2l3x4YlQ28qFh++SVppLXo57Em+jMpxFyrPrCpWYf0CJcHG8Hvx/94hhJjwYMoyu7uI/ HOGQb5/sxBCFE0jBZ+zbWDgeGvmYzP29HmVskZDmCo0Sgx9yCJdwxngSSIX7QxjFtNwtdMguhN3sz GfHrv3Ow==; Received: from willy by casper.infradead.org with local (Exim 4.94.2 #2 (Red Hat Linux)) id 1muoU1-0084Wh-Hg; Wed, 08 Dec 2021 04:23:09 +0000 From: "Matthew Wilcox (Oracle)" To: linux-fsdevel@vger.kernel.org, linux-mm@kvack.org Cc: "Matthew Wilcox (Oracle)" Subject: [PATCH 01/48] filemap: Remove PageHWPoison check from next_uptodate_page() Date: Wed, 8 Dec 2021 04:22:09 +0000 Message-Id: <20211208042256.1923824-2-willy@infradead.org> X-Mailer: git-send-email 2.31.1 In-Reply-To: <20211208042256.1923824-1-willy@infradead.org> References: <20211208042256.1923824-1-willy@infradead.org> MIME-Version: 1.0 X-Rspamd-Server: rspam07 X-Rspamd-Queue-Id: 3EDE8600198A X-Stat-Signature: 5bdzbod34ar13y6t3boa3s5qgegs8zpi Authentication-Results: imf14.hostedemail.com; dkim=pass header.d=infradead.org header.s=casper.20170209 header.b=ThqWMSkj; spf=none (imf14.hostedemail.com: domain of willy@infradead.org has no SPF policy when checking 90.155.50.34) smtp.mailfrom=willy@infradead.org; dmarc=none X-HE-Tag: 1638937393-287393 X-Bogosity: Ham, tests=bogofilter, spamicity=0.000000, version=1.2.4 Sender: owner-linux-mm@kvack.org Precedence: bulk X-Loop: owner-majordomo@kvack.org List-ID: Pages are individually marked as suffering from hardware poisoning. Checking that the head page is not hardware poisoned doesn't make sense; we might be after a subpage. We check each page individually before we use it, so this was an optimisation gone wrong. Signed-off-by: Matthew Wilcox (Oracle) Reviewed-by: Christoph Hellwig --- mm/filemap.c | 2 -- 1 file changed, 2 deletions(-) diff --git a/mm/filemap.c b/mm/filemap.c index daa0e23a6ee6..39c4c46c6133 100644 --- a/mm/filemap.c +++ b/mm/filemap.c @@ -3253,8 +3253,6 @@ static struct page *next_uptodate_page(struct page *page, goto skip; if (!PageUptodate(page) || PageReadahead(page)) goto skip; - if (PageHWPoison(page)) - goto skip; if (!trylock_page(page)) goto skip; if (page->mapping != mapping)