3
0
Fork 0
forked from mirrors/linux
kernel/arch/sparc
Kevin Brodsky 10a2e444e4 sparc64: mm: call ctor/dtor for kernel PTEs
The generic implementation of pte_{alloc_one,free}_kernel now calls the
[cd]tor, without initialising the ptlock needlessly as
pagetable_pte_ctor() skips it for init_mm.

Align sparc64 with the generic implementation by ensuring
pagetable_pte_[cd]tor() are called for kernel PTEs.  As a result the
kernel and user alloc/free functions have the same implementation, and
since pgtable_t is defined as pte_t *, we can have both call a common
helper.

Link: https://lkml.kernel.org/r/20250408095222.860601-7-kevin.brodsky@arm.com
Signed-off-by: Kevin Brodsky <kevin.brodsky@arm.com>
Cc: Albert Ou <aou@eecs.berkeley.edu>
Cc: Andreas Larsson <andreas@gaisler.com>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: David S. Miller <davem@davemloft.net>
Cc: Geert Uytterhoeven <geert@linux-m68k.org>
Cc: Linus Waleij <linus.walleij@linaro.org>
Cc: Madhavan Srinivasan <maddy@linux.ibm.com>
Cc: Mark Rutland <mark.rutland@arm.com>
Cc: Matthew Wilcox (Oracle) <willy@infradead.org>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Mike Rapoport <rppt@kernel.org>
Cc: Palmer Dabbelt <palmer@dabbelt.com>
Cc: Paul Walmsley <paul.walmsley@sifive.com>
Cc: Peter Zijlstra <peterz@infradead.org>
Cc: Qi Zheng <zhengqi.arch@bytedance.com>
Cc: Ryan Roberts <ryan.roberts@arm.com>
Cc: Will Deacon <will@kernel.org>
Cc: <x86@kernel.org>
Cc: Yang Shi <yang@os.amperecomputing.com>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2025-05-11 17:48:22 -07:00
..
boot kbuild: Abort make on install failures 2024-07-20 13:34:54 +09:00
configs lib/crc: remove unnecessary prompt for CONFIG_CRC16 2025-04-04 11:31:42 -07:00
crypto crypto: skcipher - Make skcipher_walk src.virt.addr const 2025-03-15 16:21:22 +08:00
include syscall.h: introduce syscall_set_nr() 2025-05-11 17:48:15 -07:00
kernel treewide: Switch/rename to timer_delete[_sync]() 2025-04-05 10:30:12 +02:00
lib lib/crc32: remove "_le" from crc32c base and arch functions 2025-02-08 20:06:30 -08:00
math-emu
mm sparc64: mm: call ctor/dtor for kernel PTEs 2025-05-11 17:48:22 -07:00
net Modules changes for v6.10-rc1 2024-05-15 14:05:08 -07:00
power sparc64: Fix prototype warnings in hibernate.c 2024-07-11 15:58:28 +02:00
prom sparc64: Fix prototype warning for prom_get_mmu_ihandle 2024-07-11 15:58:28 +02:00
vdso sparc/vdso: Always reject undefined references during linking 2025-03-11 09:54:48 +01:00
video arch: Fix name collision with ACPI's video.o 2024-05-20 21:17:06 +00:00
Kbuild
Kconfig sparc/crc32: expose CRC32 functions through lib 2024-12-01 17:23:01 -08:00
Kconfig.debug sparc: select FRAME_POINTER instead of redefining it 2024-02-16 16:50:26 +01:00
Makefile sparc/build: Put usage of -fcall-used* flags behind cc-option 2024-11-16 09:52:56 +01:00