Subject: Re: kern/28582
To: None <kern-bug-people@netbsd.org, gnats-admin@netbsd.org,>
From: Chris Tribo <ctribo@dtcc.edu>
List: netbsd-bugs
Date: 05/20/2005 06:03:02
The following reply was made to PR kern/28582; it has been noted by GNATS.

From: Chris Tribo <ctribo@dtcc.edu>
To: gnats-bugs@netbsd.org
Cc: 
Subject: Re: kern/28582
Date: Fri, 20 May 2005 02:02:04 -0400 (EDT)

 The console is not attaching to the USB keyboard unless you remove all
 pckbd and pckbc entries from the kernel config file.
 PCKBC_CNATTACH_MAY_FAIL and PCKBD_SELF_TEST don't help.
 
 The problem at hand is that we start off talking to the keyboard through
 USB Legacy emulation in the BIOS which presents a PS/2 keyboard interface
 to the OS until the USB controller is reset; at which point USB legacy
 emulation ceases to work. Maybe there is a way to:
 
 - ask the KB for a serial number or unique capability string via PS/2
 - reset the USB chip(s)
 - enumerate the USB buses/devices
 - check if the USB keyboard info matches what was retrieved from the PS/2
 port. If it matches, call console attach to the USB keyboard and set a
 flag that indicates that the ukbd is to always attach as console keyboard,
 to cover the event that it gets unplugged or disconnected.
 
 There's probably much simpler solutions, possibly a way to detect the
 status of legacy emulation or just some simple code changes to what we
 have. Lennart said he would take a look when he has time.