Skip to content

Commit 4257889

Browse files
Ralph Campbelltorvalds
authored andcommitted
mm/migrate: remove cpages-- in migrate_vma_finalize()
The variable struct migrate_vma->cpages is only used in migrate_vma_setup(). There is no need to decrement it in migrate_vma_finalize() since it is never checked. Signed-off-by: Ralph Campbell <rcampbell@nvidia.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Cc: Jason Gunthorpe <jgg@nvidia.com> Cc: Jerome Glisse <jglisse@redhat.com> Cc: John Hubbard <jhubbard@nvidia.com> Cc: Christoph Hellwig <hch@lst.de> Link: http://lkml.kernel.org/r/20200827190735.12752-1-rcampbell@nvidia.com Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
1 parent 67197a4 commit 4257889

1 file changed

Lines changed: 0 additions & 1 deletion

File tree

mm/migrate.c

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3077,7 +3077,6 @@ void migrate_vma_finalize(struct migrate_vma *migrate)
30773077

30783078
remove_migration_ptes(page, newpage, false);
30793079
unlock_page(page);
3080-
migrate->cpages--;
30813080

30823081
if (is_zone_device_page(page))
30833082
put_page(page);

0 commit comments

Comments
 (0)