summaryrefslogtreecommitdiffstats
path: root/mm/migrate.c
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-16 03:22:49 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-04-16 03:22:49 +0000
commit87662aef9c2f9405ca8937c07372641e69113654 (patch)
tree612907d41d90d34f497c4bfbbfd9fbd368d2a1d7 /mm/migrate.c
parentAdding debian version 6.1.82-1. (diff)
downloadlinux-87662aef9c2f9405ca8937c07372641e69113654.tar.xz
linux-87662aef9c2f9405ca8937c07372641e69113654.zip
Merging upstream version 6.1.85.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mm/migrate.c')
-rw-r--r--mm/migrate.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/mm/migrate.c b/mm/migrate.c
index c93dd6a31..c5968021f 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -423,8 +423,12 @@ int folio_migrate_mapping(struct address_space *mapping,
if (folio_test_swapbacked(folio)) {
__folio_set_swapbacked(newfolio);
if (folio_test_swapcache(folio)) {
+ int i;
+
folio_set_swapcache(newfolio);
- newfolio->private = folio_get_private(folio);
+ for (i = 0; i < nr; i++)
+ set_page_private(folio_page(newfolio, i),
+ page_private(folio_page(folio, i)));
}
entries = nr;
} else {