Subject: kern/31381: Detaching an Adaptec ADP-1480 cardbus card panics netbsd-3
To: None <,,>
From: Hauke Fath <hauke@Espresso.Rhein-Neckar.DE>
List: netbsd-bugs
Date: 09/23/2005 19:51:00
>Number:         31381
>Category:       kern
>Synopsis:       Detaching an Adaptec ADP-1480 cardbus card panics netbsd-3
>Confidential:   no
>Severity:       critical
>Priority:       medium
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Fri Sep 23 19:51:00 +0000 2005
>Originator:     Hauke Fath <hauke@Espresso.Rhein-Neckar.DE>
>Release:        NetBSD 3.0_BETA
/~\  The ASCII Ribbon Campaign                    Hauke Fath
\ /    No HTML/RTF in email	        Institut für Nachrichtentechnik
 X     No Word docs in email	                  TU Darmstadt
/ \  Respect for open standards              Ruf +49-6151-16-3281
System: NetBSD quiche 3.0_BETA NetBSD 3.0_BETA (QUICHE) #4: Mon Sep 5 22:10:05 CEST 2005 hauke@quiche:/usr/src/sys/arch/i386/compile/QUICHE i386
Architecture: i386
Machine: i386

Pulling an Adaptec ADP-1480 pc-card from my Thinkpad T23 
panics reproducibly:


cbb1: wait took 0.019313s
cardbus_mapreg_map called: cardbus1 0
cardbus_mapreg_map: physaddr 40000000
cardbus1: unmap mem space
ahc0 at cardbus1 dev 0 function 0: Adaptec ADP-1480 SCSI
cardbus_mapreg_map called: cardbus1 0
cardbus_mapreg_map: physaddr 40000000
ahc0: interrupting at 11
ahc0: CardBus device requires an SEEPROM


panic: hook_disestablish: hook 0x0 not established
Stopped in pid 8.1 (cardslot1) at       netbsd:cpu_Debugger+0x4:        popl %ebp
db> t
cpu_Debugger(c055111d,cad83e98,339d43df,0,0) at netbsd:cpu_Debugger+0x4
panic(c05781c0,0,cad83eac,c031f6c9,c05f6d34) at netbsd:panic+0x12b
hook_disestablish(c05f6d34,0,cad83ecc,c01b5247,0) at 0xc031f5f1
shutdownhook_disestablish(0,0,3297ff0d,c0c2e800,0) at netbsd:shutdownhook_disestablish+0x19
ahc_detach(c0c2e800,0,cad83efc,c032a1c7,c0c2e800) at netbsd:ahc_detach+0x47
ahc_cardbus_detach(c0c2e800,0,0,ca42b39c,0) at netbsd:ahc_cardbus_detach+0x1b
config_detach(c0c2e800,0,cad83f5c,0,1) at netbsd:config_detach+0x299
cardbus_detach_card(c0c27600,20,c054a665,0,0) at netbsd:cardbus_detach_card+0x29
cardslot_event_thread(c0c0c200,683000,68b000,0,c0100321) at netbsd:cardslot_event_thread+0x190

-- note that the card configures and works fine on a -current kernel. 
And, while a 16bit APA-1460 does not work correctly (PR kern/31164), 
at least it detaches properly.


	Insert Adaptec ADP-1480 pc-card into netbsd-3 notebook, 
then remove it. Watch notebook panic.

	Pull up relevant changes from -current?