From patchwork Sat Jul 8 08:57:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 13305630 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 4D016EB64DC for ; Sat, 8 Jul 2023 08:57:39 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id A70B06B0071; Sat, 8 Jul 2023 04:57:37 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 9F9E08D0002; Sat, 8 Jul 2023 04:57:37 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 8C2636B0072; Sat, 8 Jul 2023 04:57:37 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0010.hostedemail.com [216.40.44.10]) by kanga.kvack.org (Postfix) with ESMTP id 5F1D08D0002 for ; Sat, 8 Jul 2023 04:57:37 -0400 (EDT) Received: from smtpin08.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay10.hostedemail.com (Postfix) with ESMTP id DEBAEC015A for ; Sat, 8 Jul 2023 08:57:36 +0000 (UTC) X-FDA: 80987841312.08.8D1A13D Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by imf01.hostedemail.com (Postfix) with ESMTP id 8FC8440013 for ; Sat, 8 Jul 2023 08:57:34 +0000 (UTC) Authentication-Results: imf01.hostedemail.com; dkim=none; spf=pass (imf01.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1688806655; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding:in-reply-to: references; bh=BuYA0wfn3H+eqdQLF8nN49hmAN5Ii+YUR/sv8joyKyI=; b=qMnGA6R4c5S2CJKnYQZB1d5ZlWBlwqKVjIftaFmybhAwTokogX485ae7Hau+yyDXOvMf2R YdycBhqRWeizukapDxnHEFkEU0OyrdPd4/HAuW0P2+Q8YgvtF57HweARoIwzlOKBei0wF4 RwDCEWbmfbmZ7f/7sHoV74lANJxv4IE= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1688806655; a=rsa-sha256; cv=none; b=BiKpEIghXJ+p12SeeBus70nfbyocvR7IqVZP7nsRh0sWiepzEkE/Ur48TU0ZI6idu+eOPd KHXGhWvu7UvLvoPiJt66/bLAK4CJylLke9EzOs8PZoBVa88PwFWDdhripZMIw6XjlaWpCo YdsDVl1tSgBQbO7BmFu7YiL0PSvOarE= ARC-Authentication-Results: i=1; imf01.hostedemail.com; dkim=none; spf=pass (imf01.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com; dmarc=pass (policy=quarantine) header.from=huawei.com Received: from canpemm500002.china.huawei.com (unknown [172.30.72.55]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Qykdd5Fb2zTkg4; Sat, 8 Jul 2023 16:56:21 +0800 (CST) Received: from huawei.com (10.174.151.185) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.27; Sat, 8 Jul 2023 16:57:28 +0800 From: Miaohe Lin To: , CC: , , Subject: [PATCH 0/8] A few fixup and cleanup patches for memory-failure Date: Sat, 8 Jul 2023 16:57:36 +0800 Message-ID: <20230708085744.3599311-1-linmiaohe@huawei.com> X-Mailer: git-send-email 2.33.0 MIME-Version: 1.0 X-Originating-IP: [10.174.151.185] X-ClientProxiedBy: dggems706-chm.china.huawei.com (10.3.19.183) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: 8FC8440013 X-Rspam-User: X-Rspamd-Server: rspam11 X-Stat-Signature: mzitsd8sdwbymcyy66g6d7oh4thdmnhn X-HE-Tag: 1688806654-600400 X-HE-Meta: U2FsdGVkX1+OJr5AxpLyNEgAHhqjkAOqPrM24Lx2hQuWBN7gDZQBJa2Lk88VMidGBAPTpisNGj1hY6TcKL0FzeLkVs3tgAALuvD5cZTJNLunfgm6UO9bVAQs3BTmtYDVeuEbXD3xGAb+ikJzpYROSXvb60IGbsA/7Wu3dqEUjo4tLR0p84PErVoPwOcfiw3h/g+0OZzjkE2WMiTOnRJXPaNdryPmmO15qEMrocch+3+0kZOFy7XTAnYOVJA46puclZnbDK0+Bpbxl/asV2pghp8uOBVnmFO0pECkUtVeqz1N4fr/YhkQeAE6lYPse4dNYYfu56OMWyyu2+MyM8HlqNt+91H2w7hXpbxmDGZvN2PasC2hYg0tydU5NMEJwpxqI2UwAhzttphHt3Bhb8JNvpS8SWMsrUar+l7iEF5fYRnvMr9+v8k9cX+sXd9sQSZzCoeTRzHvNfw9yhepgFt1d34Z0DBcjs/iGiYyGUTCElwcbpe2KCu8RyqFQF8a+iBge/EuIbMxd9bsiZTUMmERN8UwB0ObC/VI0jN67AvIo8YvRyi91tNYXcVfef4mwASmusmOlRAWGrXJ+8Imhe35phi3N00gJfDQFDOM+85WQiUabAnC8kRvqfuDPkREIETyInJRMTc00yAgRTua78TeyhjttHfw8o9RMsboavDeneK1mcIOBHPO1+bkraM+OkdQAqghPd7xQqtB2HXILaRzbQjvOcjOD9CKtUmY7mOHVcM4d8MFvH4z9XUYgpixw6DRNeC3smfy/zb4eqXWzyb+ZLtj3CH/FalmxZ/26+7RihniXjAFRe3TAV0LJs6ca/20oLVmu++ZtfL3xhGS6fRl2SbOlRWm79h25SC45jotpBk4jcF0W7wTv3Gi/sQHml/MKilCRbTxHG8K+2zzdHxlFPlVQLyWZR2WN3a6ckISLyK+diLirC/yNtFBBjXErHYKzpW/w5NVuzvY9zHr/24 JpeHt2qh Ii9vuIGWCDbH/bZwBxLk6Bt7OeNAA75SbkKApQkRZFF1VCgmALK2v0N0qb4DHs7PdK0UEYBVrRQNPLIAV/krZXiAeUTwGr6iQ5HXQcMce2/ptqh7JbKEGjZkisIGgyoJQ0T09uXLcwgLQyep7bo/9054oQzMLbL9yOZbcjZWfepL9+MY= 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: Hi everyone, This series contains a few fixup patches to fix potential permanently locked hpage, fix race window when trying to get hugetlb folio and so on. Also there is minor cleanup for comments and codestyle. More details can be found in the respective changelogs. Thanks! Miaohe Lin (8): mm: memory-failure: fix potential permanently locked hpage mm: memory-failure: ensure moving HWPoison flag to the raw error pages mm: memory-failure: Don't account hwpoison_filter() filtered pages mm: memory-failure: use local variable huge to check hugetlb page mm: memory-failure: remove unneeded header files mm: memory-failure: minor cleanup for comments and codestyle mm: memory-failure: fetch compound head after extra page refcnt is held mm: memory-failure: fix race window when trying to get hugetlb folio mm/memory-failure.c | 49 +++++++++++++++++++++++++++------------------ 1 file changed, 30 insertions(+), 19 deletions(-)