[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-Id: <ce1279df18d2c163998c403e0b5ec6d3f6f90f7a.1629447552.git.baolin.wang@linux.alibaba.com>
Date: Sat, 21 Aug 2021 15:54:59 +0800
From: Baolin Wang <baolin.wang@...ux.alibaba.com>
To: akpm@...ux-foundation.org
Cc: shy828301@...il.com, willy@...radead.org,
baolin.wang@...ux.alibaba.com, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: [PATCH v3 4/4] mm: migrate: Change to use bool type for 'page_was_mapped'
Change to use bool type for 'page_was_mapped' variable making it
more readable.
Signed-off-by: Baolin Wang <baolin.wang@...ux.alibaba.com>
Reviewed-by: Yang Shi <shy828301@...il.com>
---
mm/migrate.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mm/migrate.c b/mm/migrate.c
index a9800fa..04a76fc 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -953,7 +953,7 @@ static int __unmap_and_move(struct page *page, struct page *newpage,
int force, enum migrate_mode mode)
{
int rc = -EAGAIN;
- int page_was_mapped = 0;
+ bool page_was_mapped = false;
struct anon_vma *anon_vma = NULL;
bool is_lru = !__PageMovable(page);
@@ -1056,7 +1056,7 @@ static int __unmap_and_move(struct page *page, struct page *newpage,
VM_BUG_ON_PAGE(PageAnon(page) && !PageKsm(page) && !anon_vma,
page);
try_to_migrate(page, 0);
- page_was_mapped = 1;
+ page_was_mapped = true;
}
if (!page_mapped(page))
--
1.8.3.1
Powered by blists - more mailing lists