ral(4) cardbus crash
Max Herrgård
herrgard at gmail.com
Wed Jul 21 12:07:01 PDT 2010
Max Herrgård wrote:
> Nicolas Thery wrote:
>> diff --git a/sys/dev/netif/ral/if_ral_pci.c b/sys/dev/netif/ral/if_ral_pci.c
>> index 4af51b1..c94fad7 100644
>> --- a/sys/dev/netif/ral/if_ral_pci.c
>> +++ b/sys/dev/netif/ral/if_ral_pci.c
>> @@ -164,7 +164,7 @@ ral_pci_attach(device_t dev)
>> {
>> struct ral_pci_softc *psc = device_get_softc(dev);
>> struct rt2560_softc *sc = &psc->u.sc_rt2560;
>> - struct ifnet *ifp = sc->sc_ifp;
>> + struct ifnet *ifp;
>> int error;
>>
>> if (pci_get_powerstate(dev) != PCI_POWERSTATE_D0) {
>> @@ -202,6 +202,7 @@ ral_pci_attach(device_t dev)
>> error = (*psc->sc_opns->attach)(dev, pci_get_device(dev));
>> if (error != 0)
>> return error;
>> + ifp = sc->sc_ifp;
>>
>> /*
>> * Hook our interrupt after all initialization is complete.
>
> Yup. This patch fixes this crash.
>
> Thank you,
> Max
However, this happens when I try to use it:
bender# ifconfig ral0 up
Jul 21 22:47:29 bender kernel: in6_ifattach_linklocal: failed to configure a link-local address on ral0 (errno=22)
bender# ifconfig wlan0 create wlandev ral0
wlan0: MAC address: 00:08:a1:a4:8d:97
. ..and then this crash comes when doing 'ifconfig wlan0 up':
Reading symbols from /usr/home/crash/kern.5...done.
Unread portion of the kernel message buffer:
ral0: need multicast update callback
panic: only BUS_DMA_NOWAIT is supported
Trace beginning at frame 0xc72ddb9c
panic(ffffffff) at panic+0x8e
panic(c062171c,c72ddc32,45e0d8,0,c723b0c0) at panic+0x8e
bus_dmamap_load_mbuf_segment(c14b3840,0,c9708d00,c72ddc20,1,c72ddc48,0) at bus_dmamap_load_mbuf_segment+0x6d
rt2661_raw_xmit(c6fb52b8,c9708d00,c72ddc96) at rt2661_raw_xmit+0x128
ieee80211_send_probereq(c6fb52b8,c723b364,c058d0c0,c058d0c0,c05c9174,0) at ieee80211_send_probereq+0x3c1
ieee80211_probe_curchan(c723b0c0,0) at ieee80211_probe_curchan+0xb3
scan_curchan(c70669c8,14,c6fb04b8,c6fb04b8,c6fb04cc) at scan_curchan+0x29
scan_task(c70669c8,1,c1423a20,c1423a3c,c06cbb18) at scan_task+0x2a4
taskqueue_run(c06cbb18,ff800000,0,c0322647,c6fb0534) at taskqueue_run+0x70
taskqueue_thread_loop(c6fb0534,0,0,0,0) at taskqueue_thread_loop+0x2b
lwkt_exit() at lwkt_exit
Debugger("panic")
panic: from debugger
Uptime: 54m58s
Physical memory: 215 MB
Dumping 48 MB: 33 17 1
Reading symbols from /boot/modules/vesa.ko...done.
Loaded symbols for /boot/modules/vesa.ko
Reading symbols from /boot/modules/acpi.ko...done.
Loaded symbols for /boot/modules/acpi.ko
_get_mycpu (di=0xc06d7980) at ./machine/thread.h:83
in ./machine/thread.h
(kgdb) bt
#0 _get_mycpu (di=0xc06d7980) at ./machine/thread.h:83
#1 md_dumpsys (di=0xc06d7980) at /usr/src/sys/platform/pc32/i386/dump_machdep.c:263
#2 0xc0319ea1 in dumpsys () at /usr/src/sys/kern/kern_shutdown.c:839
#3 0xc031a41c in boot (howto=260) at /usr/src/sys/kern/kern_shutdown.c:388
#4 0xc031a542 in panic (fmt=0xc05adfb2 "from debugger") at /usr/src/sys/kern/kern_shutdown.c:745
#5 0xc0178ad5 in db_panic (addr=-1068167144, have_addr=0, count=-1, modif=0xc72dda54 "") at /usr/src/sys/ddb/db_command.c:448
#6 0xc017914a in db_command () at /usr/src/sys/ddb/db_command.c:344
#7 db_command_loop () at /usr/src/sys/ddb/db_command.c:470
#8 0xc017b758 in db_trap (type=3, code=0) at /usr/src/sys/ddb/db_trap.c:71
#9 0xc0551184 in kdb_trap (type=3, code=0, regs=0xc72ddb4c) at /usr/src/sys/platform/pc32/i386/db_interface.c:152
#10 0xc0563717 in trap (frame=0xc72ddb4c) at /usr/src/sys/platform/pc32/i386/trap.c:837
#11 0xc0552557 in calltrap () at /usr/src/sys/platform/pc32/i386/exception.s:785
#12 0xc0551018 in breakpoint (msg=0xc05c5eca "panic") at ./cpu/cpufunc.h:73
#13 Debugger (msg=0xc05c5eca "panic") at /usr/src/sys/platform/pc32/i386/db_interface.c:334
#14 0xc031a539 in panic (fmt=0xc062171c "only BUS_DMA_NOWAIT is supported\n") at /usr/src/sys/kern/kern_shutdown.c:743
#15 0xc0550ced in bus_dmamap_load_mbuf_segment (dmat=0xc14b3840, map=0x0, m0=0xff800000, segs=0xc72ddc20, maxsegs=1,
nsegs=0xc72ddc48, flags=<value optimized out>) at /usr/src/sys/platform/pc32/i386/busdma_machdep.c:882
#16 0xc029ea45 in rt2661_tx_mgt (ni=0xc6fb52b8, m=0xc9708d00, params=0xc72ddc96) at /usr/src/sys/dev/netif/ral/rt2661.c:1337
#17 rt2661_raw_xmit (ni=0xc6fb52b8, m=0xc9708d00, params=0xc72ddc96) at /usr/src/sys/dev/netif/ral/rt2661.c:1691
#18 0xc03bea87 in ieee80211_send_probereq (ni=0xc6fb52b8, sa=0xc723b364 "",
da=0xc058d0c0 "\377\377\377\377\377\377ether_input_chain", bssid=0xc058d0c0 "\377\377\377\377\377\377ether_input_chain",
ssid=0xc05c9174 "", ssidlen=0) at /usr/src/sys/netproto/802_11/wlan/ieee80211_output.c:1821
#19 0xc03c31a8 in ieee80211_probe_curchan (vap=0xc723b0c0, force=0) at /usr/src/sys/netproto/802_11/wlan/ieee80211_scan.c:791
#20 0xc03c3c01 in scan_curchan (ss=0xc70669c8, maxdwell=20) at /usr/src/sys/netproto/802_11/wlan/ieee80211_scan.c:809
#21 0xc03c3ed5 in scan_task (arg=0xc70669c8, pending=1) at /usr/src/sys/netproto/802_11/wlan/ieee80211_scan.c:940
#22 0xc033bdbb in taskqueue_run (queue=0xc1423a20, lock_held=1) at /usr/src/sys/kern/subr_taskqueue.c:271
#23 0xc033bf4d in taskqueue_thread_loop (arg=0xc6fb0534) at /usr/src/sys/kern/subr_taskqueue.c:373
#24 0xc0322647 in lwkt_deschedule_self (td=) at /usr/src/sys/kern/lwkt_thread.c:250
Backtrace stopped: previous frame inner to this frame (corrupt stack?)
Max
More information about the Bugs
mailing list