[alsa-devel] Kernel crashes for unsupported sample rates
Aggarwal, Anuj
anuj.aggarwal at ti.com
Thu May 15 12:23:11 CEST 2008
Hi,
I tried "pcm" sample application which is coming along with the alsa-libs package (in the test folder). It works well for the sample rates supported by my audio driver but gives me a kernel crash when tried with any other non-supporting sample rate. If the driver has explicitly said that these sample rates are not-supported, then the app should have exited gracefully instead of trying further.
The log is as below (attached also):
[root at MY_EVM bin]# ./pcm -r 10000 -v
Playback device is plughw:0,0
Stream parameters are 10000Hz, S16_LE, 1 channels
Sine wave rate is 440.0000Hz
Using transfer method: write
Plug PCM: Rate conversion PCM (11025, sformat=S16_LE)
Its setup is:
Alignment trap: not handling instruction e1932f9f at [<c02317a0>]
access : RW_INTERLEAVEDUnhandled fault: alignment exception (0x001) at 0x00000003
format : S16_LE
subInternal error: : 1 [#5]
Modules linked in:
CPU: 0 Not tainted (2.6.22.18-omap3 #1)
PC is at snd_pcm_mmap_data_nopage+0xb8/0xe4
LR is at 0xc7b71c00
pc : [<c02317a4>] lr : [<c7b71c00>] psr: 60000113
sp : c69c3e58 ip : c77f9460 fp : c69c3e6c
r10: 00000000 r9 : 402f2000 r8 : c7dc4f04
r7 : c77a7bd0 r6 : 00000000 r5 : c69c3e94 r4 : 402f2000
r3 : 00000003 r2 : bf3fe000 r1 : 00000000 r0 : c0be3540
Flags: nZCv IRQs on FIQs on Mode SVC_32 Segment user
Control: 00c5387f Table: 807ec018 DAC: 00000015
Process pcm (pid: 324, stack limit = 0xc69c22d8)
Stack: (0xc69c3e58 to 0xc69c4000)
3e40: 00000000 c69c2000
3e60: c69c3ec4 c69c3e70 c0092d2c c02316f8 c69c3e8c c69c3e80 c00580f4 c005c99c
3e80: 00000800 c0025380 000003c8 c07ed008 174c3094 00000002 17bfac7c c03a600c
3ea0: c055bd60 c77a7bd0 c00253b4 c0025380 c69c3fb0 402f2000 c69c3f04 c69c3ec8
3ec0: c0030fb0 c0092c08 174c3094 c0844123 0001f040 00000817 c055d6c0 c03a600c
3ee0: 00000817 c69c3fb0 402f2000 0008d3dd 00000000 00000000 c69c3fac c69c3f08
3f00: c002a1e8 c0030ed8 c03b22e4 c0844123 0001f040 00000004 c055d6c0 c002af68
3f20: c69c3f3c c69c3f30 c02356bc c0235134 c69c3f54 c69c3f40 c00b166c c0235694
3f40: c055d6c0 0001f040 c69c3f7c c69c3f58 c00b1910 c00b1644 00000025 c03b30d0
3f60: 00000004 0001f040 c0844123 c055d6c0 c69c3fa4 c69c3f80 c00b1968 c00b16bc
3f80: c69c3fac 00000000 0001ef20 0001eee0 ffffffff 00000000 00000000 00000000
3fa0: 00000000 c69c3fb0 c002ad60 c002a1b8 402f2000 00000000 00000000 00000000
3fc0: 00080000 00000000 00000000 00000000 0008d3dd 00000000 00000000 00020398
3fe0: 00000000 bed06588 40088d30 40088d58 20000010 ffffffff 00000000 00000000
Backtrace:
[<c02316ec>] (snd_pcm_mmap_data_nopage+0x0/0xe4) from [<c0092d2c>] (__handle_mm_fault+0x130/0x968)
r5:c69c2000 r4:00000000
[<c0092bfc>] (__handle_mm_fault+0x0/0x968) from [<c0030fb0>] (do_page_fault+0xe4/0x218)
[<c0030ecc>] (do_page_fault+0x0/0x218) from [<c002a1e8>] (do_DataAbort+0x3c/0x9c)
[<c002a1ac>] (do_DataAbort+0x0/0x9c) from [<c002ad60>] (ret_from_exception+0x0/0x10)
Exception stack(0xc69c3fb0 to 0xc69c3ff8)
3fa0: 402f2000 00000000 00000000 00000000
3fc0: 00080000 00000000 00000000 00000000 0008d3dd 00000000 00000000 00020398
3fe0: 00000000 bed06588 40088d30 40088d58 20000010 ffffffff
r7:00000000 r6:00000000 r5:00000000 r4:ffffffff
Code: 0590300c 11a03000 e2833004 e1932f9f (e2822001)
format : STD
channels : 1
rate : 10000
exact rate : 10000 (10000/1)
msbits : 16
buffer_size : 14860
period_size : 928
period_time : 92879
tick_time : 7812
tstamp_mode : NONE
period_step : 1
sleep_min : 0
avail_min : 928
xfer_align : 1
start_threshold : 14848
stop_threshold : 14860
silence_threshold: 0
silence_size : 0
boundary : 973864960
Slave: Hardware PCM card 0 'TWL4030' device 0 subdevice 0
Its setup is:
stream : PLAYBACK
access : MMAP_INTERLEAVED
format : S16_LE
subformat : STD
channels : 1
rate : 11025
exact rate : 11025 (11025/1)
msbits : 16
buffer_size : 16384
period_size : 1024
period_time : 92879
tick_time : 7812
tstamp_mode : NONE
period_step : 1
sleep_min : 0
avail_min : 1024
xfer_align : 1
start_threshold : 16384
stop_threshold : 16384
silence_threshold: 0
silence_size : 0
boundary : 1073741824
Segmentation fault
Is the driver not handling anything properly or is it the intended behavior? Please help.
Thanks and Regards,
Anuj Aggarwal
-------------- next part --------------
An embedded and charset-unspecified text was scrubbed...
Name: unsupported_crash.txt
Url: http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20080515/6064c5aa/attachment.txt
More information about the Alsa-devel
mailing list