From patchwork Wed Jun 12 07:18:33 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 13694555 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 8D40416C6A5; Wed, 12 Jun 2024 07:22:54 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=45.249.212.188 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718176977; cv=none; b=U2KtFnMCaXPGdxZF/UxWUQnN44CgHWxtczVX8G4vUamKQFqe1niwW39FhM4i/RpDw/3sjPPffRIFbyqFtAz6Xnk+zTobkajtOJMpu0wSJBwno1zPzC4c3zo8tTxxJDxn9dPDiB1hRjschRSFgr984lCSXdQIAfwDwZGTbxyS/lI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1718176977; c=relaxed/simple; bh=O3JIof6r7PdMFJ4F5QZWltFUWEUomewKnebj+j/QRFY=; h=From:To:CC:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=Y3tCKNfYzOw9apcZFsTKTRh1KXPs8DOEwVeCNAMSBaAxyVdJvEOX66ihEMQO2cLgkzllQeEhhivdP605pSQJHHz74kn/7XRHELqCXEINe3jQiEcFhJEmMShdZZVeGT0X8S3ABD8NVMbHacBxAEdhRkBZfPTAF0n1oR++iFog3ZQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com; spf=pass smtp.mailfrom=huawei.com; arc=none smtp.client-ip=45.249.212.188 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=quarantine dis=none) header.from=huawei.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=huawei.com Received: from mail.maildlp.com (unknown [172.19.163.252]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4VzcR920tHzdfyD; Wed, 12 Jun 2024 15:21:25 +0800 (CST) Received: from canpemm500002.china.huawei.com (unknown [7.192.104.244]) by mail.maildlp.com (Postfix) with ESMTPS id 8FBAC180AAB; Wed, 12 Jun 2024 15:22:52 +0800 (CST) Received: from huawei.com (10.173.127.72) by canpemm500002.china.huawei.com (7.192.104.244) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id 15.1.2507.39; Wed, 12 Jun 2024 15:22:24 +0800 From: Miaohe Lin To: , , CC: , , , , Subject: [PATCH v3 11/13] mm/memory-failure: fix comment of get_hwpoison_page() Date: Wed, 12 Jun 2024 15:18:33 +0800 Message-ID: <20240612071835.157004-12-linmiaohe@huawei.com> X-Mailer: git-send-email 2.33.0 In-Reply-To: <20240612071835.157004-1-linmiaohe@huawei.com> References: <20240612071835.157004-1-linmiaohe@huawei.com> Precedence: bulk X-Mailing-List: linux-edac@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-ClientProxiedBy: dggems703-chm.china.huawei.com (10.3.19.180) To canpemm500002.china.huawei.com (7.192.104.244) When return value is 0, it could also means the page is free hugetlb page or free buddy page. Fix the corresponding comment. Signed-off-by: Miaohe Lin --- mm/memory-failure.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/mm/memory-failure.c b/mm/memory-failure.c index bb8e79381c1f..475524f79550 100644 --- a/mm/memory-failure.c +++ b/mm/memory-failure.c @@ -1525,7 +1525,7 @@ static int __get_unpoison_page(struct page *page) * the given page has PG_hwpoison. So it's never reused for other page * allocations, and __get_unpoison_page() never races with them. * - * Return: 0 on failure, + * Return: 0 on failure or free buddy (hugetlb) page, * 1 on success for in-use pages in a well-defined state, * -EIO for pages on which we can not handle memory errors, * -EBUSY when get_hwpoison_page() has raced with page lifecycle