linux/kernel/power
Bernhard Walle 5ada918b82 vt: introduce and use vt_kmsg_redirect() function
The kernel offers with TIOCL_GETKMSGREDIRECT ioctl() the possibility to
redirect the kernel messages to a specific console.

However, since it's not possible to switch to the kernel message console
after a panic(), it would be nice if the kernel would print the panic
message on the current console.

This patch series adds a new interface to access the global kmsg_redirect
variable by a function to be able to use it in code where
CONFIG_VT_CONSOLE is not set (kernel/panic.c).

This patch:

Instead of using and exporting a global value kmsg_redirect, introduce a
function vt_kmsg_redirect() that both can set and return the console where
messages are printed.

Change all users of kmsg_redirect (the VT code itself and kernel/power.c)
to the new interface.

The main advantage is that vt_kmsg_redirect() can also be used when
CONFIG_VT_CONSOLE is not set.

Signed-off-by: Bernhard Walle <bernhard@bwalle.de>
Cc: Alan Cox <alan@lxorguk.ukuu.org.uk>
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
2009-12-15 08:53:28 -08:00
..
Kconfig PM: Introduce core framework for run-time PM of I/O devices (rev. 17) 2009-08-23 00:04:44 +02:00
Makefile PM / Hibernate: Shift remaining code from swsusp.c to hibernate.c 2009-12-06 16:16:07 +01:00
console.c vt: introduce and use vt_kmsg_redirect() function 2009-12-15 08:53:28 -08:00
hibernate.c PM / Hibernate: Shift remaining code from swsusp.c to hibernate.c 2009-12-06 16:16:07 +01:00
hibernate_nvs.c PM/Hibernate: Move NVS routines into a seperate file (v2). 2009-06-12 21:32:33 +02:00
main.c PM / Runtime: Export the PM runtime workqueue 2009-12-06 16:17:56 +01:00
power.h PM/Hibernate: Do not release preallocated memory unnecessarily (rev. 2) 2009-09-14 20:26:58 +02:00
poweroff.c trivial: kernel/power/poweroff.c: whitespace fix 2009-06-12 18:01:46 +02:00
process.c PM / freezer: Don't get over-anxious while waiting 2009-10-28 22:53:09 +01:00
snapshot.c mm: don't use alloc_bootmem_low() where not strictly needed 2009-09-22 07:17:38 -07:00
suspend.c PM: Separate suspend to RAM functionality from core 2009-06-12 21:32:33 +02:00
suspend_test.c PM: Make warning in suspend_test_finish() less likely to happen 2009-10-22 08:23:45 +09:00
swap.c PM / Hibernate: Swap, use KERN_CONT 2009-12-06 16:16:24 +01:00
swsusp.c PM / Hibernate: Shift remaining code from swsusp.c to hibernate.c 2009-12-06 16:16:07 +01:00
user.c headers: smp_lock.h redux 2009-07-12 12:22:34 -07:00