Thread (140 messages) 140 messages, 10 authors, 11d ago

Re: [PATCH 05/30] mm/rmap: update mm/interval_tree.c comments

From: Lorenzo Stoakes <ljs@kernel.org>
Date: 2026-06-29 17:41:13
Also in: damon, dri-devel, kvm, linux-arm-msm, linux-fsdevel, linux-iommu, linux-mm, linux-perf-users, linux-tegra, lkml, nvdimm

On Mon, Jun 29, 2026 at 01:11:19PM -0400, Gregory Price wrote:
On Mon, Jun 29, 2026 at 05:41:16PM +0100, Lorenzo Stoakes wrote:
quoted
On Mon, Jun 29, 2026 at 12:01:02PM -0400, Gregory Price wrote:
quoted
On Mon, Jun 29, 2026 at 01:23:16PM +0100, Lorenzo Stoakes wrote:
quoted
Update the file comment to clarify that both file-backed and anonymous
interval trees are provided, referencing the relevant data types for
clarity.
Isn't this self-evident by nature of the function definitions?
(one takes a vm_area_struct, the other takes an anon_vma_chain)
Well you see you're already hitting up on issues there, they both take an
rb_root_cached and the vma_*() ones do not instantly scream 'file-backed' do
they? As VMAs are obviously used for buth anon and file-backed...

But later patches fix this stuff :)

And I feel it's hard visually to see where one set of definitions end and
another begins, which was really the motive for this, as trivial as it is!
Fair enough, I scanned the rest initially but trying to wrap my head
around everything as i go through one by one.  Generally this really
screams "fix the apis" not "comment the bad ones" - but i suppose that's
the whole point here.
Yeah intent is to eventually completely remove the anon stuff from here at least
:)

And Pedro I think is looking at the file rmap so we'll get there :)
It's definitely an improvement either way.

Reviewed-by: Gregory Price <gourry@gourry.net>

~Gregory
Cheers, Lorenzo
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help