linux/arch/mips/loongson64
Mike Rapoport (Microsoft) 3515863d9f arch, mm: pull out allocation of NODE_DATA to generic code
Architectures that support NUMA duplicate the code that allocates
NODE_DATA on the node-local memory with slight variations in reporting of
the addresses where the memory was allocated.

Use x86 version as the basis for the generic alloc_node_data() function
and call this function in architecture specific numa initialization.

Round up node data size to SMP_CACHE_BYTES rather than to PAGE_SIZE like
x86 used to do since the bootmem era when allocation granularity was
PAGE_SIZE anyway.

Link: https://lkml.kernel.org/r/20240807064110.1003856-10-rppt@kernel.org
Signed-off-by: Mike Rapoport (Microsoft) <rppt@kernel.org>
Acked-by: David Hildenbrand <david@redhat.com>
Reviewed-by: Jonathan Cameron <Jonathan.Cameron@huawei.com>
Tested-by: Zi Yan <ziy@nvidia.com> # for x86_64 and arm64
Tested-by: Jonathan Cameron <Jonathan.Cameron@huawei.com> [arm64 + CXL via QEMU]
Acked-by: Dan Williams <dan.j.williams@intel.com>
Cc: Alexander Gordeev <agordeev@linux.ibm.com>
Cc: Andreas Larsson <andreas@gaisler.com>
Cc: Arnd Bergmann <arnd@arndb.de>
Cc: Borislav Petkov <bp@alien8.de>
Cc: Catalin Marinas <catalin.marinas@arm.com>
Cc: Christophe Leroy <christophe.leroy@csgroup.eu>
Cc: Dave Hansen <dave.hansen@linux.intel.com>
Cc: Davidlohr Bueso <dave@stgolabs.net>
Cc: David S. Miller <davem@davemloft.net>
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Cc: Heiko Carstens <hca@linux.ibm.com>
Cc: Huacai Chen <chenhuacai@kernel.org>
Cc: Ingo Molnar <mingo@redhat.com>
Cc: Jiaxun Yang <jiaxun.yang@flygoat.com>
Cc: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Cc: Jonathan Corbet <corbet@lwn.net>
Cc: Michael Ellerman <mpe@ellerman.id.au>
Cc: Palmer Dabbelt <palmer@dabbelt.com>
Cc: Rafael J. Wysocki <rafael@kernel.org>
Cc: Rob Herring (Arm) <robh@kernel.org>
Cc: Samuel Holland <samuel.holland@sifive.com>
Cc: Thomas Bogendoerfer <tsbogend@alpha.franken.de>
Cc: Thomas Gleixner <tglx@linutronix.de>
Cc: Vasily Gorbik <gor@linux.ibm.com>
Cc: Will Deacon <will@kernel.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
2024-09-03 21:15:28 -07:00
..
boardinfo.c MIPS: Loongson64: Add /sys/firmware/lefi/boardinfo 2020-10-27 12:46:06 +01:00
cop2-ex.c MIPS: Loongson-3: Fix fp register access if MSA enabled 2020-09-22 13:07:22 +02:00
cpucfg-emul.c MIPS: Unify naming style of vendor CP0.Config6 bits 2020-07-08 11:15:53 +02:00
dma.c MIPS: Loongson64: Include bootinfo.h in dma.c 2024-06-11 13:04:11 +02:00
env.c MIPS: Loongson64: env: Hook up Loongsson-2K 2024-06-21 10:22:10 +02:00
hpet.c MIPS: Replace setup_irq() by request_irq() 2020-03-05 16:47:35 +01:00
init.c mm: Introduce vmap_page_range() to map pages in PCI address space 2024-03-11 16:58:10 +01:00
Kconfig MIPS: Loongson64: Mark RS780 HPET as broken 2020-04-20 19:37:01 +02:00
Makefile MIPS: Loongson64: Implement PM suspend for LEFI firmware 2024-06-11 13:03:50 +02:00
numa.c arch, mm: pull out allocation of NODE_DATA to generic code 2024-09-03 21:15:28 -07:00
Platform MIPS: Loongson: Move arch cflags to MIPS top level Makefile 2023-04-05 09:45:09 +02:00
pm.c MIPS: Loongson64: Implement PM suspend for LEFI firmware 2024-06-11 13:03:50 +02:00
reset.c MIPS: Loongson64: reset: Prioritise firmware service 2024-06-21 10:22:10 +02:00
setup.c MIPS: Loongson64: Remove CPU_HAS_WB 2023-03-14 17:06:16 +01:00
sleeper.S MIPS: Loongson64: sleeper: Pass ra and sp as arguments 2024-06-21 10:22:10 +02:00
smp.c MIPS: Loongson64: Switch to SYNC_R4K 2024-07-23 09:29:49 +02:00
smp.h MIPS: Loongson64: Move files to the top-level directory 2019-11-01 14:31:28 -07:00
time.c MIPS: Loongson64: Add support for the Loongson-2K1000 to get cpu_clock_freq 2021-03-25 10:44:01 +01:00
vbios_quirk.c PCI/sysfs: Find shadow ROM before static attribute initialization 2022-01-26 10:41:21 -06:00