diff options
author | Miaohe Lin <linmiaohe@huawei.com> | 2022-04-28 23:16:17 -0700 |
---|---|---|
committer | akpm <akpm@linux-foundation.org> | 2022-04-28 23:16:17 -0700 |
commit | 024c61eaff17f6a8c73cb8b25137251f0c3ef039 (patch) | |
tree | 4aa7d2e2222c826e7bf58b6621bad09ef180364d /mm/compaction.c | |
parent | 94bfe85bde18a99612bb5d0ce348643c2d352836 (diff) | |
download | lwn-024c61eaff17f6a8c73cb8b25137251f0c3ef039.tar.gz lwn-024c61eaff17f6a8c73cb8b25137251f0c3ef039.zip |
mm: compaction: remove unneeded return value of kcompactd_run
Patch series "A few cleanup and fixup patches for compaction".
This series contains a few patches to clean up some obsolete comment,
remove unneeded return value and so on. Also we fix the possible NULL
pointer dereference. More details can be found in the respective
changelogs.
This patch (of 12):
The return value of kcompactd_run() is unused now. Clean it up.
Link: https://lkml.kernel.org/r/20220418141253.24298-1-linmiaohe@huawei.com
Link: https://lkml.kernel.org/r/20220418141253.24298-2-linmiaohe@huawei.com
Signed-off-by: Miaohe Lin <linmiaohe@huawei.com>
Cc; Mel Gorman <mgorman@techsingularity.net>
Cc: David Hildenbrand <david@redhat.com>
Cc: Vlastimil Babka <vbabka@suse.cz>
Cc: Pintu Kumar <pintu@codeaurora.org>
Cc: Charan Teja Kalla <charante@codeaurora.org>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Diffstat (limited to 'mm/compaction.c')
-rw-r--r-- | mm/compaction.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/mm/compaction.c b/mm/compaction.c index baf654b5e073..2e838992b324 100644 --- a/mm/compaction.c +++ b/mm/compaction.c @@ -3016,21 +3016,18 @@ static int kcompactd(void *p) * This kcompactd start function will be called by init and node-hot-add. * On node-hot-add, kcompactd will moved to proper cpus if cpus are hot-added. */ -int kcompactd_run(int nid) +void kcompactd_run(int nid) { pg_data_t *pgdat = NODE_DATA(nid); - int ret = 0; if (pgdat->kcompactd) - return 0; + return; pgdat->kcompactd = kthread_run(kcompactd, pgdat, "kcompactd%d", nid); if (IS_ERR(pgdat->kcompactd)) { pr_err("Failed to start kcompactd on node %d\n", nid); - ret = PTR_ERR(pgdat->kcompactd); pgdat->kcompactd = NULL; } - return ret; } /* |