lkml.org 
[lkml]   [2011]   [Aug]   [25]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 06/16] freezer: make exiting tasks properly unfreezable
On 08/25, Tejun Heo wrote:
>
> Yeah, what 'freeze' should do is a bit vague on the edges, I think.
> The freezer can't really halt the whole system operation including
> IOs. Tasks aren't the only source which can kick those off. There
> are other asynchronous sources,

Of course.

But still I can't understand why it is better to consider the exiting
task as "frozen" from the very beginning, right after PTRACE_EVENT_EXIT.
do_exit() does a lot of misc things, and this patch simply makes it
"invisible" to the freezer. This looks "unsafe" even if this is fine
for suspend/etc.

To me, try_to_freeze_tasks() should succed when all threads either
sleep in refrigerator(), or ->state = TASK_DEAD (the final schedule()
was called). Until then try_to_freeze_tasks() should retry.

But since we can't see the threads after exit_notify (in general),
the current ->exit_state check looks reasonable.

But again, again, I won't argue.

> Rafael, can you please enlighten
> us on the subject?

Please ;)

> Another freezer user is the cgroup,

Yes. And I don't understand this case too. I mean, the fact we ignore
the exiting tasks.

Oleg.



\
 
 \ /
  Last update: 2011-08-25 19:01    [W:0.109 / U:0.312 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site