From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (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 045173C1974 for ; Mon, 10 Aug 2026 12:56:09 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786366571; cv=none; b=L9CE8DVWKArxFZr5kNl2NAODl1H7z/ll8Zh+Snk04zEKFfg36k2i/x4bQcTqRAzlnEE7I68ODiAM17RnRFOAjKdm9ciXas9oPi5/RGKbaXfr8nO83CCg0SxNnsoXCybq51T/TtmFaOmvQryP2mp+SVJ7gGFemYExwG1kFydnmDE= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1786366571; c=relaxed/simple; bh=lKZUixRZX3PrFfmq/G1HHYWWlfQbhX85WGQo8sN515I=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=jx69MHf51kAlkpm/VCUnklaYKOlhbq8Gd4ccjhUqSZDUeiSw2jlzchg/Ho6eJxDS+Ib+XM0qx6kFakIAOrD3APPjxhbDN5ffF8szS20z3mEDYWhbOQU3IamwjM8ZjlCBUF1ruXZFcUknqkyqZG8Xn4mPaGEAQXellS/iar/rbS4= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=e7vr1lga; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="e7vr1lga" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0B6591F000E9; Mon, 10 Aug 2026 12:56:04 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1786366569; bh=MPKIlGpvmXcWQjI00VD8/5BTruLNkTRTyS1KnizrheY=; h=Date:From:To:Cc:Subject:References:In-Reply-To; b=e7vr1lgaqF30+6dpc+JhFfhBT3urAGCW5BunGeskC4pRhKJPj9hzGXL7RlFivof/I Wsiwf9KmF2ZckCXD1Ep4XDYUDcJNFJxZULN7auMqvBIQnbr7DxR+VlTg24T3QEUlYZ zQ8Y3U/UZjLLhWoltw+0SSfEblcbKHmq+Im2q7nc7I90c47Q76O5Y2o7B3bYv8wlXj 3hqParA/XlZ2NMOex/vSfx4Oke9Zhs+F9WuEdlf7+zP5SNtLkR3PyyLsAkGyhJYUw0 /3+Q6MXXNyu4orfM9yXs42KeDVJbgyCujPhy0kpfYYfpaSF6HAmrdaaeeRuXozOuYs YghievTvXw3tA== Date: Mon, 10 Aug 2026 13:55:49 +0100 From: "Lorenzo Stoakes (ARM)" To: Tal Zussman Cc: Matthew Wilcox , Andrew Morton , Chris Li , Kairui Song , Kemeng Shi , Nhat Pham , Baoquan He , Barry Song , Youngjun Park , David Hildenbrand , "Liam R. Howlett" , Vlastimil Babka , Mike Rapoport , Suren Baghdasaryan , Michal Hocko , Christoph Hellwig , Johannes Weiner , Yosry Ahmed , Chengming Zhou , linux-mm@kvack.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 4/6] mm/page_io: rename bio_associate_blkg_from_page() Message-ID: References: <20260806-b4-page_io-folios-v1-0-0899bac3b826@columbia.edu> <20260806-b4-page_io-folios-v1-4-0899bac3b826@columbia.edu> <612ed1ce-e7a7-410e-9ad7-256e77bc867c@columbia.edu> 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: <612ed1ce-e7a7-410e-9ad7-256e77bc867c@columbia.edu> On Fri, Aug 07, 2026 at 10:30:22PM +0300, Tal Zussman wrote: > On 8/7/26 2:56 PM, Matthew Wilcox wrote: > > On Thu, Aug 06, 2026 at 06:55:36PM -0400, Tal Zussman wrote: > >> This function takes a folio. Rename it to > >> bio_associate_blkg_from_folio() accordingly. While at it, convert the > >> macro in the !CONFIG_MEMCG || !CONFIG_BLK_CGROUP case to a function. > >> > >> Signed-off-by: Tal Zussman > > > > Reviewed-by: Matthew Wilcox (Oracle) > > > >> -static void bio_associate_blkg_from_page(struct bio *bio, struct folio *folio) > >> +static void bio_associate_blkg_from_folio(struct bio *bio, struct folio *folio) > > > > It's s shame this isn't const-qualified (after all, we don't modify the folio). > > That needs folio_memcg_charged() to take a const folio pointer, which it > > could. And folio_memcg_blkg_css() and folio_memcg(). That's a followup > > patch though. > > > > I had the same thought when looking at this and went all the way down the > callchain to dump_page(). I didn't want to flood the list with patches, but > happy to send a couple follow-up patches once this is in mm-new. Churn that achieves good things is OK :) (but of course, I would say that ;) -- Cheers, Lorenzo