mm-treewide-remove-pxd_huge.patch removed from -mm tree
The quilt patch titled
Subject: mm/treewide: remove pXd_huge()
has been removed from the -mm tree. Its filename was
mm-treewide-remove-pxd_huge.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: Peter Xu <[email protected]>
Subject: mm/treewide: remove pXd_huge()
Date: Mon, 18 Mar 2024 16:04:02 -0400
This API is not used anymore, drop it for the whole tree.
---
arch/arm/mm/Makefile | 1 arch/arm/mm/hugetlbpage.c | 29 ------------- arch/arm64/mm/hugetlbpage.c | 10 ---- arch/loongarch/mm/hugetlbpage.c | 10 ---- arch/mips/include/asm/pgtable-32.h | 2 arch/mips/include/asm/pgtable-64.h | 2 arch/mips/mm/hugetlbpage.c | 10 ---- arch/parisc/mm/hugetlbpage.c | 11 ---- arch/powerpc/include/asm/book3s/64/pgtable-4k.h | 10 ---- arch/powerpc/include/asm/book3s/64/pgtable-64k.h | 25 ----------- arch/powerpc/include/asm/nohash/pgtable.h | 10 ---- arch/riscv/mm/hugetlbpage.c | 10 ---- arch/s390/mm/hugetlbpage.c | 10 ---- arch/sh/mm/hugetlbpage.c | 10 ---- arch/sparc/mm/hugetlbpage.c | 10 ---- arch/x86/mm/hugetlbpage.c | 16 ------- include/linux/hugetlb.h | 24 ---------- 17 files changed, 2 insertions(+), 198 deletions(-)
arch/arm64/mm/hugetlbpage.c renamed from arch/arm64/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -79,16 +79,6 @@ bool arch_hugetlb_migration_supported(st }#endif -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} - -int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} -static int find_num_contig (struct mm_struct *mm,unsigned long addr,pte_t *ptep,size_t *pgsize) {
arch/arm/mm/hugetlbpage.c deleted +0 -29
@@ -1,29 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-only -/* -* arch/arm/mm/hugetlbpage.c -* -* Copyright (C) 2012 ARM Ltd. -* -* Based on arch/x86/include/asm/hugetlb.h and Bill Carson's patches -*/ - -#include <linux/init.h> -#include <linux/fs.h> -#include <linux/mm.h> -#include <linux/hugetlb.h> -#include <linux/pagemap.h> -#include <linux/err.h> -#include <linux/sysctl.h> -#include <asm/mman.h> -#include <asm/tlb.h> -#include <asm/tlbflush.h> - -int pud_huge (pud_t pud) -{ -return 0 ; -} - -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -}
arch/arm/mm/Makefile renamed from arch/arm/mm/Makefile~mm-treewide-remove-pxd_huge +0 -1
@@ -21,7 +21,6 @@ KASAN_SANITIZE_physaddr.o := n obj-$(CONFIG_DEBUG_VIRTUAL) += physaddr.o obj-$(CONFIG_ALIGNMENT_TRAP) += alignment.o -obj-$(CONFIG_HUGETLB_PAGE) += hugetlbpage.o obj-$(CONFIG_ARM_PV_FIXUP) += pv-fixup-asm.o obj-$(CONFIG_CPU_ABRT_NOMMU) += abort-nommu.o
arch/loongarch/mm/hugetlbpage.c renamed from arch/loongarch/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -50,16 +50,6 @@ pte_t *huge_pte_offset(struct mm_structreturn (pte_t *) pmd; } -int pmd_huge (pmd_t pmd) -{ -return (pmd_val (pmd) & _PAGE_HUGE) !=0 ; -} - -int pud_huge (pud_t pud) -{ -return (pud_val (pud) & _PAGE_HUGE) !=0 ; -} -uint64_t pmd_to_entrylo (unsigned long pmd_val) {uint64_t val;
arch/mips/include/asm/pgtable-32.h renamed from arch/mips/include/asm/pgtable-32.h~mm-treewide-remove-pxd_huge +1 -1
@@ -129,7 +129,7 @@ static inline int pmd_none(pmd_t pmd)static inline int pmd_bad (pmd_t pmd) {#ifdef CONFIG_MIPS_HUGE_TLB_SUPPORT -/* pmd_huge(pmd) but inline */ +/* pmd_leaf(pmd) but inline */ if (unlikely (pmd_val (pmd) & _PAGE_HUGE))return 0 ;#endif
arch/mips/include/asm/pgtable-64.h renamed from arch/mips/include/asm/pgtable-64.h~mm-treewide-remove-pxd_huge +1 -1
@@ -245,7 +245,7 @@ static inline int pmd_none(pmd_t pmd)static inline int pmd_bad (pmd_t pmd) {#ifdef CONFIG_MIPS_HUGE_TLB_SUPPORT -/* pmd_huge(pmd) but inline */ +/* pmd_leaf(pmd) but inline */ if (unlikely (pmd_val (pmd) & _PAGE_HUGE))return 0 ;#endif
arch/mips/mm/hugetlbpage.c renamed from arch/mips/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -57,13 +57,3 @@ pte_t *huge_pte_offset(struct mm_struct }return (pte_t *) pmd; } - -int pmd_huge (pmd_t pmd) -{ -return (pmd_val (pmd) & _PAGE_HUGE) !=0 ; -} - -int pud_huge (pud_t pud) -{ -return (pud_val (pud) & _PAGE_HUGE) !=0 ; -}
arch/parisc/mm/hugetlbpage.c renamed from arch/parisc/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -11
@@ -180,14 +180,3 @@ int huge_ptep_set_access_flags(struct vm }return changed; } - - -int pmd_huge (pmd_t pmd) -{ -return 0 ; -} - -int pud_huge (pud_t pud) -{ -return 0 ; -}
arch/powerpc/include/asm/book3s/64/pgtable-4k.h renamed from arch/powerpc/include/asm/book3s/64/pgtable-4k.h~mm-treewide-remove-pxd_huge +0 -10
@@ -6,16 +6,6 @@*/ #ifndef __ASSEMBLY__#ifdef CONFIG_HUGETLB_PAGE -static inline int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} - -static inline int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} -/* * With radix , we have hugepage ptes in the pud and pmd entries. We don't * need to setup hugepage directory for them. Our pte and page directory format
arch/powerpc/include/asm/book3s/64/pgtable-64k.h renamed from arch/powerpc/include/asm/book3s/64/pgtable-64k.h~mm-treewide-remove-pxd_huge +0 -25
@@ -4,31 +4,6 @@#ifndef __ASSEMBLY__#ifdef CONFIG_HUGETLB_PAGE -/* -* We have PGD_INDEX_SIZ = 12 and PTE_INDEX_SIZE = 8, so that we can have -* 16GB hugepage pte in PGD and 16MB hugepage pte at PMD; -* -* Defined in such a way that we can optimize away code block at build time -* if CONFIG_HUGETLB_PAGE=n. -* -* returns true for pmd migration entries, THP, devmap, hugetlb -* But compile time dependent on CONFIG_HUGETLB_PAGE -*/ -static inline int pmd_huge (pmd_t pmd) -{ -/* -* leaf pte for huge page -*/ -return !!(pmd_raw (pmd) &cpu_to_be64 (_PAGE_PTE)); -} - -static inline int pud_huge (pud_t pud) -{ -/* -* leaf pte for huge page -*/ -return !!(pud_raw (pud) &cpu_to_be64 (_PAGE_PTE)); -}/* * With 64k page size, we have hugepage ptes in the pgd and pmd entries. We don't
arch/powerpc/include/asm/nohash/pgtable.h renamed from arch/powerpc/include/asm/nohash/pgtable.h~mm-treewide-remove-pxd_huge +0 -10
@@ -351,16 +351,6 @@ static inline int hugepd_ok(hugepd_t hpd #endif } -static inline int pmd_huge (pmd_t pmd) -{ -return 0 ; -} - -static inline int pud_huge (pud_t pud) -{ -return 0 ; -} -#define is_hugepd (hpd) (hugepd_ok(hpd))#endif
arch/riscv/mm/hugetlbpage.c renamed from arch/riscv/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -399,16 +399,6 @@ static bool is_napot_size(unsigned long#endif /*CONFIG_RISCV_ISA_SVNAPOT*/ -int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} - -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} -static bool __hugetlb_valid_size (unsigned long size) {if (size ==HPAGE_SIZE )
arch/s390/mm/hugetlbpage.c renamed from arch/s390/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -233,16 +233,6 @@ pte_t *huge_pte_offset(struct mm_structreturn (pte_t *) pmdp; } -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} - -int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} -bool __init arch_hugetlb_valid_size (unsigned long size) {if (MACHINE_HAS_EDAT1 && size ==PMD_SIZE )
arch/sh/mm/hugetlbpage.c renamed from arch/sh/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -70,13 +70,3 @@ pte_t *huge_pte_offset(struct mm_structreturn pte; } - -int pmd_huge (pmd_t pmd) -{ -return 0 ; -} - -int pud_huge (pud_t pud) -{ -return 0 ; -}
arch/sparc/mm/hugetlbpage.c renamed from arch/sparc/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -10
@@ -407,16 +407,6 @@ pte_t huge_ptep_get_and_clear(struct mm_return entry; } -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} - -int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} -static void hugetlb_free_pte_range (struct mmu_gather *tlb,pmd_t *pmd,unsigned long addr) {
arch/x86/mm/hugetlbpage.c renamed from arch/x86/mm/hugetlbpage.c~mm-treewide-remove-pxd_huge +0 -16
@@ -19,22 +19,6 @@#include <asm/tlbflush.h> #include <asm/elf.h> -/* -* pmd_huge() returns 1 if @pmd is hugetlb related entry. -*/ -int pmd_huge (pmd_t pmd) -{ -return pmd_leaf (pmd); -} - -/* -* pud_huge() returns 1 if @pud is hugetlb related entry. -*/ -int pud_huge (pud_t pud) -{ -return pud_leaf (pud); -} -#ifdef CONFIG_HUGETLB_PAGE static unsigned long hugetlb_get_unmapped_area_bottomup(struct file *file, unsigned long addr, unsigned long len,
include/linux/hugetlb.h renamed from include/linux/hugetlb.h~mm-treewide-remove-pxd_huge +0 -24
@@ -272,13 +272,9 @@ void hugetlb_vma_unlock_write(struct vm_int hugetlb_vma_trylock_write (struct vm_area_struct *vma);void hugetlb_vma_assert_locked (struct vm_area_struct *vma);void hugetlb_vma_lock_release (struct kref *kref); - -int pmd_huge (pmd_t pmd); -int pud_huge (pud_t pud);long hugetlb_change_protection (struct vm_area_struct *vma,unsigned long address,unsigned long end,pgprot_t newprot,unsigned long cp_flags); -bool is_hugetlb_entry_migration (pte_t pte);bool is_hugetlb_entry_hwpoisoned (pte_t pte);void hugetlb_unshare_all_pmds (struct vm_area_struct *vma);
@@ -399,16 +395,6 @@ static inline void hugetlb_vma_assert_lo { } -static inline int pmd_huge (pmd_t pmd) -{ -return 0 ; -} - -static inline int pud_huge (pud_t pud) -{ -return 0 ; -} -static inline int is_hugepage_only_range (struct mm_struct *mm,unsigned long addr,unsigned long len) {
@@ -493,16 +479,6 @@ static inline vm_fault_t hugetlb_fault(sstatic inline void hugetlb_unshare_all_pmds (struct vm_area_struct *vma) { }#endif /* !CONFIG_HUGETLB_PAGE */ -/* -* hugepages at page global directory. If arch support -* hugepages at pgd level, they need to define this. -*/ -#ifndef pgd_huge -#define pgd_huge (x) 0 -#endif -#ifndef p4d_huge -#define p4d_huge (x) 0 -#endif #ifndef pgd_writestatic inline int pgd_write (pgd_t pgd)
_
Patches currently in -mm which might be from [email protected] are
mm-userfaultfd-reset-ptes-when-close-for-wr-protected-ones.patch mm-hugetlb-assert-hugetlb_lock-in-__hugetlb_cgroup_commit_charge.patch mm-page_table_check-support-userfault-wr-protect-entries.patch