]> git.karo-electronics.de Git - mv-sheeva.git/blobdiff - mm/vmscan.c
[PATCH] mm: exit_mmap need not reset
[mv-sheeva.git] / mm / vmscan.c
index 843c87d1e61f5f63e68aa53a903567a3802958f8..41d1064aabfb944c87c2c7e62ce33fbb7c664b15 100644 (file)
@@ -417,7 +417,9 @@ static int shrink_list(struct list_head *page_list, struct scan_control *sc)
                 * Anonymous process memory has backing store?
                 * Try to allocate it some swap space here.
                 */
-               if (PageAnon(page) && !PageSwapCache(page) && sc->may_swap) {
+               if (PageAnon(page) && !PageSwapCache(page)) {
+                       if (!sc->may_swap)
+                               goto keep_locked;
                        if (!add_to_swap(page))
                                goto activate_locked;
                }