lkml.org 
[lkml]   [1999]   [Dec]   [3]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: Toshiba Satellite 2595XDVD

    On Thu, 2 December 1999, Pavel Machek wrote:
    > Hi!
    >
    > > I am not sure to whom should I address this, it's about a buggy
    > > keyboard controller (I guess) found on <subj> laptops that has a
    > > peculiar behavior with some key sequences. Specifically, when you
    > > press a shift (ctrl, alt, shift) and a key - (mostly when you play a
    > > lot with shifts, like in emacs :-)) - sometimes the controller ignores
    > > the repeat delay and repeats the key, sending very close (tens of
    > > miliseconds) key_down interrups (kbd MAKEs).
    >
    > It would be nice to warn if such condition is detected. Silently
    > correcting problems is bad thing (tm). So patch currently looks like
    > this. (Also owners of good keyboards with short autorepeats will at
    > least know what code to disable and to who complain :-)))))
    Well, of course I had a printk in my first version of this, but, after
    a few days I deleted it... We can get it back, if you like. Also,
    the 200ms delay I am using here is less than the smalest delay
    possible (at least on PC kbds that I am aware of) that is 250 ms, and
    this is applicable only to the _second_ identical scancode in a row,
    therefore it only affects kbd delay, not kbd rate - so no probl with
    short autorepeats.

    > /*
    > * Fix for Toshiba Satellites. Under some
    > * circumstances, its keyboards behave like ignoring the
    > * kbd repeat delay. This happens in conjunction with shift
    > * keys (ctrl, alt, shift) and leads to undesirable repeat
    > * of a key even if pressed briefly. Fix it by ignoring any
    > * subsequent occurence of the second identical scancode for
    > * 200 ms. IMO, this doesn't break anything on a good keyboard.
    > *
    > * Thanx to Andrei Pitis <pink@roedu.net>.
    > */
    > static int prev_scancode = 0;
    > static int stop_jiffies = 0;
    >
    > /* new scancode, trigger delay */
    > if (scancode != prev_scancode)
    > stop_jiffies = jiffies;
    >
    > /* same scancode, accept only after the delay */
    > else if (jiffies - stop_jiffies >= 10)
    > stop_jiffies = 0;
    >
    > /* glitch! bail out... */
    > else {
    > printk( "Keyboard glitch detected, ignoring keypress\n" );
    > return;
    > }
    > prev_scancode = scancode;
    >
    > --
    > I'm really pavel@ucw.cz. Look at http://195.113.31.123/~pavel. Pavel
    > Hi! I'm a .signature virus! Copy me into your ~/.signature, please!

    -
    To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
    the body of a message to majordomo@vger.rutgers.edu
    Please read the FAQ at http://www.tux.org/lkml/

    \
     
     \ /
      Last update: 2005-03-22 13:55    [W:0.029 / U:119.152 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site