lkml.org 
[lkml]   [2007]   [Feb]   [18]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [RFC PATCH(Experimental) 0/4] Freezer based Cpu-hotplug
On 02/18, Rafael J. Wysocki wrote:
>
> On Sunday, 18 February 2007 00:47, Oleg Nesterov wrote:
> >
> > However, this means that sys_vfork() makes impossible to freeze processes
> > until child exits/execs. Not good.
>
> Yes, but this also is the current behavior.

Yes, yes, I see.

I forgot to say that we have another problem: coredumping.

A thread which does do_coredump() send SIGKILL to ->mm users, and sleeps
on ->mm->core_startup_done. Now it can't be frozen if sub-thread goes to
refrigerator. I think this could be solved easily if we add a check to
refrigerator() as you suggested for ->vfork_donw.

> I think the real solution would be to use an interruptible completion in the
> vfork code. It was discussed some time ago and, IIRC, Ingo had an experimental
> patch that implemented it. Still, for the suspend this really is not an issue
> in practice, so it wasn't merged.

It is not (afaics) so trivial to do rightly, and with this change the parent
will be seen as TASK_INTERRUPTIBLE even without freezer in progress.

A very vague idea: what if parent will do

current->flags |= PF_PLEASE_CONSIDER_ME_AS_FROZEN_BUT_SET_TIF_FREEZE
wait_for_completion(&vfork);
try_to_freeze();

?

> It may be a good time to solve this problem now. :-)

Yes, I think so :)

Oleg.

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2007-02-18 12:35    [W:0.084 / U:30.688 seconds]
©2003-2018 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site