patch-2.2.15 linux/drivers/char/console.c
Next file: linux/drivers/char/cpia.c
Previous file: linux/drivers/char/c-qcam.c
Back to the patch index
Back to the overall index
- Lines: 56
- Date:
Fri Apr 21 12:45:51 2000
- Orig file:
v2.2.14/drivers/char/console.c
- Orig date:
Tue Jan 4 21:18:45 2000
diff -u --new-file --recursive --exclude-from ../../exclude v2.2.14/drivers/char/console.c linux/drivers/char/console.c
@@ -91,9 +91,6 @@
#include <linux/config.h>
#include <linux/version.h>
#include <linux/tqueue.h>
-#ifdef CONFIG_APM
-#include <linux/apm_bios.h>
-#endif
#include <asm/io.h>
#include <asm/system.h>
@@ -188,6 +185,12 @@
static int scrollback_delta = 0;
/*
+ * Hook so that the power management routines can (un)blank
+ * the console on our behalf.
+ */
+int (*console_blank_hook)(int) = NULL;
+
+/*
* Low-Level Functions
*/
@@ -355,7 +358,7 @@
static void update_attr(int currcons)
{
attr = build_attr(currcons, color, intensity, blink, underline, reverse ^ decscnm);
- video_erase_char = (build_attr(currcons, color, 1, 0, 0, decscnm) << 8) | ' ';
+ video_erase_char = (build_attr(currcons, color, 1, blink, 0, decscnm) << 8) | ' ';
}
/* Note: inverting the screen twice should revert to the original state */
@@ -2539,10 +2542,8 @@
if (i)
set_origin(currcons);
-#ifdef CONFIG_APM
- if (apm_display_blank())
+ if (console_blank_hook && console_blank_hook(1))
return;
-#endif
if (vesa_blank_mode)
sw->con_blank(vc_cons[currcons].d, vesa_blank_mode + 1);
}
@@ -2566,9 +2567,8 @@
currcons = fg_console;
console_blanked = 0;
-#ifdef CONFIG_APM
- apm_display_unblank();
-#endif
+ if (console_blank_hook)
+ console_blank_hook(0);
if (sw->con_blank(vc_cons[currcons].d, 0))
/* Low-level driver cannot restore -> do it ourselves */
update_screen(fg_console);
FUNET's LINUX-ADM group, linux-adm@nic.funet.fi
TCL-scripts by Sam Shen (who was at: slshen@lbl.gov)