aboutsummaryrefslogtreecommitdiffstats
path: root/mm/migrate.c
diff options
context:
space:
mode:
Diffstat (limited to 'mm/migrate.c')
-rw-r--r--mm/migrate.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/mm/migrate.c b/mm/migrate.c
index 6c822a7b27e0..f9dfb18a4eba 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -975,7 +975,13 @@ out:
975 dec_zone_page_state(page, NR_ISOLATED_ANON + 975 dec_zone_page_state(page, NR_ISOLATED_ANON +
976 page_is_file_cache(page)); 976 page_is_file_cache(page));
977 /* Soft-offlined page shouldn't go through lru cache list */ 977 /* Soft-offlined page shouldn't go through lru cache list */
978 if (reason == MR_MEMORY_FAILURE) { 978 if (reason == MR_MEMORY_FAILURE && rc == MIGRATEPAGE_SUCCESS) {
979 /*
980 * With this release, we free successfully migrated
981 * page and set PG_HWPoison on just freed page
982 * intentionally. Although it's rather weird, it's how
983 * HWPoison flag works at the moment.
984 */
979 put_page(page); 985 put_page(page);
980 if (!test_set_page_hwpoison(page)) 986 if (!test_set_page_hwpoison(page))
981 num_poisoned_pages_inc(); 987 num_poisoned_pages_inc();