]> git.hungrycats.org Git - linux/commitdiff
[PATCH] pm: console driver fixes
authorIan Campbell <icampbell@arcom.com>
Sat, 9 Oct 2004 08:03:26 +0000 (01:03 -0700)
committerLinus Torvalds <torvalds@ppc970.osdl.org>
Sat, 9 Oct 2004 08:03:26 +0000 (01:03 -0700)
Fix warnings in kernel/power/console.c by only declaring orig_fgconsole
and orig_kmsg when required by SUSPEND_CONSOLE. Restore kmsg_redirect on
resume.

Signed-off-by: Ian Campbell <icampbell@arcom.com>
Signed-off-by: Andrew Morton <akpm@osdl.org>
Signed-off-by: Linus Torvalds <torvalds@osdl.org>
kernel/power/console.c

index 00b390d7a5ad1fb6640fbfcf48bef5cfa09caa7c..7ff375e7c95f3cf24ab52adf62a688849684e05f 100644 (file)
@@ -11,7 +11,9 @@
 
 static int new_loglevel = 10;
 static int orig_loglevel;
+#ifdef SUSPEND_CONSOLE
 static int orig_fgconsole, orig_kmsg;
+#endif
 
 int pm_prepare_console(void)
 {
@@ -50,6 +52,7 @@ void pm_restore_console(void)
        acquire_console_sem();
        set_console(orig_fgconsole);
        release_console_sem();
+       kmsg_redirect = orig_kmsg;
 #endif
        return;
 }