NetBSD Problem Report #31906

From www@netbsd.org  Mon Oct 24 11:19:04 2005
Return-Path: <www@netbsd.org>
Received: by narn.netbsd.org (Postfix, from userid 31301)
	id E5E2663B9F9; Mon, 24 Oct 2005 11:19:04 +0000 (UTC)
Message-Id: <20051024111904.E5E2663B9F9@narn.netbsd.org>
Date: Mon, 24 Oct 2005 11:19:04 +0000 (UTC)
From: ghen@telenet.be
Reply-To: ghen@telenet.be
To: gnats-bugs@netbsd.org
Subject: ral(4) panics kernel when unplugging ASUS card from Apple USB keyboard
X-Send-Pr-Version: www-1.0

>Number:         31906
>Category:       kern
>Synopsis:       ral(4) panics kernel when unplugging ASUS card from Apple USB keyboard
>Confidential:   no
>Severity:       critical
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Mon Oct 24 11:20:00 +0000 2005
>Last-Modified:  Mon Jan 16 20:30:01 +0000 2006
>Originator:     Geert Hendrickx
>Release:        current as of 20051023
>Organization:
>Environment:
NetBSD mantis 3.99.10 NetBSD 3.99.10 (MANTIS) #4: Sun Oct 23 16:03:26 CEST 2005  geert@mantis:/cvs/obj/sys/arch/i386/compile/MANTIS i386
>Description:
I'm using the ral(4) driver with an ASUS WL-167G usb wireless card on my HP     
laptop running a 3.99.10 kernel.  It works fine when I plug it directly         
into one of the USB ports of my laptop, but not when I plug it into an USB      
port on my Apple USB keyboard (which also acts as an USB hub with two extra     
ports).  I get the following when plugging it in:                               
(output is not copy/pasted but manually copied so may not be exact)             

> ral0 at uhub5 port 3                                                          
> ral0: ASUS 802.11g WLAN Drive, rev 2.00/0.01, addr 4                          
> ral0: could not set configuration no                                          

And when unplugging:                                                            

> ral0: at uhub5 port 3 (addr 4) disconnected                                   
> uvm_fault (0x08ce9e0, 0, 0, 1) -> -0xe                                        
> kernel: supervisor trap page fault, code=0                                    
> stopped in pid 5.1 (usb1) at netbsd: ieee80211_remove_vop + 0x31: movl 0      
> (%eax),%ebx                                                                   
> db>                                                                           

The kernel enters the debugger but everything, incl keyboard, is completely     
frozen, hard reboot required...  However I can use other USB devices (such      
as mouse, flash memory) via that keyboard just fine.         
>How-To-Repeat:
Build a -current kernel with "ral* at uhub? port ?", plug ASUS ral(4) usb card 
into Apple usb keyboard and unplug again.  It crashes every time.  
>Fix:

>Release-Note:

>Audit-Trail:

From: Geert Hendrickx <ghen@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/31906 (ral(4) panics kernel when unplugging ASUS card from Apple USB keyboard)
Date: Mon, 16 Jan 2006 21:23:01 +0100

 I can reproduce this crash with other (non-keyboard) USB hubs as well.  As
 before, other USB devices (mice, storage, ...) work fine with this hub.
 Below is a transcript.  

 When plugged into an USB port directly, the ASUS card works fine: 
 > ral0: ASUS 802.11g WLAN Drive, rev 2.00/0.01, addr 2
 > ral0: MAC/BBP RT2570 (rev 0x03), RF RT2526, address 00:11:d8:c1:ea:48
 > ral0: 11b rates: 1Mbps 2Mbps 5.5Mbps 11Mbps
 > ral0: 11g rates: 1Mbps 2Mbps 5.5Mbps 11Mbps 6Mbps 9Mbps 12Mbps 18Mbps 24Mbps 36Mbps 48Mbps 54Mbps

 I can configure and use the ral0 network device without problems: 
 > ral0: link state changed to UP

 No problem disconnecting the card either: 
 > ral0: link state changed to DOWN
 > ral0: at uhub4 port 5 (addr 2) disconnected
 > ral0 detached

 Now with the USB hub: 
 > uhub5 at uhub2 port 1
 > uhub5: Texas Instruments TUSB2046 hub, class 9/0, rev 1.10/1.25, addr 2
 > uhub5: 4 ports with 4 removable, bus powered

 Plug card into USB hub: 
 > ral0 at uhub5 port 3
 > ral0: ASUS 802.11g WLAN Drive, rev 2.00/0.01, addr 3
 > ral0: could not set configuration no

 Card is not configured, ifconfig -a doesn't show ral0.  

 When disconnecting, the kernel crashes: 
 > ral0: at uhub5 port 3 (addr 3) disconnected
 > uvm_fault (0xc062bf60, 0, 0, 1) -> 0xe
 > kernel: supervisor trap page fault, code=0
 > Stopped in pid 6.1 (usb2) at netbsd:ieee80211_remove_vap+0x31: movl 0 (%eax),%ebx
 > db> 

 I can compile a debugging kernel and provide a backtrace too, if anyone is
 interested (keyboard still works).  

 	Geert

From: Geert Hendrickx <ghen@NetBSD.org>
To: gnats-bugs@NetBSD.org
Cc: 
Subject: Re: kern/31906 (ral(4) panics kernel when unplugging ASUS card from Apple USB keyboard)
Date: Mon, 16 Jan 2006 21:27:22 +0100

 I forgot to mention: this is NetBSD/i386 3.99.15 as of 14/01/2006.  

 	Geert

>Unformatted:

NetBSD Home
NetBSD PR Database Search

(Contact us) $NetBSD: query-full-pr,v 1.39 2013/11/01 18:47:49 spz Exp $
$NetBSD: gnats_config.sh,v 1.8 2006/05/07 09:23:38 tsutsui Exp $
Copyright © 1994-2007 The NetBSD Foundation, Inc. ALL RIGHTS RESERVED.