UPSTREAM: mm/damon/core: nullify pointer ctx->kdamond with a NULL
Currently a plain integer is being used to nullify the pointer ctx->kdamond. Use NULL instead. Cleans up sparse warning: mm/damon/core.c:317:40: warning: Using plain integer as NULL pointer Link: https://lkml.kernel.org/r/20210925215908.181226-1-colin.king@canonical.com Signed-off-by: Colin Ian King <colin.king@canonical.com> Reviewed-by: SeongJae Park <sj@kernel.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org> (cherry picked from commit 7ec1992b891e59dba0f04e0327980786e8f61b13) Bug: 228223814 Signed-off-by: Hailong Tu <tuhailong@oppo.com> Change-Id: Id5f9786633a785fd45bb6b25f0765671a21d3458
This commit is contained in:

committed by
Hailong Tu

parent
e0fad2fbbe
commit
b1209ff347
@@ -314,7 +314,7 @@ static int __damon_start(struct damon_ctx *ctx)
|
|||||||
nr_running_ctxs);
|
nr_running_ctxs);
|
||||||
if (IS_ERR(ctx->kdamond)) {
|
if (IS_ERR(ctx->kdamond)) {
|
||||||
err = PTR_ERR(ctx->kdamond);
|
err = PTR_ERR(ctx->kdamond);
|
||||||
ctx->kdamond = 0;
|
ctx->kdamond = NULL;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
mutex_unlock(&ctx->kdamond_lock);
|
mutex_unlock(&ctx->kdamond_lock);
|
||||||
|
Reference in New Issue
Block a user