]> git.karo-electronics.de Git - karo-tx-linux.git/commit
mm: migrate: one less atomic operation
authorJacobo Giralt <jacobo.giralt@gmail.com>
Thu, 8 Dec 2011 04:38:54 +0000 (15:38 +1100)
committerStephen Rothwell <sfr@canb.auug.org.au>
Fri, 9 Dec 2011 04:52:33 +0000 (15:52 +1100)
commit9f07097dcc4c282d4be4a904ed759c81aa2c72de
tree3849c4102ceb066b74ce8bc162118443f021d33b
parentdc11953d0db5e8dab0ead20c77f408943eb50a5e
mm: migrate: one less atomic operation

migrate_page_move_mapping() drops a reference from the old page after
unfreezing its counter.  Both operations can be merged into a single
atomic operation by directly unfreezing to one less reference.

The same applies to migrate_huge_page_move_mapping().

Signed-off-by: Jacobo Giralt <jacobo.giralt@gmail.com>
Cc: Mel Gorman <mel@csn.ul.ie>
Cc: Minchan Kim <minchan.kim@gmail.com>
Cc: Johannes Weiner <jweiner@redhat.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
mm/migrate.c