From patchwork Thu Jul 13 17:26:36 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kemeng Shi X-Patchwork-Id: 13311651 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 D1264C001B0 for ; Thu, 13 Jul 2023 09:26:16 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2E7D78D0008; Thu, 13 Jul 2023 05:26:06 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 271468D000A; Thu, 13 Jul 2023 05:26:06 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0EC668D0008; Thu, 13 Jul 2023 05:26:06 -0400 (EDT) X-Delivered-To: linux-mm@kvack.org Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by kanga.kvack.org (Postfix) with ESMTP id D5E028D000A for ; Thu, 13 Jul 2023 05:26:05 -0400 (EDT) Received: from smtpin11.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id AB07F140168 for ; Thu, 13 Jul 2023 09:26:05 +0000 (UTC) X-FDA: 81006057090.11.0A198A2 Received: from dggsgout11.his.huawei.com (dggsgout11.his.huawei.com [45.249.212.51]) by imf08.hostedemail.com (Postfix) with ESMTP id A5F8716000F for ; Thu, 13 Jul 2023 09:26:01 +0000 (UTC) Authentication-Results: imf08.hostedemail.com; dkim=none; spf=none (imf08.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.51) 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=1689240363; 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-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=qjCVA5MDxvd3EeNJU3W/jmqQ/LWIpwAI10XwgSHHZWw=; b=NueqQIGPVFubFzg4X3O7bC+w91wMoSPSpss2uK0nV6l7YyZiyvOuNiUJdDXQ5umA+uQZ2k idZ32hvGUNjuOiVNLKALQSqtzsjML72bo2S/6jlbKxEbt1qV4o2jaRvBHBd0XDQzG0B/B2 OLexQq/p340j+tYj0dOTpZYkU4otG5M= ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1689240363; a=rsa-sha256; cv=none; b=4TDe73fRE8HiVAp2hxcYvkddPZqHyzNe7sEXDn/PrOQOKwrKBIc9qocUBRo2O4gieKEnof bT61Ukj9x9k6wbCEhLng2m+KMSkq4Gtj8ztXQYGEaKKE9DIw2FbaiglJ4ac26hLRKlNNRj 0jjQpRaG/m3sUBkfNKAP0u/t6YDTdhE= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none; spf=none (imf08.hostedemail.com: domain of shikemeng@huaweicloud.com has no SPF policy when checking 45.249.212.51) smtp.mailfrom=shikemeng@huaweicloud.com; dmarc=none Received: from mail02.huawei.com (unknown [172.30.67.153]) by dggsgout11.his.huawei.com (SkyGuard) with ESMTP id 4R1q3S2wtvz4f3q36 for ; Thu, 13 Jul 2023 17:25:56 +0800 (CST) Received: from huaweicloud.com (unknown [10.175.124.27]) by APP2 (Coremail) with SMTP id Syh0CgDHu+khw69kr7cmNw--.13397S10; Thu, 13 Jul 2023 17:25:57 +0800 (CST) From: Kemeng Shi To: pasha.tatashin@soleen.com, akpm@linux-foundation.org, linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: shikemeng@huaweicloud.com Subject: [PATCH 8/8] mm/page_table_check: remove unused parameter in [__]page_table_check_pud_set Date: Fri, 14 Jul 2023 01:26:36 +0800 Message-Id: <20230713172636.1705415-9-shikemeng@huaweicloud.com> X-Mailer: git-send-email 2.30.0 In-Reply-To: <20230713172636.1705415-1-shikemeng@huaweicloud.com> References: <20230713172636.1705415-1-shikemeng@huaweicloud.com> MIME-Version: 1.0 X-CM-TRANSID: Syh0CgDHu+khw69kr7cmNw--.13397S10 X-Coremail-Antispam: 1UD129KBjvJXoWxXFW3tFykCr4UGFy7Jry7Wrg_yoWrurWxpF s8A3Wvqr45W34Fvry2yrsYvryxtrs8GFWrWryfGanYv3W3Kry0qFyDJrZrAayrGa4xua9x GFWYgwn8GF42qrUanT9S1TB71UUUUUUqnTZGkaVYY2UrUUUUjbIjqfuFe4nvWSU5nxnvy2 9KBjDU0xBIdaVrnRJUUUm214x267AKxVWrJVCq3wAFc2x0x2IEx4CE42xK8VAvwI8IcIk0 rVWrJVCq3wAFIxvE14AKwVWUJVWUGwA2jI8I6cxK62vIxIIY0VWUZVW8XwA2048vs2IY02 0E87I2jVAFwI0_JF0E3s1l82xGYIkIc2x26xkF7I0E14v26ryj6s0DM28lY4IEw2IIxxk0 rwA2F7IY1VAKz4vEj48ve4kI8wA2z4x0Y4vE2Ix0cI8IcVAFwI0_tr0E3s1l84ACjcxK6x IIjxv20xvEc7CjxVAFwI0_Gr1j6F4UJwA2z4x0Y4vEx4A2jsIE14v26rxl6s0DM28EF7xv wVC2z280aVCY1x0267AKxVW0oVCq3wAS0I0E0xvYzxvE52x082IY62kv0487Mc02F40EFc xC0VAKzVAqx4xG6I80ewAv7VC0I7IYx2IY67AKxVWUJVWUGwAv7VC2z280aVAFwI0_Jr0_ Gr1lOx8S6xCaFVCjc4AY6r1j6r4UM4x0Y48IcxkI7VAKI48JM4x0x7Aq67IIx4CEVc8vx2 IErcIFxwCF04k20xvY0x0EwIxGrwCFx2IqxVCFs4IE7xkEbVWUJVW8JwCFI7km07C267AK xVWUAVWUtwC20s026c02F40E14v26r1j6r18MI8I3I0E7480Y4vE14v26r106r1rMI8E67 AF67kF1VAFwI0_JF0_Jw1lIxkGc2Ij64vIr41lIxAIcVC0I7IYx2IY67AKxVWUCVW8JwCI 42IY6xIIjxv20xvEc7CjxVAFwI0_Gr0_Cr1lIxAIcVCF04k26cxKx2IYs7xG6r1j6r1xMI IF0xvEx4A2jsIE14v26r1j6r4UMIIF0xvEx4A2jsIEc7CjxVAFwI0_Gr0_Gr1UYxBIdaVF xhVjvjDU0xZFpf9x0pRvJPtUUUUU= X-CM-SenderInfo: 5vklyvpphqwq5kxd4v5lfo033gof0z/ X-CFilter-Loop: Reflected X-Stat-Signature: qsoy5hn1zua9qcsbjc95hby861jkw469 X-Rspamd-Server: rspam10 X-Rspamd-Queue-Id: A5F8716000F X-Rspam-User: X-HE-Tag: 1689240361-105970 X-HE-Meta: U2FsdGVkX1+kUn4jH5BKcn29jpBUZLb9ksbxTAM633/uQf5exdSldDzm1KjJ30VkXvk3PmKEkh8wemXi0GW6sBXMq+UEaO5MSU9/YaQif3I7rkwdn+5LFTyvFbcXhRdwOw8qQkbfaWM4r4WSmuEacMLsefTDdk+dmpDMk9j/3C6AyE6FncDXf6tw4JOfQLjb0RnKA7J9d9TuG5StQgG4NvUGM9lqgys5Bag7o27lnj99Xti8CyW6axS2vtE5OhRBB3KLeKske0uFH3r56orA190SlhdAnG54iOa/epDQ6FxrBj4Bn271P1pJLG+ErcijohdudkTJ2h6EoiqsRUiVFWGxbnn4QE8LvtO46WS6PXPrDrmBqpKLUJ2xGzU/b23DE8sHHLDqHbzVgeEHpwmnzZotSRXwUid0GZvcaa4/VJQvt8TzceD4BOPCyNppG1rS/KvdP+DioHQnFcPbzEnBX89/8v8FPMpuZpJKK03k4k3P/6XkuBgVN3iZKab7f1H6GfoLj1rJI539rLVDULno24L+Obr3UGLax+mKS2NOoRHtTTNtcXw8QGe6zfQzkzOUIzDtpH21mj97gCDQPUe0SZDrihZJeQlH45zedDsw06khixRV6F66LDyyqZqEPHZFP7NpcpiFx6nDSaXKelFLAsHXG38klTYIbszKi9qkktW83YaNfqJOSBtKafnRSn9BQdcKbdb+uMbZV0BavStfWy392lckCpJ+2RyKsvdbHB8EJ2xpGgSY/QvCSpNvE/CexCHJVF9T56RoR6TLmLK6rM3vziCt8NkzYvR7pRcRj6qaOar+MIOUTLFNJoIFMApLCRWnPlBcwW1BpljTtuQipKrxWRZL/tvaQg0jfOcuFJJh+5hZhebdS8C68q8hrDrKwK8iewvfZyZC/W8y1TkOjhhuaeToqzkdeddo6iD4GfPKWN09bHyTPZzBKwGW1tN1dC6vvUFFn/E+Kzcwbb7 eJCrdyz8 Yg52IQwpyuRfEqnhw/feYLgEi4n/+59Kg5TkNj23plWQlRpEQA/578j3QdEDdRqAWvLO2s5FIFokEsXkTn85IT5uxxLKe0qdutbAmZy7hfjbmEDy36UxjVCJtGw+MErx4V1hx8/0Hy4x5aqVRDkboIWbRIHpUzDhLTwlhrL1MRLmT3kJ1jn2WZKrzYNqJ1ahvlrgbEJTSh+ruBVOwwcBCmfc/6R8MgWDyKMytQUMze74v2XAIE2tHKOlef5NMVPCGWUTk/Q9lbzSz1pw= 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: Remove unused addr in __page_table_check_pud_set and page_table_check_pud_set. Signed-off-by: Kemeng Shi --- arch/arm64/include/asm/pgtable.h | 2 +- arch/riscv/include/asm/pgtable.h | 2 +- arch/x86/include/asm/pgtable.h | 2 +- include/linux/page_table_check.h | 11 ++++------- mm/page_table_check.c | 3 +-- 5 files changed, 8 insertions(+), 12 deletions(-) diff --git a/arch/arm64/include/asm/pgtable.h b/arch/arm64/include/asm/pgtable.h index 1fbf8d3f42b1..fe4b913589ee 100644 --- a/arch/arm64/include/asm/pgtable.h +++ b/arch/arm64/include/asm/pgtable.h @@ -531,7 +531,7 @@ static inline void set_pmd_at(struct mm_struct *mm, unsigned long addr, static inline void set_pud_at(struct mm_struct *mm, unsigned long addr, pud_t *pudp, pud_t pud) { - page_table_check_pud_set(mm, addr, pudp, pud); + page_table_check_pud_set(mm, pudp, pud); return __set_pte_at(mm, addr, (pte_t *)pudp, pud_pte(pud)); } diff --git a/arch/riscv/include/asm/pgtable.h b/arch/riscv/include/asm/pgtable.h index a30658b2611b..44377f0d7c35 100644 --- a/arch/riscv/include/asm/pgtable.h +++ b/arch/riscv/include/asm/pgtable.h @@ -694,7 +694,7 @@ static inline void set_pmd_at(struct mm_struct *mm, unsigned long addr, static inline void set_pud_at(struct mm_struct *mm, unsigned long addr, pud_t *pudp, pud_t pud) { - page_table_check_pud_set(mm, addr, pudp, pud); + page_table_check_pud_set(mm, pudp, pud); return __set_pte_at(mm, addr, (pte_t *)pudp, pud_pte(pud)); } diff --git a/arch/x86/include/asm/pgtable.h b/arch/x86/include/asm/pgtable.h index 9cc26cb0bc9f..ada1bbf12961 100644 --- a/arch/x86/include/asm/pgtable.h +++ b/arch/x86/include/asm/pgtable.h @@ -1037,7 +1037,7 @@ static inline void set_pmd_at(struct mm_struct *mm, unsigned long addr, static inline void set_pud_at(struct mm_struct *mm, unsigned long addr, pud_t *pudp, pud_t pud) { - page_table_check_pud_set(mm, addr, pudp, pud); + page_table_check_pud_set(mm, pudp, pud); native_set_pud(pudp, pud); } diff --git a/include/linux/page_table_check.h b/include/linux/page_table_check.h index dd58dfb0e643..7f6b9bf926c5 100644 --- a/include/linux/page_table_check.h +++ b/include/linux/page_table_check.h @@ -19,8 +19,7 @@ void __page_table_check_pmd_clear(struct mm_struct *mm, pmd_t pmd); void __page_table_check_pud_clear(struct mm_struct *mm, pud_t pud); void __page_table_check_pte_set(struct mm_struct *mm, pte_t *ptep, pte_t pte); void __page_table_check_pmd_set(struct mm_struct *mm, pmd_t *pmdp, pmd_t pmd); -void __page_table_check_pud_set(struct mm_struct *mm, unsigned long addr, - pud_t *pudp, pud_t pud); +void __page_table_check_pud_set(struct mm_struct *mm, pud_t *pudp, pud_t pud); void __page_table_check_pte_clear_range(struct mm_struct *mm, unsigned long addr, pmd_t pmd); @@ -83,14 +82,13 @@ static inline void page_table_check_pmd_set(struct mm_struct *mm, pmd_t *pmdp, __page_table_check_pmd_set(mm, pmdp, pmd); } -static inline void page_table_check_pud_set(struct mm_struct *mm, - unsigned long addr, pud_t *pudp, +static inline void page_table_check_pud_set(struct mm_struct *mm, pud_t *pudp, pud_t pud) { if (static_branch_likely(&page_table_check_disabled)) return; - __page_table_check_pud_set(mm, addr, pudp, pud); + __page_table_check_pud_set(mm, pudp, pud); } static inline void page_table_check_pte_clear_range(struct mm_struct *mm, @@ -135,8 +133,7 @@ static inline void page_table_check_pmd_set(struct mm_struct *mm, pmd_t *pmdp, { } -static inline void page_table_check_pud_set(struct mm_struct *mm, - unsigned long addr, pud_t *pudp, +static inline void page_table_check_pud_set(struct mm_struct *mm, pud_t *pudp, pud_t pud) { } diff --git a/mm/page_table_check.c b/mm/page_table_check.c index 033956704a64..84c8163984e5 100644 --- a/mm/page_table_check.c +++ b/mm/page_table_check.c @@ -208,8 +208,7 @@ void __page_table_check_pmd_set(struct mm_struct *mm, pmd_t *pmdp, pmd_t pmd) } EXPORT_SYMBOL(__page_table_check_pmd_set); -void __page_table_check_pud_set(struct mm_struct *mm, unsigned long addr, - pud_t *pudp, pud_t pud) +void __page_table_check_pud_set(struct mm_struct *mm, pud_t *pudp, pud_t pud) { if (&init_mm == mm) return;