linux/arch/i386/kernel
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
..
acpi Remove some unused variables 2007-07-03 18:27:53 -07:00
cpu [CPUFREQ] Fix typos in powernow-k8 printk's. 2007-07-13 01:34:10 -04:00
.gitignore
alternative.c Revert "[PATCH] x86: __pa and __pa_symbol address space separation" 2007-05-07 08:44:24 -07:00
apic.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
apm.c Freezer: make kernel threads nonfreezable by default 2007-07-17 10:23:02 -07:00
asm-offsets.c [PATCH] i386: map enough initial memory to create lowmem mappings 2007-05-02 19:27:16 +02:00
bootflag.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
cpuid.c Add suspend-related notifications for CPU hotplug 2007-05-09 12:30:56 -07:00
crash.c move die notifier handling to common code 2007-05-08 11:15:04 -07:00
crash_dump.c
doublefault.c [PATCH] i386: i386 separate hardware-defined TSS from Linux additions 2007-05-02 19:27:13 +02:00
e820.c Make definitions for struct e820entry and struct e820map consistent 2007-07-12 10:55:54 -07:00
early_printk.c
efi.c EFI: warn only for pre-1.00 system tables 2007-05-08 11:15:10 -07:00
efi_stub.S [PATCH] x86: remove unused include from efi_stub.S 2006-09-26 08:48:56 -07:00
entry.S i386: fix regression, endless loop in ptrace singlestep over an int80 2007-07-06 10:23:43 -07:00
head.S x86: initial fixmap support 2007-07-16 09:05:35 -07:00
hpet.c [PATCH] Add suspend/resume for HPET 2007-03-29 10:25:32 -07:00
i386_ksyms.c [PATCH] i386: Convert PDA into the percpu section 2007-05-02 19:27:16 +02:00
i387.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
i8237.c [PATCH] mmc (mainly): add "or later" clause to licence statement. 2006-10-01 00:39:23 -07:00
i8253.c [VOYAGER] clockevents: correct boot cpu is zero assumption 2007-05-01 10:06:42 -05:00
i8259.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
init_task.c [PATCH] nsproxy: move init_nsproxy into kernel/nsproxy.c 2006-10-02 07:57:20 -07:00
io_apic.c Freezer: make kernel threads nonfreezable by default 2007-07-17 10:23:02 -07:00
ioport.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
irq.c [PATCH] i386: Convert PDA into the percpu section 2007-05-02 19:27:16 +02:00
kprobes.c Kprobes: The ON/OFF knob thru debugfs 2007-05-08 11:15:19 -07:00
ldt.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
legacy_serial.c x86, serial: convert legacy COM ports to platform devices 2007-05-08 11:15:23 -07:00
machine_kexec.c [PATCH] i386: Avoid overwriting the current pgd (V4, i386) 2006-09-26 10:52:38 +02:00
Makefile i386: move common parts of smp into their own file 2007-05-15 08:54:00 -07:00
mca.c [PATCH] i386: replace kmalloc+memset with kzalloc 2006-12-07 02:14:19 +01:00
microcode.c microcode: fix section mismatch warning 2007-06-01 08:18:30 -07:00
module.c [PATCH] Generic BUG for i386 2006-12-08 08:28:39 -08:00
mpparse.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
msr.c Add suspend-related notifications for CPU hotplug 2007-05-09 12:30:56 -07:00
nmi.c move die notifier handling to common code 2007-05-08 11:15:04 -07:00
numaq.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
paravirt.c Revert "[PATCH] paravirt: Add startup infrastructure for paravirtualization" 2007-05-10 09:26:53 -07:00
pci-dma.c x86: Disable DAC on VIA bridges 2007-06-20 14:27:25 -07:00
pcspeaker.c [PATCH] x86: Unify pcspeaker platform device code between i386/x86-64 2007-02-13 13:26:26 +01:00
process.c make seccomp zerocost in schedule 2007-07-16 09:05:50 -07:00
ptrace.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
quirks.c Clean up E7520/7320/7525 quirk printk. 2007-07-07 13:53:13 -07:00
reboot.c Work around Dell E520 BIOS reboot bug 2007-06-01 08:18:28 -07:00
reboot_fixups.c GEODE: reboot fixup for geode machines with CS5536 boards 2007-07-06 11:45:11 -07:00
relocate_kernel.S [PATCH] i386: Avoid overwriting the current pgd (V4, i386) 2006-09-26 10:52:38 +02:00
scx200.c Remove obsolete #include <linux/config.h> 2006-06-30 19:25:36 +02:00
setup.c Make struct boot_params a real structure, and remove obsolete fields 2007-07-12 10:55:54 -07:00
sigframe.h
signal.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
smp.c i386: don't check_pgt_cache in flush_tlb_mm 2007-05-17 05:23:05 -07:00
smpboot.c sched: zap the migration init / cache-hot balancing code 2007-07-09 18:51:57 +02:00
smpcommon.c i386: move common parts of smp into their own file 2007-05-15 08:54:00 -07:00
srat.c ACPI: build fix for IBM x440 - CONFIG_X86_SUMMIT 2007-02-02 21:47:33 -05:00
summit.c
sys_i386.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
syscall_table.S signal/timer/event: eventfd wire up x86 arches 2007-05-11 08:29:37 -07:00
sysenter.c [PATCH] i386: In compat mode, the return value here was uninitialized. 2007-05-02 19:27:16 +02:00
time.c [PATCH] i386: pit_latch_buggy has no effect 2007-05-02 19:27:05 +02:00
topology.c Replace remaining references to "driverfs" with "sysfs". 2007-02-17 19:13:42 +01:00
trampoline.S [PATCH] i386: Rename boot_gdt_table to boot_gdt 2007-05-02 19:27:10 +02:00
traps.c generic bug: use show_regs() instead of dump_stack() 2007-07-16 09:05:51 -07:00
tsc.c sched: x86, track TSC-unstable events 2007-07-09 18:51:59 +02:00
tsc_sync.c [PATCH] x86: rewrite SMP TSC sync code 2007-02-16 08:13:57 -08:00
vm86.c header cleaning: don't include smp_lock.h when not used 2007-05-08 11:15:07 -07:00
vmi.c Fix vmi.c compilation 2007-06-01 08:18:27 -07:00
vmiclock.c [PATCH] i386: Convert VMI timer to use clock events 2007-05-02 19:27:16 +02:00
vmlinux.lds.S all-archs: consolidate .data section definition in asm-generic 2007-05-19 09:11:57 +02:00
vsyscall-int80.S
vsyscall-note.S
vsyscall-sigreturn.S [PATCH] Mark unwind info for signal trampolines in vDSOs 2006-03-31 12:18:52 -08:00
vsyscall-sysenter.S [PATCH] vdso: randomize the i386 vDSO by moving it into a vma 2006-06-27 17:32:38 -07:00
vsyscall.lds.S [PATCH] i386: VDSO_PRELINK warning fix 2007-05-02 19:27:09 +02:00
vsyscall.S