summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYang Li <yang.lee@linux.alibaba.com>2022-11-16 09:23:45 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2024-11-08 16:26:47 +0100
commitde0a1554a45428ad0e10340d642608ce62d61c74 (patch)
tree7a7c196d1df34e7acde08c77d35772205875b59c
parent2a4b092d91ac8a51f23845c6dae684a757571891 (diff)
downloadlinux-de0a1554a45428ad0e10340d642608ce62d61c74.tar.gz
linux-de0a1554a45428ad0e10340d642608ce62d61c74.tar.bz2
linux-de0a1554a45428ad0e10340d642608ce62d61c74.zip
mm/migrate.c: stop using 0 as NULL pointer
[ Upstream commit 4c74b65f478dc9353780a6be17fc82f1b06cea80 ] mm/migrate.c:1198:24: warning: Using plain integer as NULL pointer Link: https://bugzilla.openanolis.cn/show_bug.cgi?id=3080 Link: https://lkml.kernel.org/r/20221116012345.84870-1-yang.lee@linux.alibaba.com Signed-off-by: Yang Li <yang.lee@linux.alibaba.com> Reported-by: Abaci Robot <abaci@linux.alibaba.com> Reviewed-by: David Hildenbrand <david@redhat.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Stable-dep-of: 35e41024c4c2 ("vmscan,migrate: fix page count imbalance on node stats when demoting pages") Signed-off-by: Sasha Levin <sashal@kernel.org>
-rw-r--r--mm/migrate.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/mm/migrate.c b/mm/migrate.c
index 562f819dc618..81444abf54db 100644
--- a/mm/migrate.c
+++ b/mm/migrate.c
@@ -1192,7 +1192,7 @@ static int unmap_and_move(new_page_t get_new_page,
return -ENOMEM;
dst = page_folio(newpage);
- dst->private = 0;
+ dst->private = NULL;
rc = __unmap_and_move(src, dst, force, mode);
if (rc == MIGRATEPAGE_SUCCESS)
set_page_owner_migrate_reason(&dst->page, reason);