mm: use clear_page_mlock() in page_remove_rmap()
[deliverable/linux.git] / mm / memory.c
index d205e4381a34a8d1aaa2c795f52f3be02c3dbe8a..5f5d1f039bf4df66b4f4cdb80fac36b83fdd30bf 100644 (file)
@@ -1577,12 +1577,12 @@ split_fallthrough:
                if (page->mapping && trylock_page(page)) {
                        lru_add_drain();  /* push cached pages to LRU */
                        /*
-                        * Because we lock page here and migration is
-                        * blocked by the pte's page reference, we need
-                        * only check for file-cache page truncation.
+                        * Because we lock page here, and migration is
+                        * blocked by the pte's page reference, and we
+                        * know the page is still mapped, we don't even
+                        * need to check for file-cache page truncation.
                         */
-                       if (page->mapping)
-                               mlock_vma_page(page);
+                       mlock_vma_page(page);
                        unlock_page(page);
                }
        }
This page took 0.023515 seconds and 5 git commands to generate.