diff options
Diffstat (limited to 'drivers/char/vt.c')
-rw-r--r-- | drivers/char/vt.c | 25 |
1 files changed, 25 insertions, 0 deletions
diff --git a/drivers/char/vt.c b/drivers/char/vt.c index e50d98cd6..4fe33cddb 100644 --- a/drivers/char/vt.c +++ b/drivers/char/vt.c @@ -27,6 +27,10 @@ #include <asm/io.h> #include <asm/uaccess.h> +#if defined(__mc68000__) || defined(CONFIG_APUS) +#include <asm/machdep.h> +#endif + #include <linux/kbd_kern.h> #include <linux/vt_kern.h> #include <linux/kbd_diacr.h> @@ -493,6 +497,27 @@ int vt_ioctl(struct tty_struct *tty, struct file * file, (cmd == KDENABIO)) ? -ENXIO : 0; #endif +#if defined(__mc68000__) || defined(CONFIG_APUS) + /* Linux/m68k interface for setting the keyboard delay/repeat rate */ + + case KDKBDREP: + { + struct kbd_repeat kbrep; + + if (!mach_kbdrate) return( -EINVAL ); + if (!suser()) return( -EPERM ); + + if (copy_from_user(&kbrep, (void *)arg, + sizeof(struct kbd_repeat))) + return -EFAULT; + if ((i = mach_kbdrate( &kbrep ))) return( i ); + if (copy_to_user((void *)arg, &kbrep, + sizeof(struct kbd_repeat))) + return -EFAULT; + return 0; + } +#endif + case KDSETMODE: /* * currently, setting the mode from KD_TEXT to KD_GRAPHICS |