From patchwork Tue Feb 20 18:32:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Zi Yan X-Patchwork-Id: 203746 Return-Path: Delivered-To: ouuuleilei@gmail.com Received: by 2002:a05:693c:2685:b0:108:e6aa:91d0 with SMTP id mn5csp594875dyc; Tue, 20 Feb 2024 10:40:55 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCVMWwpgM79UEPqhPdrRfVyc1m4f/9gO1+L0Tya2SQSHHP1VjzU4c+N9imvcwi8StXM45iaRLRxenDEV9SMmR/cCe9KAtw== X-Google-Smtp-Source: AGHT+IHYZQGnXyBwhXQRh6+zvVM5tfw1WHeEiPF2AB8lfxHE3+IXLqrMB63jLLn47nSeehB9k4Cx X-Received: by 2002:a17:90a:ce15:b0:299:d720:2e46 with SMTP id f21-20020a17090ace1500b00299d7202e46mr4348057pju.12.1708454455482; Tue, 20 Feb 2024 10:40:55 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1708454455; cv=pass; d=google.com; s=arc-20160816; b=sL8qnhdfI9LwrmyZviy+8gRQ5n+OLQe954sUW8qRDNSMhyy/8bPgWFvI7Kj7Ac2aFI qX4/S0LpX51VK3D7pugU37OmS6zP3sshP/yBQyOUbzc4Dm/IUq1vcHap9CWL5C7Pp8H4 LxOtc395CiA50VHamNQgYl/WSRH0+aq6WQn31IJIZbh0Pa38ANBQvN475PdwzfDacTFJ 13zLDWfKwoUfRMcp80ElrQmbRlYARCKbZGCzWlYEUPWPAhbrgRnCZmQeLwO1xXOmdxfs tnXaKQJtUi73zPAbQ1LqL202f+LqWK7oONC21k9dXnaAwvYHtSKOl8cBSJPbnpoaD2g/ LK4w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:reply-to:references:in-reply-to :message-id:date:subject:cc:to:from:feedback-id:dkim-signature :dkim-signature; bh=3te7tA2WvcLuVx5XlSmApKI15+NRwijvQjuoj0usTfY=; fh=vJ0CYzlC3FzFcxY+JvdHzizIe8XjzG5USPt1Sa6qsGI=; b=JFoFiN1Bg17NNDT1SorFUW0mpa5K9gUTsywju+ZBWvdyj0gx1diiai3sxoIPwt/D7F nwGnqNUEa+Q+vDYfRrbYo2TwROyaMQkI0++JCuaLAfl8nBtzIFpXeW7KCMWtN/LPsygF rrIxuhmdFNai8aDq76T/f4HrUQJjDlk6XWMe0WB1+OWU6gWluGNEjePGvpeuW7yNpxU6 1ZQ20p1Lhq9NRF/Eaq8vT8H2zva87VWZDJq8uRmzWHjrmHW6aF8iXge9yGsB60hUF05p R4yQKVPbOXAoy+uSrQ8e4b4Iw0yT0b8rEVjpomH9sfK7ladV6PvKYadc7PNMq+PyyXUU +d1g==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@sent.com header.s=fm1 header.b=OSmmEdRo; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=gmSswlMA; arc=pass (i=1 spf=pass spfdomain=sent.com dkim=pass dkdomain=sent.com dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=sent.com); spf=pass (google.com: domain of linux-kernel+bounces-73513-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73513-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sent.com Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id lx11-20020a17090b4b0b00b00298986bddffsi6740553pjb.111.2024.02.20.10.40.55 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Feb 2024 10:40:55 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-73513-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@sent.com header.s=fm1 header.b=OSmmEdRo; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=gmSswlMA; arc=pass (i=1 spf=pass spfdomain=sent.com dkim=pass dkdomain=sent.com dkim=pass dkdomain=messagingengine.com dmarc=pass fromdomain=sent.com); spf=pass (google.com: domain of linux-kernel+bounces-73513-ouuuleilei=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-kernel+bounces-73513-ouuuleilei=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=sent.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id AAEC5B2270E for ; Tue, 20 Feb 2024 18:33:12 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 17DB412EBCA; Tue, 20 Feb 2024 18:32:47 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=sent.com header.i=@sent.com header.b="OSmmEdRo"; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b="gmSswlMA" Received: from wout3-smtp.messagingengine.com (wout3-smtp.messagingengine.com [64.147.123.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id D16E3127B6C for ; Tue, 20 Feb 2024 18:32:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=64.147.123.19 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708453963; cv=none; b=JwGFq4/r7y9VBjT4JktNJj0vLqiJI8kP5M1kKLtfVl8INaJGzE8KQNM/mvNRSWdxaQwLOoI/Xrk2F7ZGgoC8LocYRz/lkKrJOpKzh/xqg7EEH4SeyfF2sp8CRWqO99wAb0vIXp0Kck08SwXcFNYtXrJMq/Nd/zhwWm4LOGHy/WI= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1708453963; c=relaxed/simple; bh=jysQqj4P6OHjX2f8XiwuDNsMZWqBz8wpGxcTRhCdhAw=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version:Content-Type; b=cj89DY+MBOajkwQjWjJ/OrQQeSMhg6ebBsoriOJmrne80Nqvll+/8h28kspZdH/tGXJvVpRpmOyWJnF1p+TKXqLHnKg5p0/iKuLWUceWXID5mBRigv6juibGDl1mv6f8lFT8OMt5efUKkXbPXzYKKdp2SbVMvWoy1HuuLGBkMd4= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sent.com; spf=pass smtp.mailfrom=sent.com; dkim=pass (2048-bit key) header.d=sent.com header.i=@sent.com header.b=OSmmEdRo; dkim=pass (2048-bit key) header.d=messagingengine.com header.i=@messagingengine.com header.b=gmSswlMA; arc=none smtp.client-ip=64.147.123.19 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=sent.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=sent.com Received: from compute7.internal (compute7.nyi.internal [10.202.2.48]) by mailout.west.internal (Postfix) with ESMTP id 4F7983200495; Tue, 20 Feb 2024 13:32:39 -0500 (EST) Received: from mailfrontend2 ([10.202.2.163]) by compute7.internal (MEProxy); Tue, 20 Feb 2024 13:32:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=sent.com; h=cc :cc:content-transfer-encoding:content-type:content-type:date :date:from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:reply-to:subject:subject:to:to; s=fm1; t= 1708453958; x=1708540358; bh=3te7tA2WvcLuVx5XlSmApKI15+NRwijvQju oj0usTfY=; b=OSmmEdRoDCwAgPBnLo0uZuQmHYzka++qvdQaXCk44ZDkenqRSb/ K0hZmACbnPKTnIsRqCesEe/C/TxyJW1JtH3gDiOYSbyF/lPmgVgJHa74i9MPm7Jh +xvtuWp0gV4+1HEK/3fO/FEoeQIJE7pkTCxHyF7EjWGEzWwX2+e43B7Z5mqLpcxV CAtDT76PMAUS67DsKKkWC8s/WhKVzmpArFJn5fQwR/PbJICXsLUVT1mK7haRlUCz q20JRQS7zbZ2s/C4ugZifll3pLFFfeH/uY8Xy/zbFahW1D/qOhX4BAPxHlVBbf8x UiEcd+fQdY2ss9rZHvh9zePsQIzaKA7AxVA== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:cc:content-transfer-encoding :content-type:content-type:date:date:feedback-id:feedback-id :from:from:in-reply-to:in-reply-to:message-id:mime-version :references:reply-to:reply-to:subject:subject:to:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; t= 1708453958; x=1708540358; bh=3te7tA2WvcLuVx5XlSmApKI15+NRwijvQju oj0usTfY=; b=gmSswlMAp/+WPxW+MYBqcg9EJgcY/p1MxHMZAoruS9GrwGchYPy 3Ous9gaijN0aVRwVNWXOKzWiekjpb3GPsNmM27lXwaOzEATaSZRln67Z2gwdpcwH P8tDUsZ96dxTJg1enKijxxxmJ7EY3Ulh9wCBwheJRscZJuQ4kP7yQCOhmIZ3qo1R 2+zvY0cUT0NAAgl3tWqEjFvleWyVa6PXV6s85zwbJsbCzKG+yuGZEa9yJxxc/kaK LKJTYsEgjYX/aYYH27H9VUZDnpg8UqgWttfzdBVGAFgx2ECmXKM/N2iv4mKc2hQN STYviACeyGO3U9Pdx7uwp/A5LSjRlCNGLLQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvledrfedtgdduudehucetufdoteggodetrfdotf fvucfrrhhofhhilhgvmecuhfgrshhtofgrihhlpdfqfgfvpdfurfetoffkrfgpnffqhgen uceurghilhhouhhtmecufedttdenucesvcftvggtihhpihgvnhhtshculddquddttddmne cujfgurhephffvvefufffkofgjfhhrgggtgfesthekredtredtjeenucfhrhhomhepkghi ucgjrghnuceoiihirdihrghnsehsvghnthdrtghomheqnecuggftrfgrthhtvghrnhepje ekteekffelleekudfftdefvddtjeejuedtuedtteegjefgvedtfedujeekieevnecuvehl uhhsthgvrhfuihiivgeptdenucfrrghrrghmpehmrghilhhfrhhomhepiihirdihrghnse hsvghnthdrtghomh X-ME-Proxy: Feedback-ID: iccd040f4:Fastmail Received: by mail.messagingengine.com (Postfix) with ESMTPA; Tue, 20 Feb 2024 13:32:37 -0500 (EST) From: Zi Yan To: linux-mm@kvack.org, linux-kernel@vger.kernel.org Cc: Zi Yan , "Huang, Ying" , Ryan Roberts , Andrew Morton , "Matthew Wilcox (Oracle)" , David Hildenbrand , "Yin, Fengwei" , Yu Zhao , Vlastimil Babka , "Kirill A . Shutemov" , Johannes Weiner , Baolin Wang , Kemeng Shi , Mel Gorman , Rohan Puri , Mcgrof Chamberlain , Adam Manzanares , "Vishal Moola (Oracle)" Subject: [PATCH v7 1/4] mm/page_alloc: remove unused fpi_flags in free_pages_prepare() Date: Tue, 20 Feb 2024 13:32:17 -0500 Message-ID: <20240220183220.1451315-2-zi.yan@sent.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240220183220.1451315-1-zi.yan@sent.com> References: <20240220183220.1451315-1-zi.yan@sent.com> Reply-To: Zi Yan Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-getmail-retrieved-from-mailbox: INBOX X-GMAIL-THRID: 1791444338999976235 X-GMAIL-MSGID: 1791444338999976235 From: Zi Yan Commit 0a54864f8dfb ("kasan: remove PG_skip_kasan_poison flag") removes the use of fpi_flags in should_skip_kasan_poison() and fpi_flags is only passed to should_skip_kasan_poison() in free_pages_prepare(). Remove the unused parameter. Signed-off-by: Zi Yan Reviewed-by: Vlastimil Babka Reviewed-by: David Hildenbrand --- mm/page_alloc.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/mm/page_alloc.c b/mm/page_alloc.c index 7ae4b74c9e5c..70c1ed3addf3 100644 --- a/mm/page_alloc.c +++ b/mm/page_alloc.c @@ -1061,7 +1061,7 @@ static int free_tail_page_prepare(struct page *head_page, struct page *page) * on-demand allocation and then freed again before the deferred pages * initialization is done, but this is not likely to happen. */ -static inline bool should_skip_kasan_poison(struct page *page, fpi_t fpi_flags) +static inline bool should_skip_kasan_poison(struct page *page) { if (IS_ENABLED(CONFIG_KASAN_GENERIC)) return deferred_pages_enabled(); @@ -1081,10 +1081,10 @@ static void kernel_init_pages(struct page *page, int numpages) } static __always_inline bool free_pages_prepare(struct page *page, - unsigned int order, fpi_t fpi_flags) + unsigned int order) { int bad = 0; - bool skip_kasan_poison = should_skip_kasan_poison(page, fpi_flags); + bool skip_kasan_poison = should_skip_kasan_poison(page); bool init = want_init_on_free(); bool compound = PageCompound(page); @@ -1266,7 +1266,7 @@ static void __free_pages_ok(struct page *page, unsigned int order, unsigned long pfn = page_to_pfn(page); struct zone *zone = page_zone(page); - if (!free_pages_prepare(page, order, fpi_flags)) + if (!free_pages_prepare(page, order)) return; /* @@ -2379,7 +2379,7 @@ static bool free_unref_page_prepare(struct page *page, unsigned long pfn, { int migratetype; - if (!free_pages_prepare(page, order, FPI_NONE)) + if (!free_pages_prepare(page, order)) return false; migratetype = get_pfnblock_migratetype(page, pfn);