Repository navigation
Closed
Labels
APLApplies to Apollolake platformApplies to Apollolake platformBYTApplies to Baytrail platformApplies to Baytrail platformbugSomething isn't working as expectedSomething isn't working as expected
Description
Describe the bug
Pause release error: Device or resource busy when do playback/capture test on BYT platform.
To Reproduce
1.Playback via "aplay -Dhw:0,0 -r48000 -c2 -fs16_le 1.wav -vv -i"
2.Pause aplay
3.Resume aplay
Reproduction Rate
1/20
Environment
Firmware: fee2517 https://github.com/thesofproject/sof/commits/master
Kernel: df832fb https://github.com/thesofproject/linux/commits/topic/sof-dev
Topology: file: tools/topology/sof-byt-nocodec.tplg
platform: BYT
Screenshots or console output
ubuntu@cd-byt-mb-nocodec-04:~$ aplay -Dhw:0,0 -fS16_LE -c2 -r 48000 audio-files/raw/test-c2-r48000-fs16_le-d60.raw -vv -i
Playing raw data 'audio-files/raw/test-c2-r48000-fs16_le-d60.raw' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Hardware PCM card 0 'sof-nocodec' device 0 subdevice 0
Its setup is:
stream : PLAYBACK
access : RW_INTERLEAVED
format : S16_LE
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 16
buffer_size : 16368
period_size : 4080
period_time : 85000
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 4080
period_event : 0
start_threshold : 16368
stop_threshold : 16368
silence_threshold: 0
silence_size : 0
boundary : 9214364837600034816
appl_ptr : 0
hw_ptr : 0
=== PAUSE === aplay: do_pause:1508: pause release error: Device or resource busy
sof-logger
CORE LEVEL COMP_ID TIMESTAMP DELTA FILE_NAME CONTENT
0 1 WAIT 67877602.239583 67877600.000000 src/lib/wait.c:89 ewt
0 1 DMA 67877608.541667 6.302083 src/drivers/dw/dma.c:375 dw_dma_stop() error: dma 1 channel 1 timeout
0 1 DMA 67891738.281250 14129.739258 src/drivers/dw/dma.c:218 dw_dma_start() error: dma 1 channel 1 not ready ena 0x2 status 0x3
0 1 IPC 67891750.677083 12.395833 src/audio/pipeline.c:701 pipeline_trigger() error: ret = -16, host->comp.id = 1, cmd = 3
0 1 IPC 67891760.833333 10.156250 src/ipc/handler.c:489 ipc: comp 1 trigger 0x70000 failed -16
0 1 DMA 78763174.114583 10871413.000000 src/drivers/dw/dma.c:218 dw_dma_start() error: dma 1 channel 1 not ready ena 0x2 status 0x3
0 1 IPC 78763186.510417 12.395833 src/audio/pipeline.c:701 pipeline_trigger() error: ret = -16, host->comp.id = 1, cmd = 3
0 1 IPC 78763196.666667 10.156250 src/ipc/handler.c:489 ipc: comp 1 trigger 0x70000 failed -16
0 1 COMP 78764922.291667 1725.625000 rc/audio/component.c:192 comp_set_state() error: wrong state = 4, COMP_TRIGGER_RESET
0 1 COMP 78764931.979167 9.687500 rc/audio/component.c:192 comp_set_state() error: wrong state = 4, COMP_TRIGGER_RESET
0 1 COMP 78764941.614583 9.635417 rc/audio/component.c:192 comp_set_state() error: wrong state = 4, COMP_TRIGGER_RESET
0 1 COMP 78764952.656250 11.041667 rc/audio/component.c:192 comp_set_state() error: wrong state = 4, COMP_TRIGGER_RESET
dmesg
[ 67.398671] sof-audio-acpi 80860F28:01: posn : host 0x39c0 dai 0x106680 wall 0x17c5a1
[ 67.398700] sof-audio-acpi 80860F28:01: ipc rx done: 0x600a0001: GLB_STREAM_MSG: POSITION
[ 67.398736] sof-audio-acpi 80860F28:01: PCM: stream 0 dir 0 DMA position 3696 DAI position 268704
[ 67.400662] sof-audio-acpi 80860F28:01: PCM: stream 0 dir 0 DMA position 3696 DAI position 268704
[ 67.400684] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 3
[ 67.400701] sof-audio-acpi 80860F28:01: ipc tx: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 67.401400] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 67.411109] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 4
[ 67.411118] sof-audio-acpi 80860F28:01: ipc tx: 0x60070000: GLB_STREAM_MSG: TRIG_RELEASE
[ 67.411203] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60070000: GLB_STREAM_MSG: TRIG_RELEASE
[ 67.411368] sof-audio-acpi 80860F28:01: PCM: stream 0 dir 0 DMA position 3696 DAI position 268704
[ 68.018975] sof-audio-acpi 80860F28:01: PCM: stream 0 dir 0 DMA position 3696 DAI position 268704
[ 68.018997] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 3
[ 68.019015] sof-audio-acpi 80860F28:01: ipc tx: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 68.020565] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 68.034475] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 4
[ 68.034484] sof-audio-acpi 80860F28:01: ipc tx: 0x60070000: GLB_STREAM_MSG: TRIG_RELEASE
[ 68.035160] sof-audio-acpi 80860F28:01: error: ipc error for 0x60070000 size 12
[ 68.035175] Low Latency: ASoC: trigger FE failed -16
[ 68.035188] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 3
[ 68.035195] sof-audio-acpi 80860F28:01: ipc tx: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 68.035273] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 78.908624] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 4
[ 78.908646] sof-audio-acpi 80860F28:01: ipc tx: 0x60070000: GLB_STREAM_MSG: TRIG_RELEASE
[ 78.908811] sof-audio-acpi 80860F28:01: error: ipc error for 0x60070000 size 12
[ 78.908886] Low Latency: ASoC: trigger FE failed -16
[ 78.908909] sof-audio-acpi 80860F28:01: pcm: trigger stream 0 dir 0 cmd 3
[ 78.908924] sof-audio-acpi 80860F28:01: ipc tx: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 78.910347] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60060000: GLB_STREAM_MSG: TRIG_PAUSE
[ 78.910383] sof-audio-acpi 80860F28:01: pcm: free stream 0 dir 0
[ 78.910398] sof-audio-acpi 80860F28:01: ipc tx: 0x60030000: GLB_STREAM_MSG: PCM_FREE
[ 78.911004] sof-audio-acpi 80860F28:01: ipc tx succeeded: 0x60030000: GLB_STREAM_MSG: PCM_FREE
[ 78.911047] sof-audio-acpi 80860F28:01: pcm: close stream 0 dir 0
Metadata
Metadata
Assignees
Labels
APLApplies to Apollolake platformApplies to Apollolake platformBYTApplies to Baytrail platformApplies to Baytrail platformbugSomething isn't working as expectedSomething isn't working as expected
Activity
Jiangxinx commentedon Oct 9, 2019
This issue also can be observed on apl platform.
tlauda commentedon Oct 9, 2019
@Jiangxinx Please provide FW logs from APL.
Jiangxinx commentedon Oct 9, 2019
Add apl logs:
Screenshots or console output
dmesg
sof-logger
Environment
Firmware: c8bc4b2 https://github.com/thesofproject/sof/commits/master
Kernel: 0f665a4 https://github.com/thesofproject/linux/commits/topic/sof-dev
Topology: file: tools/topology/sof-apl-pcm512x.tplg
platform: APL
tlauda commentedon Oct 9, 2019
@Jiangxinx Are you playing on HDA?
Jiangxinx commentedon Oct 9, 2019
@tlauda No, I played using I2S device ( -Dhw:0,0 ).
Jiangxinx commentedon Oct 16, 2019
This issues still can be reproduced on BYT platform. However, the phenomenon is very strange.
I tested it on two similar devices (byt-nocodec) ,and one can reproduce it, another cannot reproduced it. It seems that this issue is not related to the sof version, and will suddenly appear from time to time.
Environment
Firmware: b5982a4 https://github.com/thesofproject/sof/commits/master
Kernel: 5edcfdf https://github.com/thesofproject/linux/commits/topic/sof-dev
Topology: file: tools/topology/sof-byt-nocodec.tplg
platform: BYT
test result
device: ubuntu@sh-byt-mb-nocodec-03
result: pass
alsamixer setting:
03-asound.txt
device: ubuntu@cd-byt-mb-nocodec-04
result: failed
alsamixer setting:
04-asound.txt
juimonen commentedon Oct 22, 2019
ack. will start checking tomorrow...
juimonen commentedon Oct 23, 2019
using latest kernel & fw, very easy to reproduce this error with pause/release:
aplay: pcm_write:2011: write error: Input/output error
attaching fw log, @tlauda any idea?
byt_fw_log.txt
is byt affected by the 3 periods change?
juimonen commentedon Oct 23, 2019
and the above was with nocodec topology
tlauda commentedon Oct 23, 2019
@juimonen Could you verify if #1984 improves it?
juimonen commentedon Oct 23, 2019
@tlauda yes #1984 seems to help and I can't reporoduce it now.
juimonen commentedon Oct 23, 2019
@Jiangxinx can you also try/verify with #1984? my test's we're very minimal, but could not reproduce the issue..
Jiangxinx commentedon Oct 23, 2019
@juimonen @tlauda Very strange, I tried #1984 , I still can reproduce it on my device.
Environment
Kernel: 2114793 https://github.com/thesofproject/linux/commits/topic/sof-dev
Topology: file: tools/topology/sof-byt-nocodec.tplg
platform: BYT
sof-logger
tlauda commentedon Oct 23, 2019
@Jiangxinx Could you attach full log from sof-logger -t? Also does it reproduce only on one machine or on couple of them. This particular error looks like some kind of HW problem.
Jiangxinx commentedon Oct 23, 2019
@tlauda Attached the full fw log:
logger.log
Jiangxinx commentedon Oct 23, 2019
@tlauda Yes, I tried two machines, another one still can not reproduce it, but my device is very easy to reproduce it.
tlauda commentedon Oct 23, 2019
@Jiangxinx I have no idea what is going on with this particular platform. I can't reproduce the issue on any other BYT. After stopping and restarting DMA there is no interrupt coming and we cannot stop DMA. Hardware is stuck. Could you look for the differences between platforms? Maybe BIOS is different or has different settings? I've tried 3 different platforms and it didn't reproduce.
juimonen commentedon Oct 23, 2019
@tlauda @Jiangxinx same here also: I've been hitting the space bar like crazy in my byt-mb-> no error... it just works for me with #1984
Jiangxinx commentedon Oct 25, 2019
Close it as it is HW problem.