aboutsummaryrefslogtreecommitdiffstats
path: root/mm
diff options
context:
space:
mode:
Diffstat (limited to 'mm')
-rw-r--r--mm/memory-failure.c10
1 files changed, 10 insertions, 0 deletions
diff --git a/mm/memory-failure.c b/mm/memory-failure.c
index a013bc94ebbe..44c6bd201d3a 100644
--- a/mm/memory-failure.c
+++ b/mm/memory-failure.c
@@ -1173,6 +1173,16 @@ int memory_failure(unsigned long pfn, int trapno, int flags)
1173 lock_page(hpage); 1173 lock_page(hpage);
1174 1174
1175 /* 1175 /*
1176 * The page could have changed compound pages during the locking.
1177 * If this happens just bail out.
1178 */
1179 if (compound_head(p) != hpage) {
1180 action_result(pfn, "different compound page after locking", IGNORED);
1181 res = -EBUSY;
1182 goto out;
1183 }
1184
1185 /*
1176 * We use page flags to determine what action should be taken, but 1186 * We use page flags to determine what action should be taken, but
1177 * the flags can be modified by the error containment action. One 1187 * the flags can be modified by the error containment action. One
1178 * example is an mlocked page, where PG_mlocked is cleared by 1188 * example is an mlocked page, where PG_mlocked is cleared by