Skip to contentSkip to conversation

x86-mm-convert-pte_next_pfn-to-pte_advance_pfn.patch removed from -mm tree

merged mm-stable Andrew Morton 1 participant 1 message Feb 22, 2024

lore
Share & tools
lore

Andrew Morton

author tree notice Applied
#0 lore raw

The quilt patch titled
Subject: x86/mm: convert pte_next_pfn() to pte_advance_pfn()
has been removed from the -mm tree. Its filename was
x86-mm-convert-pte_next_pfn-to-pte_advance_pfn.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: Ryan Roberts <[email protected]>
Subject: x86/mm: convert pte_next_pfn() to pte_advance_pfn()
Date: Thu, 15 Feb 2024 10:31:52 +0000

Core-mm needs to be able to advance the pfn by an arbitrary amount, so override the new pte_advance_pfn() API to do so.

Cc Alistair Popple <[email protected]>
Cc Andrey Ryabinin <[email protected]>
Cc Ard Biesheuvel <[email protected]>
Cc Barry Song <[email protected]>
Cc Borislav Petkov (AMD) <[email protected]>
Cc Catalin Marinas <[email protected]>
Cc Dave Hansen <[email protected]>
Cc "H. Peter Anvin" <[email protected]>
Cc Ingo Molnar <[email protected]>
Cc James Morse <[email protected]>
Cc John Hubbard <[email protected]>
Cc Kefeng Wang <[email protected]>
Cc Marc Zyngier <[email protected]>
Cc Mark Rutland <[email protected]>
Cc Matthew Wilcox (Oracle) <[email protected]>
Cc Thomas Gleixner <[email protected]>
Cc Will Deacon <[email protected]>
Cc Yang Shi <[email protected]>
Cc Zi Yan <[email protected]>

---

 arch/x86/include/asm/pgtable.h |    8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
arch/x86/include/asm/pgtable.h renamed from arch/x86/include/asm/pgtable.h~x86-mm-convert-pte_next_pfn-to-pte_advance_pfn +4 -4
@@ -955,13 +955,13 @@ static inline int pte_same(pte_t a, pte_
 	return a.pte == b.pte;
 }
 
-static inline pte_t pte_next_pfn(pte_t pte)
+static inline pte_t pte_advance_pfn(pte_t pte, unsigned long nr)
 {
 	if (__pte_needs_invert(pte_val(pte)))
-		return __pte(pte_val(pte) - (1UL << PFN_PTE_SHIFT));
-	return __pte(pte_val(pte) + (1UL << PFN_PTE_SHIFT));
+		return __pte(pte_val(pte) - (nr << PFN_PTE_SHIFT));
+	return __pte(pte_val(pte) + (nr << PFN_PTE_SHIFT));
 }
-#define pte_next_pfn	pte_next_pfn
+#define pte_advance_pfn	pte_advance_pfn
 
 static inline int pte_present(pte_t a)
 {

_

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