Subject: kern/7086: Unplugging USB devices can cause system crash
To: None <gnats-bugs@gnats.netbsd.org>
From: Matthias Scheler <tron@lyssa.owl.de>
List: netbsd-bugs
Date: 03/05/1999 18:49:55
>Number:         7086
>Category:       kern
>Synopsis:       Unplugging USB devices can cause system crash
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    kern-bug-people (Kernel Bug People)
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Mar  5 10:05:00 1999
>Last-Modified:
>Originator:     Matthias Scheler
>Organization:
Matthias Scheler                                http://home.owl.de/~tron/
>Release:        19990228
>Environment:
System: NetBSD lyssa.owl.de 1.3J NetBSD 1.3J (LYSSA) #0: Sun Feb 28 19:41:44 MET 1999 tron@lyssa.owl.de:/src/sys/compile/LYSSA i386


>Description:
A week ago I connected my EIZO F67 monitor's USB hub to the onboard USB
controller of my Intel BX chipset based PC motherboard. The HUB and the
builtin device for the monitor are properly recognized:

uhci0: interrupting at irq 15
uhci0: USB version 1.0
usb0 at uhci0
uhub0 at usb0
uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1
uhub0: 2 ports with 2 removable, self powered
uhub1 at uhub0 port 2
uhub1: EIZO hub, class 9/0, rev 1.00/1.01, addr 2
uhub1: 5 ports with 5 removable, self powered
ugen0 at uhub1 port 1
ugen0: EIZO monitor, rev 1.00/1.01, addr 3

I don't know if that matters but the USB controller shares interrupt 15
with the second SCSI channel of an Adaptec 3940UW. The "usbd" is
enabled in "/etc/rc.conf".

I turned of the monitor the USB devices got removed:

uhub0: port error, restarting port 2
uhub1: at uhub0 port 2 (addr 2) disconnected
ugen0: at uhub1 port 1 (addr 3) disconnected

[I wonder if part of the problem is that the hub gets removed after the
 device.]

After if I turned it on again the hub got a new ordinal number but the
monitor isn't recognized at all:

uhub2 at uhub0 port 2
uhub2: EIZO hub, class 9/0, rev 1.00/1.01, addr 2
uhub0: port error, restarting port 2

And once again:

uhub2: at uhub0 port 2 (addr 2) disconnected
uhub3 at uhub0 port 2
uhub3: EIZO hub, class 9/0, rev 1.00/1.01, addr 2
uhub3: 5 ports with 5 removable, self powered
ugen1 at uhub3 port 1
ugen1: EIZO monitor, rev 1.00/1.01, addr 3

After the next try the system rebooted immediately.

>How-To-Repeat:
Connect an EIZO Fx7 to an onboard USB controller on an Intel BX board and
turn it off and on a few times.

>Fix:
Sorry, I don't know.

>Audit-Trail:
>Unformatted: