Re: panic when detecting an ES1373 AudioPCI sound card

From: Thierry Herbelot <thierry_at_herbelot.com>
Date: Wed, 4 Jul 2007 19:29:27 +0200
Le Monday 04 June 2007, Ariff Abdullah a écrit :
>
> Try reproduce the panic, and when it drops to ddb, do "show alllocks".
>

Hello,

I just checked if the problem was still present :
(after booting verbose & single-user my most recent kernel, from sources 
cvsuped yesterday)

[skipping messages from the verbose boot]
....
Trying to mount root from ufs:/dev/ad0s1a
start_init: trying /sbin/init
Enter full pathname of shell or RETURN for /bin/sh:
# kldload /boot/kernel/snd_es137x.ko
pci0: driver added
found-> vendor=0x134a, dev=0x0001, revid=0x00
        bus=0, slot=13, func=0
        class=01-00-00, hdrtype=0x00, mfdev=0
        cmdreg=0x0001, statreg=0x0200, cachelnsz=0 (dwords)
        lattimer=0x00 (0 ns), mingnt=0x00 (0 ns), maxlat=0x00 (0 ns)
        intpin=a, irq=17
pci0:13:0: reprobing on driver added
found-> vendor=0x1274, dev=0x5000, revid=0x00
        bus=0, slot=17, func=0
        class=04-01-00, hdrtype=0x00, mfdev=0
        cmdreg=0x0105, statreg=0x0400, cachelnsz=0 (dwords)
        lattimer=0x20 (960 ns), mingnt=0x0c (3000 ns), maxlat=0x80 (32000 ns)
        intpin=a, irq=3
pci0:17:0: reprobing on driver added
pcm1: <AudioPCI ES1370> port 0xcc00-0xcc3f irq 19 at device 17.0 on pci0
pcm1: Reserved 0x40 bytes for rid 0x10 type 4 at 0xcc00
pcm1: es1370_wrcodec: timed out
pcm1: Mixer "vol":
pcm1: Mixer "pcm":
pcm1: Mixer "line":
pcm1: Mixer "mic":
pcm1: Mixer "cd":
pcm1: Mixer "ogain":
pcm1: Mixer "line1":
pcm1: Mixer "line2":
pcm1: Mixer "line3":
pcm1: [MPSAFE]
pcm1: [ITHREAD]
pcm1: clone manager: deadline=750ms flags=0x8000001e
pcm1: sndbuf_setmap 13987000, 1000; 0xc26b9000 -> 13987000
pcm1: sndbuf_setmap 1398b000, 1000; 0xc26bd000 -> 1398b000
pcm1: sndbuf_setmap 1398d000, 1000; 0xc26bf000 -> 1398d000
panic: _mtx_lock_sleep: recursed on non-recursive mutex pcm1 
_at_ /tank/files1/src/sys/modules/sound/driver/es137x/../../../../dev/sound/pci/es137x.c:510

cpuid = 1
KDB: enter: panic
[thread pid 55 tid 100055 ]
Stopped at      kdb_enter+0x32: leave
db> where
Tracing pid 55 tid 100055 td 0xc26d9800
kdb_enter(c0a8fdde,1,c0a8ec7f,d53bf6cc,1,...) at kdb_enter+0x32
panic(c0a8ec7f,c2680740,c26f4dcf,1fe,c25aca60,...) at panic+0x124
_mtx_lock_sleep(c25aca60,c26d9800,0,c26f4dcf,1fe,...) at _mtx_lock_sleep+0x47
_mtx_lock_flags(c25aca60,0,c26f4dcf,1fe,c26806c0,...) at _mtx_lock_flags+0xef
eschan_setformat(c26806c0,c269d4c8,10000010,649,c2687e00,...) at 
eschan_setformat+0x3d
chn_tryspeed(c26806c0,c269d4c8,10000010,69f,c2687e00,...) at 
chn_tryspeed+0x2a5
chn_tryformat(c26806c0,c269d4c8,c0d6155f,0,c2696000,...) at chn_tryformat+0xe1
chn_setformat(c2696000,10000010,c0d65058,3f8,2,...) at chn_setformat+0x1f
chn_reset(c2696000,10000010,c0d632f7,32f,ffffffff,...) at chn_reset+0xc1
vchan_create(c2696000,ffffffff,c0d62b54,e4,1,...) at vchan_create+0x42d
pcm_setvchans(ffffffff,c,c0b43700,c26806f0,c269ce00,...) at 
pcm_setvchans+0x187
pcm_setmaxautovchans(c252a680,2,7,c2680670,c2680670,...) at 
pcm_setmaxautovchans+0xc0
pcm_setstatus(c252a680,d53bf908,ffffffff,c26f50a5,c0000002,...) at 
pcm_setstatus+0x82
es_pci_attach(c252a680,c26a184c,c0b3b51c,c0a921e8,80000000,...) at 
es_pci_attach+0x11fe
device_attach(c252a680,c252a680,c0a9213e,917,c252a680,...) at 
device_attach+0x36f
device_probe_and_attach(c252a680,c252f100,11,0,c267f600,...) at 
device_probe_and_attach+0x100
pci_driver_added(c252ad80,c26f6544,c0b3b36c,0,c26f6530,...) at 
pci_driver_added+0xf5
devclass_add_driver(c242ba40,c26f6544,0,2d,c26f6544,...) at 
devclass_add_driver+0xe8
driver_module_handler(c267f580,0,c26f6530,76,d53bfc1c,...) at 
driver_module_handler+0x79
module_register_init(c26f64cc,0,c0a8d21d,dc,0,...) at 
module_register_init+0xa7
linker_load_module(0,d53bfc4c,c0a8d21d,364,bfbfee7c,...) at 
linker_load_module+0x9fa
kern_kldload(c26d9800,c267d000,d53bfc70,0,2ff,...) at kern_kldload+0xc8
kldload(c26d9800,d53bfcfc,4,c,c0b3dae0,...) at kldload+0x74
syscall(d53bfd38) at syscall+0x2b3
Xint0x80_syscall() at Xint0x80_syscall+0x20
--- syscall (304, FreeBSD ELF32, kldload), eip = 0x280c106b, esp = 0xbfbfee0c, 
ebp = 0xbfbfee38 ---
db> show alllocks
Process 55 (kldload) thread 0xc26d9800 (100055)
exclusive sleep mutex pcm1 (snd_es137x softc) r = 0 (0xc25aca60) locked 
_at_ /tank/files1/src/sys/modules/sound/driver/es137x/../../../../dev/sound/pci/es137x.c:544
exclusive sleep mutex pcm1:record:dsp1.r0 (pcm record channel) r = 0 
(0xc25acce0) locked 
_at_ /tank/files1/src/sys/modules/sound/sound/../../../dev/sound/pcm/vchan.c:815
exclusive sleep mutex Giant r = 1 (0xc0ba3a48) locked 
_at_ /tank/files1/src/sys/kern/kern_module.c:117
db> 

>
> 3) Get http://people.freebsd.org/~ariff/test/es137x_mtx_grumpy.c and
>    replace your sys/dev/sound/pci/es137x.c. Look for "IMPOSSIBLE!"
>    kernel message during loading and startup.

will do !

	Thierry
Received on Wed Jul 04 2007 - 15:29:41 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:13 UTC