summaryrefslogtreecommitdiffstats
path: root/mm/migrate.c
diff options
context:
space:
mode:
authorJohannes Weiner <hannes@cmpxchg.org>2009-09-21 17:02:59 -0700
committerLinus Torvalds <torvalds@linux-foundation.org>2009-09-22 07:17:38 -0700
commitedcf4748cd56adcdf0856cc99ef108a4ea3ac7fe (patch)
tree317d477d08dea82f5eef2e9c17294d0f0639ea81 /mm/migrate.c
parent6c0b13519d1c755d874e82c8fb8a6dcef0ee402c (diff)
downloadlinux-stable-edcf4748cd56adcdf0856cc99ef108a4ea3ac7fe.tar.gz
linux-stable-edcf4748cd56adcdf0856cc99ef108a4ea3ac7fe.tar.bz2
linux-stable-edcf4748cd56adcdf0856cc99ef108a4ea3ac7fe.zip
mm: return boolean from page_has_private()
Make page_has_private() return a true boolean value and remove the double negations from the two callsites using it for arithmetic. Signed-off-by: Johannes Weiner <hannes@cmpxchg.org> Cc: Christoph Lameter <cl@linux-foundation.org> Reviewed-by: Christoph Lameter <cl@linux-foundation.org> Reviewed-by: KOSAKI Motohiro <kosaki.motohiro@jp.fujitsu.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/migrate.c')
-rw-r--r--mm/migrate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/migrate.c b/mm/migrate.c
index e97e513fe898..16052e80aaac 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -272,7 +272,7 @@ static int migrate_page_move_mapping(struct address_space *mapping,
pslot = radix_tree_lookup_slot(&mapping->page_tree,
page_index(page));
- expected_count = 2 + !!page_has_private(page);
+ expected_count = 2 + page_has_private(page);
if (page_count(page) != expected_count ||
(struct page *)radix_tree_deref_slot(pslot) != page) {
spin_unlock_irq(&mapping->tree_lock);