From: David Hildenbrand <david@redhat.com>
To: Lorenzo Stoakes <lorenzo.stoakes@oracle.com>
Cc: Jann Horn <jannh@google.com>, Vlastimil Babka <vbabka@suse.cz>,
Andrew Morton <akpm@linux-foundation.org>,
"Liam R . Howlett" <Liam.Howlett@oracle.com>,
linux-mm@kvack.org, linux-kernel@vger.kernel.org
Subject: Re: [PATCH] MAINTAINERS: group all VMA-related files into the VMA section
Date: Tue, 10 Dec 2024 17:59:08 +0100 [thread overview]
Message-ID: <50e194c2-914d-43eb-bff8-47c4a1119dce@redhat.com> (raw)
In-Reply-To: <dfe6b339-a742-4adc-9a53-c653510428d8@lucifer.local>
On 10.12.24 10:51, Lorenzo Stoakes wrote:
> David,
Hi Lorenzo,
sorry for the late reply.
>
> To avoid an infinite back-and-forth...
>
> I think you're stuck on the idea that we are sat in a VMA 'vacuum', perhaps
> because I put so much effort into separating out the VMA logic, for the
> purpose of being able to userland test it, it's almost given the wrong
> impression (I should perhaps have put less effort into this? :)
Yes, that nicely summarizes it.
In particular, because the patch description says "group all VMA-related
files", and I am having a hard time to even identify *what* a
"VMA-related" file is, really.
For example, why not mempolicy.c->mbind()? Not that I would suggest
that, because the file is filled with non-vma-related stuff.
See below of what might make sense to me.
>
> But we have for quite some time now de facto been expected to maintain all
> aspects of mapping, remapping, etc. INCLUDING page table considerations.
> > We are more or less de facto maintaining all that (modulo madvise.c - I
> grant you this is the odd one out).
>
> So you can imagine it's a bit frustrating, when that's the case, to be told
> in effect - no this isn't for you - right?
It isn't "VMA" group for me, independent of "who" is currently listed
there. And maybe we now agree on that, maybe not.
Talking about things that are frustrating: being called a "senior member
of the kernel". :)
> > For instance, as I said before, we have spent large parts of the
6.12 cycle
> dealing with practical concerns specifically around page table
> manipulation.
> > Maintainership is more than setting up lei rules, obviously. One
can set
> lei rules for anything. It means that our say has more impact, and it also
> means that we are (co-)responsible for the listed files, and that's acked
> rather than disregarded.
> > So, again, I politely disagree with your assessment re: page tables.
> > I think their manipulation under circumstances where you
> map/remap/mprotect/mlock is -inseparable- from memory mapping/VMA
> logic. Otherwise, what's the point right?
We'll likely have to agree to disagree. :) But again, my main point is
that the VMA group is misleading.
As a side note, I believe the code can be structures accordingly (call
that separating it). mmap/munmap handling is the prime example right now
for me.
For example, I really enjoy how:
munmap() (mmap.c) routes to __vm_munmap (vma.c) makes use of abstracted
page table logic like free_pgtables() and unmap_vmas() (memory.c).
This way it is clear what the rather high-level MM syscall
implementation is (mmap.c), what the VMA handling is (vma.c) and what
the abstracted page table handling logic is (memory.c). I don't think
that page table handling code should be moved to either mmap.c or vma.c.
I would enjoy if we would handle e.g., mprotect.c in a similar way, such
that the helper like change_protection() -- again, used by completely
mprotect()-unrelated code outside of mprotect.c -- would not reside in
mprotect.c. But that code just evolved naturally after we kept reusing
change_protection() outside of the file.
Regarding mremap logic there once was a discussion about merging it with
the uffdio_move logic, but not sure if that really makes sense.
>
> My suggestion is that:
>
> a. we put everything in MEMORY MAPPING
> b. We drop mm/madvise.c from the list
Sounds better, although I am still fuzzy on what is supposed to be in
there and what not. See my mbind() example above ..
I see how mmap/munmap/mprotect/mremap fall into the same category of MM
syscalls that mainly affect the /proc/self/maps output (in contrast to a
bunch of others). Which make sense to me to group in such a way.
mseal.c and mlock.c likely as well.
msync.c is a simple VMA walker ... not sure if it belongs in there, but
who am I to tell.
--
Cheers,
David / dhildenb
next prev parent reply other threads:[~2024-12-10 16:59 UTC|newest]
Thread overview: 25+ messages / expand[flat|nested] mbox.gz Atom feed top
2024-12-06 19:16 Lorenzo Stoakes
2024-12-06 19:35 ` Liam R. Howlett
2024-12-09 9:16 ` David Hildenbrand
2024-12-09 10:06 ` Lorenzo Stoakes
2024-12-09 14:09 ` David Hildenbrand
2024-12-09 14:28 ` Lorenzo Stoakes
2024-12-09 14:56 ` David Hildenbrand
2024-12-09 15:04 ` Lorenzo Stoakes
2024-12-09 13:25 ` Vlastimil Babka
2024-12-09 14:00 ` David Hildenbrand
2024-12-09 14:11 ` Lorenzo Stoakes
2024-12-09 14:25 ` David Hildenbrand
2024-12-09 14:38 ` Jann Horn
2024-12-09 14:44 ` David Hildenbrand
2024-12-09 14:45 ` Lorenzo Stoakes
2024-12-09 15:03 ` David Hildenbrand
2024-12-09 15:16 ` Lorenzo Stoakes
2024-12-09 22:02 ` David Hildenbrand
2024-12-10 9:51 ` Lorenzo Stoakes
2024-12-10 16:59 ` David Hildenbrand [this message]
2024-12-11 9:35 ` Lorenzo Stoakes
2024-12-11 10:27 ` David Hildenbrand
2024-12-11 10:44 ` Lorenzo Stoakes
2024-12-10 16:06 ` Liam R. Howlett
2024-12-09 14:32 ` Lorenzo Stoakes
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=50e194c2-914d-43eb-bff8-47c4a1119dce@redhat.com \
--to=david@redhat.com \
--cc=Liam.Howlett@oracle.com \
--cc=akpm@linux-foundation.org \
--cc=jannh@google.com \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=lorenzo.stoakes@oracle.com \
--cc=vbabka@suse.cz \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox