Signed-off-by: Pingfan Liu <[email protected]>
Cc: "Jérôme Glisse" <[email protected]>
Cc: Andrew Morton <[email protected]>
Cc: Mel Gorman <[email protected]>
Cc: Jan Kara <[email protected]>
Cc: "Kirill A. Shutemov" <[email protected]>
Cc: Michal Hocko <[email protected]>
Cc: Mike Kravetz <[email protected]>
Cc: Andrea Arcangeli <[email protected]>
Cc: Matthew Wilcox <[email protected]>
To: [email protected]
Cc: [email protected]
---
 mm/migrate.c | 5 +----
 1 file changed, 1 insertion(+), 4 deletions(-)

diff --git a/mm/migrate.c b/mm/migrate.c
index 8992741..c2ec614 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -2230,7 +2230,6 @@ static int migrate_vma_collect_pmd(pmd_t *pmdp,
                if (pte_none(pte)) {
                        mpfn = MIGRATE_PFN_MIGRATE;
                        migrate->cpages++;
-                       pfn = 0;
                        goto next;
                }
 
@@ -2255,7 +2254,6 @@ static int migrate_vma_collect_pmd(pmd_t *pmdp,
                        if (is_zero_pfn(pfn)) {
                                mpfn = MIGRATE_PFN_MIGRATE;
                                migrate->cpages++;
-                               pfn = 0;
                                goto next;
                        }
                        page = vm_normal_page(migrate->vma, addr, pte);
@@ -2265,10 +2263,9 @@ static int migrate_vma_collect_pmd(pmd_t *pmdp,
 
                /* FIXME support THP */
                if (!page || !page->mapping || PageTransCompound(page)) {
-                       mpfn = pfn = 0;
+                       mpfn = 0;
                        goto next;
                }
-               pfn = page_to_pfn(page);
 
                /*
                 * By getting a reference on the page we pin it and that blocks
-- 
2.7.5

Reply via email to