From patchwork Fri Oct 13 08:56:00 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kefeng Wang X-Patchwork-Id: 13420535 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 E02E2CDB47E for ; Fri, 13 Oct 2023 08:59:12 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id BD3948E001F; Fri, 13 Oct 2023 04:59:06 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id B5EAB8E0018; Fri, 13 Oct 2023 04:59:06 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 9FE1C8E001F; Fri, 13 Oct 2023 04:59: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 7D1B48E0018 for ; Fri, 13 Oct 2023 04:59:06 -0400 (EDT) Received: from smtpin28.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay08.hostedemail.com (Postfix) with ESMTP id 309EC1401C3 for ; Fri, 13 Oct 2023 08:59:06 +0000 (UTC) X-FDA: 81339838692.28.0BC583B Received: from szxga03-in.huawei.com (szxga03-in.huawei.com [45.249.212.189]) by imf08.hostedemail.com (Postfix) with ESMTP id 8846A16000A for ; Fri, 13 Oct 2023 08:59:03 +0000 (UTC) Authentication-Results: imf08.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf08.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=hostedemail.com; s=arc-20220608; t=1697187544; 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=MUSi80tZ4yNk8CECWcRvMJAQ5YmLm4C/rY6QQ6q7lE8=; b=s5HOGV6NA23d1FWMTKOKgEA6esZ4jFLUJehgxr48+rxZTAEoV7wFQ4rEThetBOTXG2Znil GO7TB2w9cc1Gca9WS1hq4JJvCJ91UyR2a+1Ml5ISDHkjSoL11hW1bPBiptM1xygodd2EyT XKUe3eitgzsKDMIUITc2EZojnkwBZI8= ARC-Authentication-Results: i=1; imf08.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf08.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.189 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1697187544; a=rsa-sha256; cv=none; b=hyna9DXhEIOaYeAQxB0PU36KVIz5hDUJVXKHAfO7SJV5mbE0NjJTyGLL8iAJBXuUaDMzaJ J/w2wamgLaVsFyNDmMLkJReZGXpWQ9FxUM8lfpo79A15gU0fVaPjL75byemgesuIhrhyqf jig0FoXdrb265qiU1WRnSGkaQAiyAxc= Received: from dggpemm100001.china.huawei.com (unknown [172.30.72.56]) by szxga03-in.huawei.com (SkyGuard) with ESMTP id 4S6L0k4qGFz1kv2n; Fri, 13 Oct 2023 16:54:30 +0800 (CST) Received: from localhost.localdomain (10.175.112.125) by dggpemm100001.china.huawei.com (7.185.36.93) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.31; Fri, 13 Oct 2023 16:58:30 +0800 From: Kefeng Wang To: Andrew Morton CC: , , , , , Zi Yan , Ingo Molnar , Peter Zijlstra , Juri Lelli , Vincent Guittot , Kefeng Wang Subject: [PATCH -next v2 16/19] mm: make finish_mkwrite_fault() static Date: Fri, 13 Oct 2023 16:56:00 +0800 Message-ID: <20231013085603.1227349-17-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.27.0 In-Reply-To: <20231013085603.1227349-1-wangkefeng.wang@huawei.com> References: <20231013085603.1227349-1-wangkefeng.wang@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.112.125] X-ClientProxiedBy: dggems704-chm.china.huawei.com (10.3.19.181) To dggpemm100001.china.huawei.com (7.185.36.93) X-CFilter-Loop: Reflected X-Rspam-User: X-Rspamd-Server: rspam12 X-Rspamd-Queue-Id: 8846A16000A X-Stat-Signature: ghpfqhfbfrqjzz6d3m37sdrqtp4ookuk X-HE-Tag: 1697187543-964262 X-HE-Meta: U2FsdGVkX18XLTzgKHaY/KBjjdH0BSZHtaA0TRdx5Evf36sWWLMKXue3yUPFIobUdL09L4YCuAOCGtg/OTPu31D2rXNN6VmCqfxyhNE4XYPevnP3FOKuEd+3Yw3F9BtfI2EHHyViMoPhjDKHBS+Eex0zNeu4LccurazBuDcRGlkC9i1ZE55uGR99bvIMmu3z7NJXxe58lq5Bv6gNGbKQfkgoUYthbC9WYRdIIwtQmakLO7Xfdk3Ri2jtuJGEw+xvq50MDjFZrzr8Pv/ZfY4SqCqviETxuYexy2bEwVdL+qYRleOW6JzTOKMahr+QIP/dhonSH6W1qtRT5iFHcKiRPxnICVKo8vOeFdKhdc2z/PppgSgNzAi+xpgUFS5gNtSp4ojb+Wbo+0mswASKk/GixgSfQZ54Qv9Q9O7ZPhoNS9ffirJYlZumvsGcYaCN6y4AQuGPNgNp3HHdm/ugto4ckP3FHZryGON8JydGoqn860cXoUJ7uWABmZJk9R2YTPs9K9Es2a3Mw0AWyQvdg3H42KQtzYSUj2isMLLHZN50yEIJOhTcoy2QpQOtkBxKEDhm2xaSQyYKmgIvyUh+NWNkmauXeaNgcbQMVABCRUCJ5eVWoHQM1G6o/gQIsh5DK01i2JMx5pkeFnd9uR8G+jPodAIWyuE4lB3gfjqobVbRgk8QkzxQ2ptrsZ6T0YtyDaigcRl75QYRDbAgybakSKSdMnadxR9l7Y7GX3wLIVf63hzfUlI1ffnkKp/4ic26O0A1vmToNYdm1elhZ7vCFl5//zXpZ6+PbyjHQLzZybs7D3ITRB/J4ZStJW/w2Q8S5bc2Pyv0yHMNHCug7ShttaVtupwjm8w2iGPJvN1/3ydH9dYSYx5y6NScNRSUrLCI6hCDSR1LtPvV2AugrCtjBDBszm8TFy98hExPJK2n+wBwmbrelmjdFPcoZfirwAOguwrPPkmNz9Ydkl6acs38izS Cbvv8lsg iq0Ok26DZgud9d1jeCJqBtiiONT37wp3AFPYiuG6IX6K9GsRGIFd1mVWbTSgf8vuwybF/VsEvePay/Zgr8PpfLLkqT6uMpipzKOZpsYy1Afx605zcL7gHgzUSzTMEqtJxdd3mKsUtbYMbOOvHB7RHyydSaYZdcjm63u+g+frkiHqZjA5iN6dRnG3AADUQkamhIfWMt4qckuKu0Ko= 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: Make finish_mkwrite_fault static since it is not used outside of memory.c. Signed-off-by: Kefeng Wang --- include/linux/mm.h | 1 - mm/memory.c | 2 +- 2 files changed, 1 insertion(+), 2 deletions(-) diff --git a/include/linux/mm.h b/include/linux/mm.h index 8229137e093b..70eae2e7d5e5 100644 --- a/include/linux/mm.h +++ b/include/linux/mm.h @@ -1346,7 +1346,6 @@ void set_pte_range(struct vm_fault *vmf, struct folio *folio, struct page *page, unsigned int nr, unsigned long addr); vm_fault_t finish_fault(struct vm_fault *vmf); -vm_fault_t finish_mkwrite_fault(struct vm_fault *vmf); #endif /* diff --git a/mm/memory.c b/mm/memory.c index a1cf25a3ff16..b6cc24257683 100644 --- a/mm/memory.c +++ b/mm/memory.c @@ -3272,7 +3272,7 @@ static vm_fault_t wp_page_copy(struct vm_fault *vmf) * Return: %0 on success, %VM_FAULT_NOPAGE when PTE got changed before * we acquired PTE lock. */ -vm_fault_t finish_mkwrite_fault(struct vm_fault *vmf) +static vm_fault_t finish_mkwrite_fault(struct vm_fault *vmf) { WARN_ON_ONCE(!(vmf->vma->vm_flags & VM_SHARED)); vmf->pte = pte_offset_map_lock(vmf->vma->vm_mm, vmf->pmd, vmf->address,