mm-call-arch_swap_restore-from-unuse_pte.patch removed from -mm tree
The quilt patch titled
Subject: mm: call arch_swap_restore() from unuse_pte()
has been removed from the -mm tree. Its filename was
mm-call-arch_swap_restore-from-unuse_pte.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 Collingbourne <[email protected]>
Subject: mm: call arch_swap_restore() from unuse_pte()
Date: Mon, 22 May 2023 17:43:09 -0700
We would like to move away from requiring architectures to restore metadata from swap in the set_pte_at() implementation, as this is not only error-prone but adds complexity to the arch-specific code. This requires us to call arch_swap_restore() before calling swap_free() whenever pages are restored from swap. We are currently doing so everywhere except in unuse_pte(); do so there as well.
---
mm/swapfile.c | 7 +++++++ 1 file changed, 7 insertions(+)
mm/swapfile.c renamed from mm/swapfile.c~mm-call-arch_swap_restore-from-unuse_pte +7 -0
@@ -1778,6 +1778,13 @@ static int unuse_pte(struct vm_area_stru goto setpte; } +/* +* Some architectures may have to restore extra metadata to the page +* when reading from swap. This metadata may be indexed by swap entry +* so this must be called before swap_free(). +*/ +arch_swap_restore (entry,page_folio (page)); +/* See do_swap_page() */ BUG_ON (!PageAnon (page) &&PageMappedToDisk (page));BUG_ON (PageAnon (page) &&PageAnonExclusive (page));
_
Patches currently in -mm which might be from [email protected] are