From patchwork Mon Jun 12 14:34:14 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Kefeng Wang X-Patchwork-Id: 13276749 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 AAE24C88CB4 for ; Mon, 12 Jun 2023 14:19:18 +0000 (UTC) Received: by kanga.kvack.org (Postfix) id 2E2BC6B0074; Mon, 12 Jun 2023 10:19:18 -0400 (EDT) Received: by kanga.kvack.org (Postfix, from userid 40) id 26A386B0075; Mon, 12 Jun 2023 10:19:18 -0400 (EDT) X-Delivered-To: int-list-linux-mm@kvack.org Received: by kanga.kvack.org (Postfix, from userid 63042) id 0E32F6B0078; Mon, 12 Jun 2023 10:19:18 -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 F1EA16B0074 for ; Mon, 12 Jun 2023 10:19:17 -0400 (EDT) Received: from smtpin01.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay06.hostedemail.com (Postfix) with ESMTP id CD61EAF469 for ; Mon, 12 Jun 2023 14:19:17 +0000 (UTC) X-FDA: 80894303154.01.5B20857 Received: from szxga02-in.huawei.com (szxga02-in.huawei.com [45.249.212.188]) by imf21.hostedemail.com (Postfix) with ESMTP id 752F11C0009 for ; Mon, 12 Jun 2023 14:19:15 +0000 (UTC) Authentication-Results: imf21.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf21.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.188 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=1686579556; 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=y9oD1no1Jl5ED5oaZg6gUA0vIFcsSBeD07uHzX7PsR0=; b=DkYxW1eDMRLpYNLIkRjWrWwSgOQr8QQy4O/M0zAqGR572JFpZFKLLEpChqMiWrKZeWeWZ7 JrPhuDVhj7GMaM3I6Z8N4RV48tPfGs23HK9xoxr6K4YnL+wMOm83+y9MGtqIUQoYG0T/Im VOYw3MUfDoPi3oetIWLrXU9rwZ9oNZM= ARC-Authentication-Results: i=1; imf21.hostedemail.com; dkim=none; dmarc=pass (policy=quarantine) header.from=huawei.com; spf=pass (imf21.hostedemail.com: domain of wangkefeng.wang@huawei.com designates 45.249.212.188 as permitted sender) smtp.mailfrom=wangkefeng.wang@huawei.com ARC-Seal: i=1; s=arc-20220608; d=hostedemail.com; t=1686579556; a=rsa-sha256; cv=none; b=QhqD1bzkF1h2Cmwaoxkw4k8+42tJxXVEg2coUaDjWzU4abLOgq/skZDL2BVaL7cFtWj7Nl ITbJQPmltBN6t3XahLNq8zBJsf40K8ozKPL0o11DLJvamq0nzjbioadLcF8qYkOAZCLLdp /iFrHhQwVgn7lAvkwLqclGTHxFmqAh8= Received: from dggpemm500001.china.huawei.com (unknown [172.30.72.56]) by szxga02-in.huawei.com (SkyGuard) with ESMTP id 4Qfv1W5KKgzTl09; Mon, 12 Jun 2023 22:18:39 +0800 (CST) Received: from localhost.localdomain.localdomain (10.175.113.25) by dggpemm500001.china.huawei.com (7.185.36.107) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256) id 15.1.2507.23; Mon, 12 Jun 2023 22:19:07 +0800 From: Kefeng Wang To: CC: , , , , , Kefeng Wang Subject: [PATCH -next 2/2] mm: kill [add|del]_page_to_lru_list() Date: Mon, 12 Jun 2023 22:34:14 +0800 Message-ID: <20230612143414.186389-2-wangkefeng.wang@huawei.com> X-Mailer: git-send-email 2.35.3 In-Reply-To: <20230612143414.186389-1-wangkefeng.wang@huawei.com> References: <20230612143414.186389-1-wangkefeng.wang@huawei.com> MIME-Version: 1.0 X-Originating-IP: [10.175.113.25] X-ClientProxiedBy: dggems705-chm.china.huawei.com (10.3.19.182) To dggpemm500001.china.huawei.com (7.185.36.107) X-CFilter-Loop: Reflected X-Rspamd-Queue-Id: 752F11C0009 X-Rspam-User: X-Rspamd-Server: rspam05 X-Stat-Signature: o144zg6absihkaghj3uzs1wjyzfw7itd X-HE-Tag: 1686579555-92481 X-HE-Meta: U2FsdGVkX1/PVCX1IoaLh8gkJ+LC/yan/MBvBfNlrrbOCtQmN29M3TEIvlN89pb/wJj/yoVZGQGDXrhUTSzsru0aCqOd5cI8tBkiWbYvI77xw7TZg+AscoTKFN6rBtHhSdJvC2urxIjUtVcP4VCaHiLrSjbf3HPGPKizvLsB9WUIJqNvaoXgvzDQ7dwpop97Me6P9YWdLFgb1R5EN9mbhQT7rnM63eh0yJbuEi0ysrgfnLq0vN5gjNDPhMa8moCBTedKSGQ36yha/sq/ZIMiW/bSeTmZ14LF7xtIyIT2dHU01xNETUOPWGSiuXmLUhfXFLxXbKXNOVMRySIlhnB6wVF5OWLIGKRwqpEimKCvrZXbftUYSXbiqWlStabp6XLzFmUbHW526Os65zZ305a6QGrVl1HC5l/ybGOaqbyHnFYdv0zkPJHSKpDrQmxYlvVTjt1rnX7SF8178B3sdHdPGCKvMjmVjZlqzfJfLl2El90gyFmxANgkMTKPfdiTKraEMqd44aNZzUUP3MPWkC8AD4b43CB/Ky5SGRltFCHxKNDdgzVqC3oRwBJwJBowJgAsL1kpAbC8E6UcGMCylzW2U/TGhrfFiWyzWH38AJT0rjq06O014mTNL+izybPvd3uqUaOxAKvMwz41cQ6BO4CoH0uAZK2pIqDxJNZuPY6UNTyNizktuOV0yImKzkLRkjz/6Gop30ytzlCdZwp4VZzvJ+DZ2zpNxa1f8BESMEA7S74cPYvz9cfpzU702L1dThyEvf7WDjV1/KIZAyj9i9CAUsQRzFYzZvkQ1KLIxfOZVgB1WXMIbdNdFRcpwC7A7HCFnLutYynih/Iq4wJNT0w47QBlGs/4IzR/flO2dSY6Wz5i74ZH8BpsqkSFLC3RWaH3GTfcf0w1f6dXC8ykY2v/+RF2461LU5MpJZpeyULSlTuIXUO9V/RaNh4MAfEkOjul9L4LgITMPmlY+I/RQ+3 8awE/qOY 04LNDdLk98A9xqlqAIyjsJuJVDk0wN1bCdYyl9ZS771IExknyxPA8lQEm4JREtQ/FVOmsR1uZZRlmK/QQEmZUgLMb3ygF4w0eAQRUA5u4I9B8eVjjxVsGgCty7rwK5mO4gsyn6wjbjfwnAj8z3dEnpkBVsEdBFOm4xPaBRhriQS0idzNo6bqeoo5aDJ1lbhSuaoxT 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: Now no one call [add|del]_page_to_lru_list(), let's drop unused page interfaces. Signed-off-by: Kefeng Wang Acked-by: Yu Zhao --- include/linux/mm_inline.h | 12 ------------ 1 file changed, 12 deletions(-) diff --git a/include/linux/mm_inline.h b/include/linux/mm_inline.h index 0e1d239a882c..e9cdeb290841 100644 --- a/include/linux/mm_inline.h +++ b/include/linux/mm_inline.h @@ -323,12 +323,6 @@ void lruvec_add_folio(struct lruvec *lruvec, struct folio *folio) list_add(&folio->lru, &lruvec->lists[lru]); } -static __always_inline void add_page_to_lru_list(struct page *page, - struct lruvec *lruvec) -{ - lruvec_add_folio(lruvec, page_folio(page)); -} - static __always_inline void lruvec_add_folio_tail(struct lruvec *lruvec, struct folio *folio) { @@ -357,12 +351,6 @@ void lruvec_del_folio(struct lruvec *lruvec, struct folio *folio) -folio_nr_pages(folio)); } -static __always_inline void del_page_from_lru_list(struct page *page, - struct lruvec *lruvec) -{ - lruvec_del_folio(lruvec, page_folio(page)); -} - #ifdef CONFIG_ANON_VMA_NAME /* * mmap_lock should be read-locked when calling anon_vma_name(). Caller should