Skip to contentSkip to conversation

powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Aug 11, 2023

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: powerpc/book3s64/radix: add support for vmemmap optimization for radix
has been removed from the -mm tree. Its filename was
powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix.patch

This patch was dropped because it was merged into the mm-stable branch of git://git.kernel.org/pub/scm/linux/kernel/git/akpm/mm

------------------------------------------------------
From: "Aneesh Kumar K.V" <[email protected]>
Subject: powerpc/book3s64/radix: add support for vmemmap optimization for radix
Date: Tue, 25 Jul 2023 00:37:57 +0530

With 2M PMD-level mapping, we require 32 struct pages and a single vmemmap page can contain 1024 struct pages (PAGE_SIZE/sizeof(struct page)). Hence with 64K page size, we don't use vmemmap deduplication for PMD-level mapping.

[[email protected]: ppc64: don't include radix headers if CONFIG_PPC_RADIX_MMU=n]
Cc Catalin Marinas <[email protected]>
Cc Christophe Leroy <[email protected]>
Cc Dan Williams <[email protected]>
Cc Joao Martins <[email protected]>
Cc Michael Ellerman <[email protected]>
Cc Mike Kravetz <[email protected]>
Cc Muchun Song <[email protected]>
Cc Nicholas Piggin <[email protected]>
Cc Oscar Salvador <[email protected]>
Cc Will Deacon <[email protected]>

---

 Documentation/mm/vmemmap_dedup.rst         |    1 
 Documentation/powerpc/index.rst            |    1 
 Documentation/powerpc/vmemmap_dedup.rst    |  101 +++++++++
 arch/powerpc/Kconfig                       |    1 
 arch/powerpc/include/asm/book3s/64/radix.h |   11 +
 arch/powerpc/mm/book3s64/radix_pgtable.c   |  203 +++++++++++++++++++
 6 files changed, 318 insertions(+)
arch/powerpc/include/asm/book3s/64/radix.h renamed from arch/powerpc/include/asm/book3s/64/radix.h~powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix +11 -0
@@ -326,6 +326,7 @@ static inline pud_t radix__pud_mkdevmap(
 }
 
 struct vmem_altmap;
+struct dev_pagemap;
 extern int __meminit radix__vmemmap_create_mapping(unsigned long start,
 					     unsigned long page_size,
 					     unsigned long phys);
@@ -363,5 +364,15 @@ int radix__remove_section_mapping(unsign
 
 void radix__kernel_map_pages(struct page *page, int numpages, int enable);
 
+#ifdef CONFIG_ARCH_WANT_OPTIMIZE_DAX_VMEMMAP
+#define vmemmap_can_optimize vmemmap_can_optimize
+bool vmemmap_can_optimize(struct vmem_altmap *altmap, struct dev_pagemap *pgmap);
+#endif
+
+#define vmemmap_populate_compound_pages vmemmap_populate_compound_pages
+int __meminit vmemmap_populate_compound_pages(unsigned long start_pfn,
+					      unsigned long start,
+					      unsigned long end, int node,
+					      struct dev_pagemap *pgmap);
 #endif /* __ASSEMBLY__ */
 #endif
arch/powerpc/Kconfig renamed from arch/powerpc/Kconfig~powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix +1 -0
@@ -174,6 +174,7 @@ config PPC
 	select ARCH_WANT_IPC_PARSE_VERSION
 	select ARCH_WANT_IRQS_OFF_ACTIVATE_MM
 	select ARCH_WANT_LD_ORPHAN_WARN
+	select ARCH_WANT_OPTIMIZE_DAX_VMEMMAP	if PPC_RADIX_MMU
 	select ARCH_WANTS_MODULES_DATA_IN_VMALLOC	if PPC_BOOK3S_32 || PPC_8xx
 	select ARCH_WEAK_RELEASE_ACQUIRE
 	select BINFMT_ELF
arch/powerpc/mm/book3s64/radix_pgtable.c renamed from arch/powerpc/mm/book3s64/radix_pgtable.c~powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix +203 -0

215 lines not on this page · raw message

Documentation/mm/vmemmap_dedup.rst renamed from Documentation/mm/vmemmap_dedup.rst~powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix +1 -0
@@ -210,6 +210,7 @@ the device (altmap).
 
 The following page sizes are supported in DAX: PAGE_SIZE (4K on x86_64),
 PMD_SIZE (2M on x86_64) and PUD_SIZE (1G on x86_64).
+For powerpc equivalent details see Documentation/powerpc/vmemmap_dedup.rst
 
 The differences with HugeTLB are relatively minor.
 
Documentation/powerpc/index.rst renamed from Documentation/powerpc/index.rst~powerpc-book3s64-radix-add-support-for-vmemmap-optimization-for-radix +1 -0
@@ -36,6 +36,7 @@ powerpc
     ultravisor
     vas-api
     vcpudispatch_stats
+    vmemmap_dedup
 
     features
 
Documentation/powerpc/vmemmap_dedup.rst new file +101 -0

101 lines not on this page · raw message

_

Patches currently in -mm which might be from [email protected] are

mm-memory_hotplug-simplify-arch_mhp_memmap_on_memory_enable-kconfig.patch mm-memory_hotplug-allow-memmap-on-memory-hotplug-request-to-fallback.patch mm-memory_hotplug-allow-architecture-to-override-memmap-on-memory-support-check.patch mm-memory_hotplug-support-memmap_on_memory-when-memmap-is-not-aligned-to-pageblocks.patch powerpc-book3s64-memhotplug-enable-memmap-on-memory-for-radix.patch mm-memory_hotplug-embed-vmem_altmap-details-in-memory-block.patch