alpha-remove-discontigmem-and-numa.patch removed from -mm tree
The patch titled
Subject: alpha: remove DISCONTIGMEM and NUMA
has been removed from the -mm tree. Its filename was
alpha-remove-discontigmem-and-numa.patch
This patch was dropped because it was merged into mainline or a subsystem tree
------------------------------------------------------
From: Mike Rapoport <[email protected]>
Subject: alpha: remove DISCONTIGMEM and NUMA
Patch series "Remove DISCONTIGMEM memory model", v3.
SPARSEMEM memory model was supposed to entirely replace DISCONTIGMEM a (long) while ago. The last architectures that used DISCONTIGMEM were updated to use other memory models in v5.11 and it is about the time to entirely remove DISCONTIGMEM from the kernel.
This set removes DISCONTIGMEM from alpha, arc and m68k, simplifies memory model selection in mm/Kconfig and replaces usage of redundant CONFIG_NEED_MULTIPLE_NODES and CONFIG_FLAT_NODE_MEM_MAP with CONFIG_NUMA and CONFIG_FLATMEM respectively.
I've also removed NUMA support on alpha that was BROKEN for more than 15 years.
There were also minor updates all over arch/ to remove mentions of DISCONTIGMEM in comments and #ifdefs.
This patch (of 9):
NUMA is marked broken on alpha for more than 15 years and DISCONTIGMEM was replaced with SPARSEMEM in v5.11.
Remove both NUMA and DISCONTIGMEM support from alpha.
---
arch/alpha/Kconfig | 22 -- arch/alpha/include/asm/machvec.h | 6 arch/alpha/include/asm/mmzone.h | 100 ------------ arch/alpha/include/asm/pgtable.h | 4 arch/alpha/include/asm/topology.h | 39 ---- arch/alpha/kernel/core_marvel.c | 53 ------ arch/alpha/kernel/core_wildfire.c | 29 --- arch/alpha/kernel/pci_iommu.c | 29 --- arch/alpha/kernel/proto.h | 8 - arch/alpha/kernel/setup.c | 16 -- arch/alpha/kernel/sys_marvel.c | 5 arch/alpha/kernel/sys_wildfire.c | 5 arch/alpha/mm/Makefile | 2 arch/alpha/mm/init.c | 3 arch/alpha/mm/numa.c | 223 ---------------------------- 15 files changed, 4 insertions(+), 540 deletions(-)
arch/alpha/include/asm/machvec.h renamed from arch/alpha/include/asm/machvec.h~alpha-remove-discontigmem-and-numa +0 -6
@@ -99,12 +99,6 @@ struct alpha_machine_vectorconst char *vector_name; -/* NUMA information */ -int (*pa_to_nid)(unsigned long ); -int (*cpuid_to_nid)(int ); -unsigned long (*node_mem_start)(int ); -unsigned long (*node_mem_size)(int ); -/* System specific parameters. */ union { struct {
arch/alpha/include/asm/mmzone.h deleted +0 -100
100 lines not on this page · raw message
arch/alpha/include/asm/pgtable.h renamed from arch/alpha/include/asm/pgtable.h~alpha-remove-discontigmem-and-numa +0 -4
@@ -206,7 +206,6 @@ extern unsigned long __zero_page(void);#define page_to_pa (page) (page_to_pfn(page) << PAGE_SHIFT)#define pte_pfn (pte) (pte_val(pte) >> 32) -#ifndef CONFIG_DISCONTIGMEM #define pte_page (pte) pfn_to_page(pte_pfn(pte))#define mk_pte (page, pgprot) \ ({ \
@@ -215,7 +214,6 @@ extern unsigned long __zero_page(void);pte_val (pte) = (page_to_pfn (page) <<32 ) |pgprot_val (pgprot); \ pte; \ }) -#endif extern inline pte_t pfn_pte (unsigned long physpfn,pgprot_t pgprot) {pte_t pte;pte_val (pte) = (PHYS_TWIDDLE (physpfn) <<32 ) |pgprot_val (pgprot);return pte; }
@@ -330,9 +328,7 @@ extern inline pte_t mk_swap_pte(unsigned#define __pte_to_swp_entry (pte) ((swp_entry_t) { pte_val(pte) })#define __swp_entry_to_pte (x) ((pte_t) { (x).val }) -#ifndef CONFIG_DISCONTIGMEM #define kern_addr_valid (addr) (1) -#endif #define pte_ERROR (e) \ printk("%s:%d: bad pte %016lx.\n", __FILE__, __LINE__, pte_val(e))
arch/alpha/include/asm/topology.h renamed from arch/alpha/include/asm/topology.h~alpha-remove-discontigmem-and-numa +0 -39
@@ -7,45 +7,6 @@#include <linux/numa.h> #include <asm/machvec.h> -#ifdef CONFIG_NUMA -static inline int cpu_to_node (int cpu) -{ -int node; - -if (!alpha_mv.cpuid_to_nid) -return 0 ; - - node = alpha_mv.cpuid_to_nid (cpu); - -#ifdef DEBUG_NUMA -BUG_ON (node <0 ); -#endif - -return node; -} - -extern struct cpumask node_to_cpumask_map[]; -/* FIXME: This is dumb, recalculating every time. But simple. */ -static const struct cpumask *cpumask_of_node (int node) -{ -int cpu; - -if (node ==NUMA_NO_NODE ) -return cpu_all_mask; - -cpumask_clear (&node_to_cpumask_map[node]); - -for_each_online_cpu (cpu) { -if (cpu_to_node (cpu) == node) -cpumask_set_cpu (cpu, node_to_cpumask_map[node]); - } - -return &node_to_cpumask_map[node]; -} - -#define cpumask_of_pcibus (bus) (cpu_online_mask) - -#endif /* !CONFIG_NUMA */ # include <asm-generic/topology.h> #endif /* _ASM_ALPHA_TOPOLOGY_H */
arch/alpha/Kconfig renamed from arch/alpha/Kconfig~alpha-remove-discontigmem-and-numa +0 -22
@@ -549,29 +549,12 @@ config NR_CPUS MARVEL support can handle a maximum of 32 CPUs, all the others with working support have a maximum of 4 CPUs. -config ARCH_DISCONTIGMEM_ENABLE - bool "Discontiguous Memory Support" - depends on BROKEN - help - Say Y to support efficient handling of discontiguous physical memory, - for architectures which are either NUMA (Non-Uniform Memory Access) - or have huge holes in the physical address space for other reasons. - See <file:Documentation/vm/numa.rst> for more. - config ARCH_SPARSEMEM_ENABLE bool "Sparse Memory Support" help Say Y to support efficient handling of discontiguous physical memory, for systems that have huge holes in the physical address space. -config NUMA - bool "NUMA Support (EXPERIMENTAL)" - depends on DISCONTIGMEM && BROKEN - help - Say Y to compile the kernel to support NUMA (Non-Uniform Memory - Access). This option is for configuring high-end multiprocessor - server machines. If in doubt, say N. - config ALPHA_WTINT bool "Use WTINT" if ALPHA_SRM || ALPHA_GENERIC default y if ALPHA_QEMU
@@ -596,11 +579,6 @@ config ALPHA_WTINT If unsure, say N. -config NODES_SHIFT - int - default "7" - depends on NEED_MULTIPLE_NODES - # LARGE_VMALLOC is racy, if you *really* need it then fix it first config ALPHA_LARGE_VMALLOC bool
arch/alpha/kernel/core_marvel.c renamed from arch/alpha/kernel/core_marvel.c~alpha-remove-discontigmem-and-numa +3 -50
72 lines not on this page · raw message
arch/alpha/kernel/core_wildfire.c renamed from arch/alpha/kernel/core_wildfire.c~alpha-remove-discontigmem-and-numa +1 -28
@@ -434,39 +434,12 @@ wildfire_write_config(struct pci_bus *bureturn PCIBIOS_SUCCESSFUL ; } -struct pci_ops wildfire_pci_ops = +struct pci_ops wildfire_pci_ops = { .read = wildfire_read_config, .write = wildfire_write_config, }; - -/* -* NUMA Support -*/ -int wildfire_pa_to_nid (unsigned long pa) -{ -return pa >>36 ; -} - -int wildfire_cpuid_to_nid (int cpuid) -{ -/* assume 4 CPUs per node */ -return cpuid >>2 ; -} - -unsigned long wildfire_node_mem_start (int nid) -{ -/* 64GB per node */ -return (unsigned long )nid * (64UL *1024 *1024 *1024 ); -} - -unsigned long wildfire_node_mem_size (int nid) -{ -/* 64GB per node */ -return 64UL *1024 *1024 *1024 ; -} -#if DEBUG_DUMP_REGS static void __init
arch/alpha/kernel/pci_iommu.c renamed from arch/alpha/kernel/pci_iommu.c~alpha-remove-discontigmem-and-numa +0 -29
@@ -71,33 +71,6 @@ iommu_arena_new_node(int nid, struct pciif (align < mem_size) align = mem_size; - -#ifdef CONFIG_DISCONTIGMEM - - arena =memblock_alloc_node (sizeof (*arena), align, nid); -if (!NODE_DATA (nid) || !arena) { -printk ("%s: couldn't allocate arena from node %d\n" -" falling back to system-wide allocation\n" , - __func__, nid); - arena =memblock_alloc (sizeof (*arena),SMP_CACHE_BYTES ); -if (!arena) -panic ("%s: Failed to allocate %zu bytes\n" , __func__, -sizeof (*arena)); - } - - arena->ptes =memblock_alloc_node (sizeof (*arena), align, nid); -if (!NODE_DATA (nid) || !arena->ptes) { -printk ("%s: couldn't allocate arena ptes from node %d\n" -" falling back to system-wide allocation\n" , - __func__, nid); - arena->ptes =memblock_alloc (mem_size, align); -if (!arena->ptes) -panic ("%s: Failed to allocate %lu bytes align=0x%lx\n" , - __func__, mem_size, align); - } - -#else /* CONFIG_DISCONTIGMEM */ - arena =memblock_alloc (sizeof (*arena),SMP_CACHE_BYTES );if (!arena) panic("%s: Failed to allocate %zu bytes\n", __func__,
@@ -107,8 +80,6 @@ iommu_arena_new_node(int nid, struct pcipanic ("%s: Failed to allocate %lu bytes align=0x%lx\n" , __func__, mem_size, align); -#endif /* CONFIG_DISCONTIGMEM */ -spin_lock_init (&arena->lock); arena->hose = hose; arena->dma_base = base;
arch/alpha/kernel/proto.h renamed from arch/alpha/kernel/proto.h~alpha-remove-discontigmem-and-numa +0 -8
@@ -49,10 +49,6 @@ extern void marvel_init_arch(void);extern void marvel_kill_arch (int );extern void marvel_machine_check (unsigned long ,unsigned long );extern void marvel_pci_tbi (struct pci_controller *,dma_addr_t ,dma_addr_t ); -extern int marvel_pa_to_nid (unsigned long ); -extern int marvel_cpuid_to_nid (int ); -extern unsigned long marvel_node_mem_start (int ); -extern unsigned long marvel_node_mem_size (int );extern struct _alpha_agp_info *marvel_agp_info (void );struct io7 *marvel_find_io7 (int pe);struct io7 *marvel_next_io7 (struct io7 *prev);
@@ -101,10 +97,6 @@ extern void wildfire_init_arch(void);extern void wildfire_kill_arch (int );extern void wildfire_machine_check (unsigned long vector,unsigned long la_ptr);extern void wildfire_pci_tbi (struct pci_controller *,dma_addr_t ,dma_addr_t ); -extern int wildfire_pa_to_nid (unsigned long ); -extern int wildfire_cpuid_to_nid (int ); -extern unsigned long wildfire_node_mem_start (int ); -extern unsigned long wildfire_node_mem_size (int );/* console.c */ #ifdef CONFIG_VGA_HOSE
arch/alpha/kernel/setup.c renamed from arch/alpha/kernel/setup.c~alpha-remove-discontigmem-and-numa +0 -16
@@ -79,11 +79,6 @@ int alpha_l3_cacheshape;unsigned long alpha_verbose_mcheck =CONFIG_VERBOSE_MCHECK_ON ;#endif -#ifdef CONFIG_NUMA -struct cpumask node_to_cpumask_map[MAX_NUMNODES ]__read_mostly ; -EXPORT_SYMBOL (node_to_cpumask_map); -#endif -/* Which processor we booted from. */ int boot_cpuid;
@@ -305,7 +300,6 @@ move_initrd(unsigned long mem_limit) }#endif -#ifndef CONFIG_DISCONTIGMEM static void __init setup_memory (void *kernel_end) {
@@ -389,9 +383,6 @@ setup_memory(void *kernel_end) }#endif /* CONFIG_BLK_DEV_INITRD */ } -#else -extern void setup_memory (void *); -#endif /* !CONFIG_DISCONTIGMEM */ int __init page_is_ram (unsigned long pfn)
@@ -618,13 +609,6 @@ setup_arch(char **cmdline_p) "VERBOSE_MCHECK "#endif -#ifdef CONFIG_DISCONTIGMEM -"DISCONTIGMEM " -#ifdef CONFIG_NUMA - "NUMA " -#endif -#endif -#ifdef CONFIG_DEBUG_SPINLOCK "DEBUG_SPINLOCK "#endif
arch/alpha/kernel/sys_marvel.c renamed from arch/alpha/kernel/sys_marvel.c~alpha-remove-discontigmem-and-numa +0 -5
@@ -461,10 +461,5 @@ struct alpha_machine_vector marvel_ev7_m .kill_arch = marvel_kill_arch, .pci_map_irq = marvel_map_irq, .pci_swizzle = common_swizzle, - - .pa_to_nid = marvel_pa_to_nid, - .cpuid_to_nid = marvel_cpuid_to_nid, - .node_mem_start = marvel_node_mem_start, - .node_mem_size = marvel_node_mem_size, };ALIAS_MV (marvel_ev7)
arch/alpha/kernel/sys_wildfire.c renamed from arch/alpha/kernel/sys_wildfire.c~alpha-remove-discontigmem-and-numa +0 -5
@@ -337,10 +337,5 @@ struct alpha_machine_vector wildfire_mv .kill_arch = wildfire_kill_arch, .pci_map_irq = wildfire_map_irq, .pci_swizzle = common_swizzle, - - .pa_to_nid = wildfire_pa_to_nid, - .cpuid_to_nid = wildfire_cpuid_to_nid, - .node_mem_start = wildfire_node_mem_start, - .node_mem_size = wildfire_node_mem_size, };ALIAS_MV (wildfire)
arch/alpha/mm/init.c renamed from arch/alpha/mm/init.c~alpha-remove-discontigmem-and-numa +0 -3
@@ -235,8 +235,6 @@ callback_init(void * kernel_end)return kernel_end; } - -#ifndef CONFIG_DISCONTIGMEM /* * paging_init() sets up the memory map. */
@@ -257,7 +255,6 @@ void __init paging_init(void)/* Initialize the kernel's ZERO_PGE. */ memset ((void *)ZERO_PGE ,0 ,PAGE_SIZE ); } -#endif /* CONFIG_DISCONTIGMEM */ #if defined(CONFIG_ALPHA_GENERIC ) || defined(CONFIG_ALPHA_SRM )void
arch/alpha/mm/Makefile renamed from arch/alpha/mm/Makefile~alpha-remove-discontigmem-and-numa +0 -2
@@ -6,5 +6,3 @@ ccflags-y := -Werror obj-y := init.o fault.o - -obj-$(CONFIG_DISCONTIGMEM) += numa.o
arch/alpha/mm/numa.c deleted +0 -223
223 lines not on this page · raw message
_
Patches currently in -mm which might be from [email protected] are
mmap-make-mlock_future_check-global.patch riscv-kconfig-make-direct-map-manipulation-options-depend-on-mmu.patch set_memory-allow-querying-whether-set_direct_map_-is-actually-enabled.patch mm-introduce-memfd_secret-system-call-to-create-secret-memory-areas.patch pm-hibernate-disable-when-there-are-active-secretmem-users.patch arch-mm-wire-up-memfd_secret-system-call-where-relevant.patch secretmem-test-add-basic-selftest-for-memfd_secret2.patch