linux-hardened/drivers/mfd
Rafael J. Wysocki 8314418629 Freezer: make kernel threads nonfreezable by default
Currently, the freezer treats all tasks as freezable, except for the kernel
threads that explicitly set the PF_NOFREEZE flag for themselves.  This
approach is problematic, since it requires every kernel thread to either
set PF_NOFREEZE explicitly, or call try_to_freeze(), even if it doesn't
care for the freezing of tasks at all.

It seems better to only require the kernel threads that want to or need to
be frozen to use some freezer-related code and to remove any
freezer-related code from the other (nonfreezable) kernel threads, which is
done in this patch.

The patch causes all kernel threads to be nonfreezable by default (ie.  to
have PF_NOFREEZE set by default) and introduces the set_freezable()
function that should be called by the freezable kernel threads in order to
unset PF_NOFREEZE.  It also makes all of the currently freezable kernel
threads call set_freezable(), so it shouldn't cause any (intentional)
change of behaviour to appear.  Additionally, it updates documentation to
describe the freezing of tasks more accurately.

[akpm@linux-foundation.org: build fixes]
Signed-off-by: Rafael J. Wysocki <rjw@sisk.pl>
Acked-by: Nigel Cunningham <nigel@nigel.suspend2.net>
Cc: Pavel Machek <pavel@ucw.cz>
Cc: Oleg Nesterov <oleg@tv-sign.ru>
Cc: Gautham R Shenoy <ego@in.ibm.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2007-07-17 10:23:02 -07:00
..
Kconfig [S390] Kconfig: menus with depends on HAS_IOMEM. 2007-05-10 15:46:07 +02:00
Makefile [PATCH] mfd: SM501 core driver 2007-02-20 17:10:14 -08:00
mcp-core.c [PATCH] Add MCP bus_type probe and remove methods 2006-01-13 11:26:08 -08:00
mcp-sa11x0.c [DRIVER MODEL] Convert platform drivers to use struct platform_driver 2005-11-09 22:32:44 +00:00
mcp.h [MFD] Add multimedia communication port core support 2005-08-18 10:06:59 +01:00
sm501.c SM501: Check SM501 ID register on initialisation 2007-06-24 08:59:11 -07:00
ucb1x00-assabet.c [MFD] Add code UCB1200/UCB1300 assabet platform support 2005-09-11 10:27:23 +01:00
ucb1x00-core.c IRQ: Maintain regs pointer globally rather than passing to IRQ handlers 2006-10-05 15:10:12 +01:00
ucb1x00-ts.c Freezer: make kernel threads nonfreezable by default 2007-07-17 10:23:02 -07:00
ucb1x00.h [ARM] 3727/1: fix ucb initialization on collie 2006-07-11 22:54:15 +01:00