]> git.karo-electronics.de Git - karo-tx-linux.git/commitdiff
mm-adjust-address_space_operationsmigratepage-return-code-fix
authorAndrew Morton <akpm@linux-foundation.org>
Fri, 9 Nov 2012 03:04:30 +0000 (14:04 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Tue, 13 Nov 2012 05:15:37 +0000 (16:15 +1100)
Cc: Rafael Aquini <aquini@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/migrate.c

index 10c77c0154b4af91122cb1c14ea7b8f62c2e6dc8..2424efba605d46cf3146b52cf0326eeb05501e31 100644 (file)
@@ -996,15 +996,12 @@ int migrate_pages(struct list_head *from,
                        }
                }
        }
-       rc = 0;
+       rc = nr_failed + retry;
 out:
        if (!swapwrite)
                current->flags &= ~PF_SWAPWRITE;
 
-       if (rc != MIGRATEPAGE_SUCCESS)
-               return rc;
-
-       return nr_failed + retry;
+       return rc;
 }
 
 int migrate_huge_page(struct page *hpage, new_page_t get_new_page,