On Wed, 11 Dec 2002 11:49:47 +0800, "Zhang, Sonic" <[EMAIL PROTECTED]> wrote: > I encounter a problem of the keyboard in KDB. The patch version is >kdb-2.5-2.4.19 for i386 with pristine kernel 2.4.19. > > The keyboard cannot work well in KDB. When you press a key, >sometimes there is no character echoed on the screen, and sometimes two >characters echoed on the screen. It is really annoying because you cannot >type continuously. > > This happens on a server with 2 processors. But I can't reproduce it >on my desktop machine. > > Is it a known bug? > > Otherwise, sometimes in KDB , only capital letters can be inputted. > It may be a little hard to re-produce because when you first enter >KDB mode, you may not encounter this situation. After doing some operations >in KDB, e.g. set some breakpoint, suddenly I found every letter I input is >capital letter and I can not switch to small letter mode. > > Is this the same problem?
The scancode handling is in arch/i386/kdb/kdba_io.c::get_kbd_char(). Some keyboard hardware has problems running in polled mode rather than interrupt driven. The keyboard setup was rewritten in 2.5 kernels and the problems seem to have gone away, my current theory is that these are kernel console problems, not kdb. Unfortunately none of the kdb developers have hardware that shows these problems. Without access to the hardware that is failing, we have to rely on users tracking down the problem. Edit get_kbd_char() to print the current cpu, the scan code being read, the various flags and the final result. Start at the comment 'Fetch the scancode' and work down. Use kdb_printf, not printk and set LINES 10000 first. WOrk out what is going wrong and where.
