linux-mm.kvack.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] fork-comment-fix: remove ambiguous question mark in CLONE_CHILD_CLEARTID comment
@ 2025-11-25  0:04 Minu Jin
  0 siblings, 0 replies; only message in thread
From: Minu Jin @ 2025-11-25  0:04 UTC (permalink / raw)
  To: mingo, peterz, juri.lelli, vincent.guittot, akpm, david, kees
  Cc: dietmar.eggemann, rostedt, bsegall, mgorman, vschneid,
	lorenzo.stoakes, Liam.Howlett, vbabka, rppt, surenb, mhocko,
	linux-kernel, linux-mm, Minu Jin

The current comment "Clear TID on mm_release()?" ends with a question mark,
implying uncertainty about whether the TID is actually cleared in mm_release().

However, the code flow is deterministic.
When a task exits, mm_release() explicitly checks 'tsk->clear_child_tid' and clears.

Since this behavior is unambiguous,
remove the confusing question mark and rephrase the comment to clearly state that TID is cleared in mm_release().

Signed-off-by: Minu Jin <s9430939@naver.com>
---
 kernel/fork.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/kernel/fork.c b/kernel/fork.c
index 3da0f08615a9..ed46e12c8060 100644
--- a/kernel/fork.c
+++ b/kernel/fork.c
@@ -2031,7 +2031,7 @@ __latent_entropy struct task_struct *copy_process(
 
 	p->set_child_tid = (clone_flags & CLONE_CHILD_SETTID) ? args->child_tid : NULL;
 	/*
-	 * Clear TID on mm_release()?
+	 * TID is cleared in mm_release() when the task exits
 	 */
 	p->clear_child_tid = (clone_flags & CLONE_CHILD_CLEARTID) ? args->child_tid : NULL;
 
-- 
2.43.0



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2025-11-25  0:04 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-11-25  0:04 [PATCH] fork-comment-fix: remove ambiguous question mark in CLONE_CHILD_CLEARTID comment Minu Jin

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox