From: Alice Ryhl <aliceryhl@google.com>
To: "David Hildenbrand (Arm)" <david@kernel.org>
Cc: linux-kernel@vger.kernel.org,
"linux-mm @ kvack . org" <linux-mm@kvack.org>,
"Andrew Morton" <akpm@linux-foundation.org>,
"Lorenzo Stoakes" <lorenzo.stoakes@oracle.com>,
"Liam R. Howlett" <Liam.Howlett@oracle.com>,
"Vlastimil Babka" <vbabka@kernel.org>,
"Mike Rapoport" <rppt@kernel.org>,
"Suren Baghdasaryan" <surenb@google.com>,
"Michal Hocko" <mhocko@suse.com>, "Jann Horn" <jannh@google.com>,
"Pedro Falcato" <pfalcato@suse.de>,
"David Rientjes" <rientjes@google.com>,
"Shakeel Butt" <shakeel.butt@linux.dev>,
"Matthew Wilcox (Oracle)" <willy@infradead.org>,
"Madhavan Srinivasan" <maddy@linux.ibm.com>,
"Michael Ellerman" <mpe@ellerman.id.au>,
"Christian Borntraeger" <borntraeger@linux.ibm.com>,
"Janosch Frank" <frankja@linux.ibm.com>,
"Claudio Imbrenda" <imbrenda@linux.ibm.com>,
"Alexander Gordeev" <agordeev@linux.ibm.com>,
"Gerald Schaefer" <gerald.schaefer@linux.ibm.com>,
"Heiko Carstens" <hca@linux.ibm.com>,
"Vasily Gorbik" <gor@linux.ibm.com>,
"Jarkko Sakkinen" <jarkko@kernel.org>,
"Thomas Gleixner" <tglx@kernel.org>,
"Ingo Molnar" <mingo@redhat.com>,
"Borislav Petkov" <bp@alien8.de>,
"Greg Kroah-Hartman" <gregkh@linuxfoundation.org>,
"Arve Hjønnevåg" <arve@android.com>,
"Todd Kjos" <tkjos@android.com>,
"Christian Brauner" <brauner@kernel.org>,
"Carlos Llamas" <cmllamas@google.com>,
"Ian Abbott" <abbotti@mev.co.uk>,
"H Hartley Sweeten" <hsweeten@visionengravers.com>,
"Jani Nikula" <jani.nikula@linux.intel.com>,
"Joonas Lahtinen" <joonas.lahtinen@linux.intel.com>,
"Rodrigo Vivi" <rodrigo.vivi@intel.com>,
"Tvrtko Ursulin" <tursulin@ursulin.net>,
"David Airlie" <airlied@gmail.com>,
"Simona Vetter" <simona@ffwll.ch>,
"Jason Gunthorpe" <jgg@ziepe.ca>,
"Leon Romanovsky" <leon@kernel.org>,
"Dimitri Sivanich" <dimitri.sivanich@hpe.com>,
"Arnd Bergmann" <arnd@arndb.de>,
"Alexei Starovoitov" <ast@kernel.org>,
"Daniel Borkmann" <daniel@iogearbox.net>,
"Andrii Nakryiko" <andrii@kernel.org>,
"Peter Zijlstra" <peterz@infradead.org>,
"Arnaldo Carvalho de Melo" <acme@kernel.org>,
"Namhyung Kim" <namhyung@kernel.org>,
"Andy Lutomirski" <luto@kernel.org>,
"Vincenzo Frascino" <vincenzo.frascino@arm.com>,
"Eric Dumazet" <edumazet@google.com>,
"Neal Cardwell" <ncardwell@google.com>,
"David S. Miller" <davem@davemloft.net>,
"David Ahern" <dsahern@kernel.org>,
"Jakub Kicinski" <kuba@kernel.org>,
"Paolo Abeni" <pabeni@redhat.com>,
"Miguel Ojeda" <ojeda@kernel.org>,
linuxppc-dev@lists.ozlabs.org, kvm@vger.kernel.org,
linux-s390@vger.kernel.org, linux-sgx@vger.kernel.org,
intel-gfx@lists.freedesktop.org, dri-devel@lists.freedesktop.org,
linux-rdma@vger.kernel.org, bpf@vger.kernel.org,
linux-perf-users@vger.kernel.org, linux-fsdevel@vger.kernel.org,
netdev@vger.kernel.org, rust-for-linux@vger.kernel.org,
x86@kernel.org
Subject: Re: [PATCH v1 02/16] mm/memory: remove "zap_details" parameter from zap_page_range_single()
Date: Sat, 28 Feb 2026 12:38:48 +0000 [thread overview]
Message-ID: <aaLh2BxSgC9Jl5iS@google.com> (raw)
In-Reply-To: <20260227200848.114019-3-david@kernel.org>
On Fri, Feb 27, 2026 at 09:08:33PM +0100, David Hildenbrand (Arm) wrote:
> Nobody except memory.c should really set that parameter to non-NULL. So
> let's just drop it and make unmap_mapping_range_vma() use
> zap_page_range_single_batched() instead.
>
> Signed-off-by: David Hildenbrand (Arm) <david@kernel.org>
> diff --git a/rust/kernel/mm/virt.rs b/rust/kernel/mm/virt.rs
> index da21d65ccd20..b8e59e4420f3 100644
> --- a/rust/kernel/mm/virt.rs
> +++ b/rust/kernel/mm/virt.rs
> @@ -124,7 +124,7 @@ pub fn zap_page_range_single(&self, address: usize, size: usize) {
> // sufficient for this method call. This method has no requirements on the vma flags. The
> // address range is checked to be within the vma.
> unsafe {
> - bindings::zap_page_range_single(self.as_ptr(), address, size, core::ptr::null_mut())
> + bindings::zap_page_range_single(self.as_ptr(), address, size)
> };
Please run rustfmt on Rust changes. Here, rustfmt leads to this being
formatted on a single line:
unsafe { bindings::zap_page_range_single(self.as_ptr(), address, size) };
with the above changed:
Acked-by: Alice Ryhl <aliceryhl@google.com> # Rust and Binder
Alice
next prev parent reply other threads:[~2026-02-28 12:38 UTC|newest]
Thread overview: 19+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-02-27 20:08 [PATCH v1 00/16] mm: cleanups around unmapping / zapping David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 01/16] mm/madvise: drop range checks in madvise_free_single_vma() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 02/16] mm/memory: remove "zap_details" parameter from zap_page_range_single() David Hildenbrand (Arm)
2026-02-28 12:38 ` Alice Ryhl [this message]
2026-02-27 20:08 ` [PATCH v1 03/16] mm/memory: inline unmap_mapping_range_vma() into unmap_mapping_range_tree() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 04/16] mm/memory: simplify calculation in unmap_mapping_range_tree() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 05/16] mm/oom_kill: use MMU_NOTIFY_CLEAR in __oom_reap_task_mm() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 06/16] mm/oom_kill: factor out zapping of VMA into zap_vma_for_reaping() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 07/16] mm/memory: rename unmap_single_vma() to __zap_vma_range() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 08/16] mm/memory: move adjusting of address range to unmap_vmas() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 09/16] mm/memory: convert details->even_cows into details->skip_cows David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 10/16] mm/memory: use __zap_vma_range() in zap_vma_for_reaping() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 11/16] mm/memory: inline unmap_page_range() into __zap_vma_range() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 12/16] mm: rename zap_vma_pages() to zap_vma() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 13/16] mm: rename zap_page_range_single_batched() to zap_vma_range_batched() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 14/16] mm: rename zap_page_range_single() to zap_vma_range() David Hildenbrand (Arm)
2026-02-28 12:44 ` Alice Ryhl
2026-02-27 20:08 ` [PATCH v1 15/16] mm: rename zap_vma_ptes() to zap_special_vma_range() David Hildenbrand (Arm)
2026-02-27 20:08 ` [PATCH v1 16/16] mm/memory: support VM_MIXEDMAP in zap_special_vma_range() David Hildenbrand (Arm)
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=aaLh2BxSgC9Jl5iS@google.com \
--to=aliceryhl@google.com \
--cc=Liam.Howlett@oracle.com \
--cc=abbotti@mev.co.uk \
--cc=acme@kernel.org \
--cc=agordeev@linux.ibm.com \
--cc=airlied@gmail.com \
--cc=akpm@linux-foundation.org \
--cc=andrii@kernel.org \
--cc=arnd@arndb.de \
--cc=arve@android.com \
--cc=ast@kernel.org \
--cc=borntraeger@linux.ibm.com \
--cc=bp@alien8.de \
--cc=bpf@vger.kernel.org \
--cc=brauner@kernel.org \
--cc=cmllamas@google.com \
--cc=daniel@iogearbox.net \
--cc=davem@davemloft.net \
--cc=david@kernel.org \
--cc=dimitri.sivanich@hpe.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=dsahern@kernel.org \
--cc=edumazet@google.com \
--cc=frankja@linux.ibm.com \
--cc=gerald.schaefer@linux.ibm.com \
--cc=gor@linux.ibm.com \
--cc=gregkh@linuxfoundation.org \
--cc=hca@linux.ibm.com \
--cc=hsweeten@visionengravers.com \
--cc=imbrenda@linux.ibm.com \
--cc=intel-gfx@lists.freedesktop.org \
--cc=jani.nikula@linux.intel.com \
--cc=jannh@google.com \
--cc=jarkko@kernel.org \
--cc=jgg@ziepe.ca \
--cc=joonas.lahtinen@linux.intel.com \
--cc=kuba@kernel.org \
--cc=kvm@vger.kernel.org \
--cc=leon@kernel.org \
--cc=linux-fsdevel@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mm@kvack.org \
--cc=linux-perf-users@vger.kernel.org \
--cc=linux-rdma@vger.kernel.org \
--cc=linux-s390@vger.kernel.org \
--cc=linux-sgx@vger.kernel.org \
--cc=linuxppc-dev@lists.ozlabs.org \
--cc=lorenzo.stoakes@oracle.com \
--cc=luto@kernel.org \
--cc=maddy@linux.ibm.com \
--cc=mhocko@suse.com \
--cc=mingo@redhat.com \
--cc=mpe@ellerman.id.au \
--cc=namhyung@kernel.org \
--cc=ncardwell@google.com \
--cc=netdev@vger.kernel.org \
--cc=ojeda@kernel.org \
--cc=pabeni@redhat.com \
--cc=peterz@infradead.org \
--cc=pfalcato@suse.de \
--cc=rientjes@google.com \
--cc=rodrigo.vivi@intel.com \
--cc=rppt@kernel.org \
--cc=rust-for-linux@vger.kernel.org \
--cc=shakeel.butt@linux.dev \
--cc=simona@ffwll.ch \
--cc=surenb@google.com \
--cc=tglx@kernel.org \
--cc=tkjos@android.com \
--cc=tursulin@ursulin.net \
--cc=vbabka@kernel.org \
--cc=vincenzo.frascino@arm.com \
--cc=willy@infradead.org \
--cc=x86@kernel.org \
/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