Loading arch/s390/Kconfig +4 −0 Original line number Diff line number Diff line Loading @@ -313,6 +313,10 @@ config ARCH_SPARSEMEM_DEFAULT config ARCH_SELECT_MEMORY_MODEL def_bool y config ARCH_ENABLE_MEMORY_HOTPLUG def_bool y depends on SPARSEMEM source "mm/Kconfig" comment "I/O subsystem configuration" Loading arch/s390/mm/init.c +19 −0 Original line number Diff line number Diff line Loading @@ -202,3 +202,22 @@ void free_initrd_mem(unsigned long start, unsigned long end) } } #endif #ifdef CONFIG_MEMORY_HOTPLUG int arch_add_memory(int nid, u64 start, u64 size) { struct pglist_data *pgdat; struct zone *zone; int rc; pgdat = NODE_DATA(nid); zone = pgdat->node_zones + ZONE_NORMAL; rc = vmem_add_mapping(start, size); if (rc) return rc; rc = __add_pages(zone, PFN_DOWN(start), PFN_DOWN(size)); if (rc) vmem_remove_mapping(start, size); return rc; } #endif /* CONFIG_MEMORY_HOTPLUG */ include/asm-s390/sparsemem.h +2 −2 Original line number Diff line number Diff line #ifndef _ASM_S390_SPARSEMEM_H #define _ASM_S390_SPARSEMEM_H #define SECTION_SIZE_BITS 25 #ifdef CONFIG_64BIT #define SECTION_SIZE_BITS 28 #define MAX_PHYSADDR_BITS 42 #define MAX_PHYSMEM_BITS 42 #else #define SECTION_SIZE_BITS 25 #define MAX_PHYSADDR_BITS 31 #define MAX_PHYSMEM_BITS 31 Loading mm/Kconfig +1 −1 Original line number Diff line number Diff line Loading @@ -129,7 +129,7 @@ config MEMORY_HOTPLUG bool "Allow for memory hot-add" depends on SPARSEMEM || X86_64_ACPI_NUMA depends on HOTPLUG && !HIBERNATION && ARCH_ENABLE_MEMORY_HOTPLUG depends on (IA64 || X86 || PPC64 || SUPERH) depends on (IA64 || X86 || PPC64 || SUPERH || S390) comment "Memory hotplug is currently incompatible with Software Suspend" depends on SPARSEMEM && HOTPLUG && HIBERNATION Loading Loading
arch/s390/Kconfig +4 −0 Original line number Diff line number Diff line Loading @@ -313,6 +313,10 @@ config ARCH_SPARSEMEM_DEFAULT config ARCH_SELECT_MEMORY_MODEL def_bool y config ARCH_ENABLE_MEMORY_HOTPLUG def_bool y depends on SPARSEMEM source "mm/Kconfig" comment "I/O subsystem configuration" Loading
arch/s390/mm/init.c +19 −0 Original line number Diff line number Diff line Loading @@ -202,3 +202,22 @@ void free_initrd_mem(unsigned long start, unsigned long end) } } #endif #ifdef CONFIG_MEMORY_HOTPLUG int arch_add_memory(int nid, u64 start, u64 size) { struct pglist_data *pgdat; struct zone *zone; int rc; pgdat = NODE_DATA(nid); zone = pgdat->node_zones + ZONE_NORMAL; rc = vmem_add_mapping(start, size); if (rc) return rc; rc = __add_pages(zone, PFN_DOWN(start), PFN_DOWN(size)); if (rc) vmem_remove_mapping(start, size); return rc; } #endif /* CONFIG_MEMORY_HOTPLUG */
include/asm-s390/sparsemem.h +2 −2 Original line number Diff line number Diff line #ifndef _ASM_S390_SPARSEMEM_H #define _ASM_S390_SPARSEMEM_H #define SECTION_SIZE_BITS 25 #ifdef CONFIG_64BIT #define SECTION_SIZE_BITS 28 #define MAX_PHYSADDR_BITS 42 #define MAX_PHYSMEM_BITS 42 #else #define SECTION_SIZE_BITS 25 #define MAX_PHYSADDR_BITS 31 #define MAX_PHYSMEM_BITS 31 Loading
mm/Kconfig +1 −1 Original line number Diff line number Diff line Loading @@ -129,7 +129,7 @@ config MEMORY_HOTPLUG bool "Allow for memory hot-add" depends on SPARSEMEM || X86_64_ACPI_NUMA depends on HOTPLUG && !HIBERNATION && ARCH_ENABLE_MEMORY_HOTPLUG depends on (IA64 || X86 || PPC64 || SUPERH) depends on (IA64 || X86 || PPC64 || SUPERH || S390) comment "Memory hotplug is currently incompatible with Software Suspend" depends on SPARSEMEM && HOTPLUG && HIBERNATION Loading