Merge "Merge keystone/android14-6.1-keystone-qcom-release.6.1.57 (daf56c4) into qcom-6.1"

This commit is contained in:
qctecmdr 2024-01-29 00:41:38 -08:00 committed by Gerrit - the friendly Code Review server
commit d8fea64391
2 changed files with 10 additions and 3 deletions

View File

@ -1,2 +1,2 @@
a2fa77d36d26b574cffec6766df50a711f305450
android14-6.1-2023-11_r3
6dd1f54e29ea4c4ec0c508ab8a7b78991e2ca25b
android14-6.1-2023-12_r2

View File

@ -393,6 +393,7 @@ int folio_migrate_mapping(struct address_space *mapping,
int dirty;
int expected_count = folio_expected_refs(mapping, folio) + extra_count;
long nr = folio_nr_pages(folio);
long entries, i;
if (!mapping) {
/* Anonymous page without mapping */
@ -430,8 +431,10 @@ int folio_migrate_mapping(struct address_space *mapping,
folio_set_swapcache(newfolio);
newfolio->private = folio_get_private(folio);
}
entries = nr;
} else {
VM_BUG_ON_FOLIO(folio_test_swapcache(folio), folio);
entries = 1;
}
/* Move dirty while page refs frozen and newpage not yet exposed */
@ -441,7 +444,11 @@ int folio_migrate_mapping(struct address_space *mapping,
folio_set_dirty(newfolio);
}
xas_store(&xas, newfolio);
/* Swap cache still stores N entries instead of a high-order entry */
for (i = 0; i < entries; i++) {
xas_store(&xas, newfolio);
xas_next(&xas);
}
/*
* Drop cache reference from old page by unfreezing