From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from casper.infradead.org (casper.infradead.org [90.155.50.34]) (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 570D0187346 for ; Tue, 2 Jun 2026 15:58:11 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=90.155.50.34 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780415895; cv=none; b=AsX386BmD9nGtsZrzIw3DA1PWKnQIWNk1c1p0EJom9JfqkMNIICBxRGzqu/6Qbw3EpsmN/qdtcDOM8dEV6nCGiJv0eEAzZ3I0Ch+QPIIhrIXQ0j3g7xz91AgCXGrX/GCJRscfZ/3qGO/YMiJnPIQBa4ton9qyXW44KzmgK/8+r0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1780415895; c=relaxed/simple; bh=Fa/ROCnw+FbJIh6gUCJf7HBD74YZkKDQrtjE2ndI2oE=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=njQYlgLWmsk5v8b98Zo7A9xaBf5ZObOL0IuUTlZ7ynqicZqJpbcFUzKga3zetjz0FpWqi674HDkVcbUQBtBcZ7iWDrN694UlF/tM5QhLKxw8d5ZEmuSDl9hzvqWEIsTn45Gj4a12Sd3bejvaQuwQce/gKw5jzsyTJuEB3daC3TY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org; spf=pass smtp.mailfrom=infradead.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b=fvKvJXdp; arc=none smtp.client-ip=90.155.50.34 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=infradead.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=infradead.org Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=infradead.org header.i=@infradead.org header.b="fvKvJXdp" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=infradead.org; s=casper.20170209; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date:Sender:Reply-To: Content-Transfer-Encoding:Content-ID:Content-Description; bh=rx+0pE4L3Y8nALJvhY8y9z/1V3Frljdp5XhJ/FJ5LMk=; b=fvKvJXdp5ZKXNTcHlJD+b/mN5+ /VukpZDAGqEmxhOYCWsu9X3IR4/SiAXCO0U/fXNRA8mimHrGkxEwvUvKruPPVvVGtP0F2KWeZHkkN Tt2L/cYxzF3toCUrpvHgNRtqGPoZg8o2CkVj44ZJcSYN9nGadiJVsFu68R7qIoHznr5Wp18V71JjE m5SVebyLMuifZCJwQS+rDhpBa0MxB67yxgJwQoOEkKqqvq+AEw/BYqHDGILpP0GMoC8azOeIFB2gX IjI4Y2YHLz3qMlcSdQ33u8nGbImpQEveVMwNtRI5xaCPAY/0IxGcDVI2wQgyySfOtIbECItfKr+Ej uV4mo4lg==; Received: from willy by casper.infradead.org with local (Exim 4.99.1 #2 (Red Hat Linux)) id 1wURUp-00000002Dze-0XIU; Tue, 02 Jun 2026 15:57:39 +0000 Date: Tue, 2 Jun 2026 16:57:39 +0100 From: Matthew Wilcox To: Jianyue Wu , Tal Zussman Cc: Andrew Morton , Chris Li , Kairui Song , Kemeng Shi , Nhat Pham , Baoquan He , Barry Song , Youngjun Park , Qi Zheng , Shakeel Butt , Axel Rasmussen , Yuanchu Xie , Wei Xu , Johannes Weiner , David Hildenbrand , Michal Hocko , Lorenzo Stoakes , "Liam R. Howlett" , Vlastimil Babka , Mike Rapoport , Suren Baghdasaryan , Michal Hocko , Hugh Dickins , Baolin Wang , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH v3 2/3] mm: move folio LRU code out of swap Message-ID: References: <20260602-ch-swap-series-plus-folio-lru-cleanup-v3-0-5bbb567f8c99@gmail.com> <20260602-ch-swap-series-plus-folio-lru-cleanup-v3-2-5bbb567f8c99@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20260602-ch-swap-series-plus-folio-lru-cleanup-v3-2-5bbb567f8c99@gmail.com> On Tue, Jun 02, 2026 at 09:01:16AM +0800, Jianyue Wu wrote: > Rename mm/swap.c to mm/folio_lru.c so the filename better matches > the code's main responsibility. > > This keeps the implementation split from swap-specific code without > changing the published LRU helper interfaces. At the same time, we have Tal trying to split folio_wait.c out of filemap.c. https://lore.kernel.org/linux-mm/20260520-filemap-split-v1-0-c36ddc2b6cf2@columbia.edu/ I wonder if instead of folio_lru.c and folio_wait.c, we shouldn't simply have folio.c. Tal has 700 lines in his diffstat, you'll have about 1100 lines, so that's about 1800 llines which seems like a good size. There's some functions from mm/util.c that would fit nicely too -- folio_mapping(), folio_anon_vma(), folio_copy(), flush_dcache_folio() Other people have thoughts?