From patchwork Fri Jul 7 15:39:53 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kemeng Shi X-Patchwork-Id: 13304515 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 C8B16EB64D9 for ; Fri, 7 Jul 2023 07:39:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 50C9E8D0002; Fri, 7 Jul 2023 03:39:18 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 4BAD28D0001; Fri, 7 Jul 2023 03:39:18 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 3D0108D0002; Fri, 7 Jul 2023 03:39:18 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0011.hostedemail.com [216.40.44.11]) by kanga.kvack.org (Postfix) with ESMTP id 2EA098D0001 for ; Fri, 7 Jul 2023 03:39:18 -0400 (EDT) Received: from smtpin06.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay05.hostedemail.com (Postfix) with ESMTP id A775740CA0 for ; Fri, 7 Jul 2023 07:39:17 +0000 (UTC) X-FDA: 80984015154.06.0445588 Received: from dggsgout12.his.huawei.com (dggsgout12.his.huawei.com [45.249.212.56]) by imf23.hostedemail.com (Postfix) with ESMTP id ED4AC140010 for ; Fri, 7 Jul 2023 07:39:13 +0000 (UTC) Authentication-Results: imf23.hostedemail.com; dkim=none; spf=none (imf23.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.56) smtp.mailfrom=shikemeng@huaweicloud.com; dmarc=none ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1688715555; a=rsa-sha256; cv=none; b=ECC+Up0V/DcOCDjZMd6nvwcltzuIrY1MrzFzs1wWpHfrANsFHXgH4iJWdbXku+0FPvlacV hyJmbY0WcirX7KZGfnBx41jCBcL57QkHzd3JbtNGQODNN0XE1b1h0tC6sh1tpUfZBS7Q2v 6aPgC7cNdtDPFrt/aRCMxg20qx0nR+E= ARC-Authentication-Results: i=1; imf23.hostedemail.com; dkim=none; spf=none (imf23.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.56) smtp.mailfrom=shikemeng@huaweicloud.com; dmarc=none ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1688715555; h=from:from:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version:content-type: content-transfer-encoding:content-transfer-encoding:in-reply-to: references; bh=sdjG0LyDq8odSl6EE5xKhHAHfN2DjJJ3ZUdDCc9WmwI=; b=UpEe7BhdH65LP+QFFjWGCAGFL5k3uEH6ADZ2s0KiLfMltuZ3Yiel+zG5B6WVnpvG/bpOPH 9pzwiBPC6Fv/4ZYdvC26bYxIQcPK1cpJ28M7adUuVuhAPCoL3unwbI1E739PeF7eHfWI0N VnI1IW6ssreE3r1wmRngAm3d/cxIaD0= Received: from mail02.huawei.com (unknown [172.30.67.143]) by dggsgout12.his.huawei.com (SkyGuard) with ESMTP id 4Qy4yt6fhlz4f3jMg for ; Fri, 7 Jul 2023 15:39:02 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.124.27]) by APP2 (Coremail) with SMTP id Syh0CgDXsc8XwadktcpJNQ--.23358S2; Fri, 07 Jul 2023 15:39:05 +0800 (CST) From: Kemeng Shi To: akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: [PATCH] mm: correct stale comment of function check_pte Date: Fri, 7 Jul 2023 23:39:53 +0800 Message-Id: <20230707153953.1380615-1-shikemeng@huaweicloud.com> X-Mailer: git-send-email 2.30.0 MIME-Version: 1.0 X-CM-TRANSID: Syh0Cg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 5vklyvpphqwq5kxd4v5lfo033gof0z/ X-CFilter-Loop: Reflected X-Rspam-User: X-Rspamd-Server: rspam06 X-Rspamd-Queue-Id: ED4AC140010 X-Stat-Signature: xfra781548iok1jknozcq4fmtxorjqi7 X-HE-Tag: 1688715553-162992 X-HE-Meta: U2FsdGVkX1/iawgTmzT3J/omJl92vgKtjzTYiRN4+vAIl5qCo/BDNBO35HJlTvweefZDyGGBCimGN/DwRJXrYg1uQlrZuos85/LhTP/cfOGcbFMpU3MJ59pA5dkyI3x2pQUA+pPB1T75FKtXQFXJ7DuqsQpKE8SsoGMd5r+P+/44OwxzztlBliTq4ovKguS5iLIHNaRnckom5uU60h7gLbYP5lJTFZiMxjnJOOHwvUXJSdTmPcs9Q3YsJiFd5bLQ/b2E4IZO70CQ+JLoGvBhaxPhsqgr6VuuZ6NejIh8vmIos0P1epdBtf1NuUaJFZA5Bo9GaLTsWN88CFZUpiPARl9FqL6HzzcKTYGYiHYud/Kmlu11Bhd3x2NFqajdPu3vvMeOgtOXaMUzmHmtPBEXjlfX12HP0Mf1cIpmBhTMBQjo0OZcY6+CcobPp6s2F0TqcRZjdRv5bzUQcjv0jOaRd0DGohYl6qRgsbrtgIjgdpjP96xiiYincWIF5+WQjLvGtjsskvuD4gCZqErm4pyVKJ1aogWr318k7wUrlwOmqbgAWZxMqYdptT1pZNbDO7fjKseSRrViPPgswE0Inr4IZKKhBW5lGBRTaGqfM5fikkm8FJVc/qbKz4OXjMnHyb4Zq8BuSgyEkhTGe8BmfpRZi9DGjNMQMdPcY74c2L0LmxNGqL7pxdQJje6gODHehsvpLwbNd6PGCZ8uax2WqZBcyne3CVi6eoY48GZGKe1oedFc/7bhKXKe1E1iTn5oOb+rSC2xmHA60OO2Vr77Vk/9Y7I8zaKrJgWg1ltmDV2zH2RWYeMzUHBbeOIrlEQ3o30/0/cQoYYIOGNjMXQYXWcxl93UPvGfXqwLiYy0NVTpYTVzoFTV+76m8SGy9zfQxZkw7y1eytaLZgDZ3oZneriN/7CI+HoMVwY3ONj8lBVGjLfPt/2HY6lD7gsvQM4xZVcsx1EzpMPPWkAs1fxCnvW p8KmrsqX zdrQaJVU0rY/9zZQCADLTsMeddtFVBbrV1sGWuA/oki5maOn/REcq8U+ukogeAdruKJ9uuyO40+IjdcYZBxSWaBIW42R5IaqW1sX+Go3I55boFWuX0dLlzlYXT5P4yZQ4VxsqPfWZPhL1pX5zdF9i2bHfDz52lOOuFZaicaISpqtLIS4sDA4VvpK6BwqJhnzF9dgINlwRWn1PUfWNrp1//bjY1zj6W6NI1NsyS66RAtzNvJDielKsRlW4pmTf7vVHe5ZBux5hIPUepBc= 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: Commit 2aff7a4755bed ("mm: Convert page_vma_mapped_walk to work on PFNs") replaced page with pfns in page_vma_mapped_walk structure and updated "@pvmw->page" to "@pvmw->pfn" in comment of function page_vma_mapped_walk. This patch update stale "page" to "pfn" in comment of check_pte. Signed-off-by: Kemeng Shi Reviewed-by: Matthew Wilcox (Oracle) --- mm/page_vma_mapped.c | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/mm/page_vma_mapped.c b/mm/page_vma_mapped.c index 6ac795a87279..dbe2418b44e5 100644 --- a/mm/page_vma_mapped.c +++ b/mm/page_vma_mapped.c @@ -73,20 +73,22 @@ static bool map_pte(struct page_vma_mapped_walk *pvmw, spinlock_t **ptlp) } /** - * check_pte - check if @pvmw->page is mapped at the @pvmw->pte - * @pvmw: page_vma_mapped_walk struct, includes a pair pte and page for checking + * check_pte - check if [pvmw->pfn, @pvmw->pfn + @pvmw->nr_pages) is + * mapped at the @pvmw->pte + * @pvmw: page_vma_mapped_walk struct, includes a pair pte and pfn range + * for checking * - * page_vma_mapped_walk() found a place where @pvmw->page is *potentially* + * page_vma_mapped_walk() found a place where pfn range is *potentially* * mapped. check_pte() has to validate this. * * pvmw->pte may point to empty PTE, swap PTE or PTE pointing to * arbitrary page. * * If PVMW_MIGRATION flag is set, returns true if @pvmw->pte contains migration - * entry that points to @pvmw->page or any subpage in case of THP. + * entry that points to [pvmw->pfn, @pvmw->pfn + @pvmw->nr_pages) * * If PVMW_MIGRATION flag is not set, returns true if pvmw->pte points to - * pvmw->page or any subpage in case of THP. + * [pvmw->pfn, @pvmw->pfn + @pvmw->nr_pages) * * Otherwise, return false. *