Subject: kern/31989: insertion of pcmcia card causes panic
To: None <kern-bug-people@netbsd.org, gnats-admin@netbsd.org,>
From: None <dogcow@babymeat.com>
List: netbsd-bugs
Date: 11/03/2005 12:11:01
>Number:         31989
>Category:       kern
>Synopsis:       insertion of pcmcia card causes panic
>Confidential:   no
>Severity:       serious
>Priority:       low
>Responsible:    kern-bug-people
>State:          open
>Class:          sw-bug
>Submitter-Id:   net
>Arrival-Date:   Thu Nov 03 12:11:00 +0000 2005
>Originator:     moof
>Release:        NetBSD 3.99.11
>Organization:
        
>Environment:
        
        
System: NetBSD craptop.babymeat.com 3.99.11 NetBSD 3.99.11 (DEBUGCREPIT) #0: Thu Nov 3 02:22:31 PST 2005 dogcow@:/usr/home/dogcow/obj/obj/usr/src/sys/arch/i386/compile/DEBUGCREPIT i386
Architecture: i386
Machine: i386
>Description:
        
Upon insertion of a crappy ACX100 (IIRC) network card, I get a rather
nasty and immediate panic:

cbb0: wait took 0.007879s
cardbus_mapreg_map called: cardbus0 0
cardbus_mapreg_map: physaddr 40000000
uvm_fault(0xc037cdc0, 0xca9ae000, 0, 1) -> 0xe
fatal page fault in supervisor mode
trap type 6 code 0 eip c02d0c97 cs 8 eflags 10287 cr2 ca9ae000 ilevel 0
panic: trap
Begin traceback...
trap() at netbsd:trap+0x16c
--- trap (number 6) ---
cardbus_read_tuples(ca992584,ca9adc00,ca992724,800,0) at netbsd:cardbus_read_tuples+0x237

and from gdb:

(gdb) up
#5  0xc02d1658 in cardbus_rescan (self=0xc0918900, 
    ifattr=0xc0314d5e "cardbus", locators=0xc0365dc8)
    at /usr/src/sys/dev/cardbus/cardbus.c:570
569                     if (cis_ptr != 0) {
570                             if (cardbus_read_tuples(&ca, cis_ptr,
571                                 tuple, sizeof(tuple))) {
572                                     printf("cardbus_attach_card: "
573                                         "failed to read CIS\n");

(gdb) print cis_ptr
$1 = 3074

the cis_ptr value looks suspicious.
>How-To-Repeat:
        
Insert said card into my Toshiba Tecra 8000 laptop.
>Fix:
        
Workaround: "don't do that."

>Unformatted: