--- a/mm/damon/core.c~mm-damon-core-nullify-pointer-ctx-kdamond-with-a-null +++ a/mm/damon/core.c @@ -314,7 +314,7 @@ static int __damon_start(struct damon_ct nr_running_ctxs); if (IS_ERR(ctx->kdamond)) { err = PTR_ERR(ctx->kdamond); - ctx->kdamond = 0; + ctx->kdamond = NULL; } } mutex_unlock(&ctx->kdamond_lock);