From patchwork Tue Jun 28 13:28:22 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Miaohe Lin X-Patchwork-Id: 12898288 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 BB04FC43334 for ; Tue, 28 Jun 2022 13:28:46 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id D71E46B0072; Tue, 28 Jun 2022 09:28:44 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id CF9698E0006; Tue, 28 Jun 2022 09:28:44 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id B4C668E0003; Tue, 28 Jun 2022 09:28:44 -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 98AC76B0072 for ; Tue, 28 Jun 2022 09:28:44 -0400 (EDT) Received: from smtpin25.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay07.hostedemail.com (Postfix) with ESMTP id 67CAE20996 for ; Tue, 28 Jun 2022 13:28:44 +0000 (UTC) X-FDA: 79627724568.25.50C840A Received: from szxga01-in.huawei.com (szxga01-in.huawei.com [45.249.212.187]) by imf18.hostedemail.com (Postfix) with ESMTP id 6AAFB1C0034 for ; Tue, 28 Jun 2022 13:28:43 +0000 (UTC) Received: from canpemm500002.china.huawei.com (unknown [172.30.72.54]) by szxga01-in.huawei.com (SkyGuard) with ESMTP id 4LXQPN4Jq8zkX1b; Tue, 28 Jun 2022 21:27:20 +0800 (CST) Received: from huawei.com (10.175.124.27) 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.2375.24; Tue, 28 Jun 2022 21:28:39 +0800 From: Miaohe Lin To: CC: , , , , , , Subject: [PATCH v2 03/16] mm/huge_memory: fix comment of __pud_trans_huge_lock Date: Tue, 28 Jun 2022 21:28:22 +0800 Message-ID: <20220628132835.8925-4-linmiaohe@huawei.com> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20220628132835.8925-1-linmiaohe@huawei.com> References: <20220628132835.8925-1-linmiaohe@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.124.27] X-ClientProxiedBy: dggems701-chm.china.huawei.com (10.3.19.178) To canpemm500002.china.huawei.com (7.192.104.244) X-CFilter-Loop: Reflected ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1656422924; a=rsa-sha256; cv=none; b=H3vuFqKdnFHy03ScQk8fMNKoB61oD6t9XXiU6g9rc3kdfuorrRs7gL4/UruR6fhpS54q6F XsKrM9Bls9MFx6SdH3ZGDsr1IH/F3j9CAuFiH/TOUOabYmuZ6IUfj4cZ6exj+I8L4nJmeg AA8YjFe2/mJm9R3OB3izVFK7YuI05h0= ARC-Authentication-Results: i=1; imf18.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf18.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.187 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1656422924; 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:in-reply-to:references:references; bh=WfcX0yLgOPdrbHZ2HW4UXhn9HneP43bMBjZ15BWwE+4=; b=tYvr/HCEyNeLGJcyvw/fL2SI7+AegTU1WrVW7eOasPs7au+QHZFcY3NIcwBH0jIBiXQx0I KM0MsDGWvsjxAsB/eVuYFA9xpp1fT8sbiEqCQtwHpRDPQCyGzN94HsFWOd2XfS6r1VdGA8 pEaBbxkWadh/ZKI3ask0gkgoNNzhHMg= X-Rspam-User: X-Stat-Signature: euszm1fu4gb4d1zgpsfq5ey8w1r9s3ao X-Rspamd-Queue-Id: 6AAFB1C0034 Authentication-Results: imf18.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf18.hostedemail.com: domain of linmiaohe@huawei.com designates 45.249.212.187 as permitted sender) smtp.mailfrom=linmiaohe@huawei.com X-Rspamd-Server: rspam03 X-HE-Tag: 1656422923-873096 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: __pud_trans_huge_lock returns page table lock pointer if a given pud maps a thp instead of 'true' since introduced. Fix corresponding comments. Signed-off-by: Miaohe Lin Acked-by: Muchun Song --- mm/huge_memory.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/mm/huge_memory.c b/mm/huge_memory.c index 76dc6d003245..f7164ef8b6e3 100644 --- a/mm/huge_memory.c +++ b/mm/huge_memory.c @@ -2006,10 +2006,10 @@ spinlock_t *__pmd_trans_huge_lock(pmd_t *pmd, struct vm_area_struct *vma) } /* - * Returns true if a given pud maps a thp, false otherwise. + * Returns page table lock pointer if a given pud maps a thp, NULL otherwise. * - * Note that if it returns true, this routine returns without unlocking page - * table lock. So callers must unlock it. + * Note that if it returns page table lock pointer, this routine returns without + * unlocking page table lock. So callers must unlock it. */ spinlock_t *__pud_trans_huge_lock(pud_t *pud, struct vm_area_struct *vma) {