6.1-PRE boot locks up, using USB keyboard
Sam Leffler
sam at errno.com
Wed Mar 15 18:53:40 UTC 2006
Rick C. Petty wrote:
> On Wed, Mar 15, 2006 at 12:27:08PM -0500, John Baldwin wrote:
>> On Wednesday 15 March 2006 12:11, Rick C. Petty wrote:
>>> My BIOS (Asus A8N-E rev 1010) has no option for disabling USB keyboard
>>> support, but I can either disable the USB controller or disable the USB
>>> legacy support. I doubt either of these is desirable. Fortunately, I
>>> discovered the problem..
>> The "legacy support" option is the one that makes a USB keyboard look like
>> a PS/2 keyboard.
>
> If I disable legacy support, the USB keyboard is useless until the kernel
> comes up multi-user and usbd is started, as I expected. Other than that,
> everything behaves identically.
>
>>> Whenever ukbd is loaded by /boot/loader and that
>>> device already exists in the kernel, the boot locks up after:
>>>
>>> atkbdc0: <Keyboard controller (i8042)> at port 0x60,0x64 on isa0
>>>
>>> when using a USB keyboard. I would think this is a bug. It is 100%
>>> repeatable for me. If I comment out the line in /boot/loader.conf, the
>>> system boots nicely.
>> Ok. There are several edge cases that can blow up if you kldload a module
>> or load a module from the loader that is already present in the kernel.
>
> I would think the loader or the kernel should be smart enough not to
> break when loading an already-loaded module. Is there a workaround?
> If not, all kernels must be compiled with ukbd (if they are to support
> USB keyboards in single-user mode, e.g.). There should also be a
> warning "BEWARE: Do not set ukbd_load in your loader.conf" :-P
>
> Seriously, though, the kernel should not break when loading an unloaded
> module. I first noticed this whenever I had umass(4) in the kernel and
> it wouldn't detect my USB memory stick but then kldload'd it, saw "File
> exists", but then it would be detected. I remember removing umass from
> my config and it behaving quite differently. I never had time to pursue
> that problem.
I've had several loader/kld bugs on my todo list for a while. For
example loading a module with undefined references from the loader will
cause the kernel to panic. Feel free to dig in and provide patches...
Sam
More information about the freebsd-hackers
mailing list