Messages in this thread Patch in this message | | | From | Bernhard Walle <> | Subject | [PATCH 3/5] Use vt_get_kmsg_redirect() and vt_set_kmsg_redirect() | Date | Sat, 10 Oct 2009 22:51:08 +0200 |
| |
Although the only code file where kmsg_redirect is used (power/console.c) is already protected by CONFIG_VT_CONSOLE, we use the new interface here to be able to make kmsg_redirect static.
Signed-off-by: Bernhard Walle <bernhard@bwalle.de> --- kernel/power/console.c | 8 ++++---- 1 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/kernel/power/console.c b/kernel/power/console.c index 5187136..df959d7 100644 --- a/kernel/power/console.c +++ b/kernel/power/console.c @@ -6,7 +6,7 @@ #include <linux/vt_kern.h> #include <linux/kbd_kern.h> -#include <linux/console.h> +#include <linux/vt.h> #include <linux/module.h> #include "power.h" @@ -21,8 +21,8 @@ int pm_prepare_console(void) if (orig_fgconsole < 0) return 1; - orig_kmsg = kmsg_redirect; - kmsg_redirect = SUSPEND_CONSOLE; + orig_kmsg = vt_get_kmsg_redirect(); + vt_set_kmsg_redirect(SUSPEND_CONSOLE); return 0; } @@ -30,7 +30,7 @@ void pm_restore_console(void) { if (orig_fgconsole >= 0) { vt_move_to_console(orig_fgconsole, 0); - kmsg_redirect = orig_kmsg; + vt_set_kmsg_redirect(orig_kmsg); } } #endif -- 1.6.3.3
| |