2003-03-27 10:19:45

by Samuel Thibault

[permalink] [raw]
Subject: Braille devices can't scrollback console

Hello,

There is no way for a braille device driven by brltty (userland root-owned
daemon) to scrollback the virtual console, the only way is to use the pc
keyboard. A very simple TIOCLINUX ioctl meets this need (tested):

diff -urN linux/drivers/char/console.c linux-scrollioctl/drivers/char/console.c
--- linux/drivers/char/console.c 2003-03-27 10:55:43.000000000 +0100
+++ linux-scrollioctl/drivers/char/console.c 2003-03-27 11:04:31.000000000 +0100
@@ -2262,6 +2262,17 @@
case 12: /* get fg_console */
ret = fg_console;
break;
+ case 13: /* scroll console */
+ {
+ int lines;
+ if (get_user(lines, (char *)arg+1)) {
+ ret = -EFAULT;
+ } else {
+ scrollfront(lines);
+ ret = 0;
+ }
+ }
+ break;
default:
ret = -EINVAL;
break;

Regards,
Samuel Thibault