]> git.baikalelectronics.ru Git - kernel.git/commit
[PATCH] Threads shouldn't inherit PF_NOFREEZE
authorAlan Stern <stern@rowland.harvard.edu>
Thu, 20 Oct 2005 04:23:51 +0000 (21:23 -0700)
committerLinus Torvalds <torvalds@g5.osdl.org>
Thu, 20 Oct 2005 06:04:31 +0000 (23:04 -0700)
commita7ac6471b5e128c5e63bbac1428e805f5e9ee32e
tree0712622c596cd3ca93234e8eca661240b5fa042b
parented84a05d8f2ea9a60641ef81f3372fc6d28eecef
[PATCH] Threads shouldn't inherit PF_NOFREEZE

The PF_NOFREEZE process flag should not be inherited when a thread is
forked.  This patch (as585) removes the flag from the child.

This problem is starting to show up more and more as drivers turn to the
kthread API instead of using kernel_thread().  As a result, their kernel
threads are now children of the kthread worker instead of modprobe, and
they inherit the PF_NOFREEZE flag.  This can cause problems during system
suspend; the kernel threads are not getting frozen as they ought to be.

Signed-off-by: Alan Stern <stern@rowland.harvard.edu>
Acked-by: Pavel Machek <pavel@ucw.cz>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
kernel/fork.c