Repository navigation
[BUG IMX] Playback and capture occasionally fails #3809
Copy link
Copy link
Closed
Labels
IMXApplies to i.MX platformApplies to i.MX platformbugSomething isn't working as expectedSomething isn't working as expected
Description
Describe the bug
Playback and capture occasionally fails with Input/output error
To Reproduce
Run playback and capture simultaneously.
Or run the script below:
#!/bin/bash
test_aplay()
{
while true
do
aplay -Dhw:1,0 -f S32_LE -c 2 -r 48000 -t raw test_play.wav
done
}
test_arecord()
{
while true
do
arecord -Dhw:1,0 -f S32_LE -c 2 -r 48000 -d 5 test_record.pcm
done
}
test_aplay &
test_arecord
Reproduction Rate
20%
Environment
- Branch name and commit hash of the 2 repositories: sof (firmware/topology) and linux (kernel driver).
- Kernel: 5.10
- SOF: master, imx-stable-v1.5, imx-stable-v1.6.
- Name of the topology file
- Topology: sof-imx8qxp-wm8960.tplg, sof-imx8qxp-cs42888-mixer.tplg, sof-imx8mp-wm8960.tplg
- Name of the platform(s) on which the bug is observed.
- Platform: i.MX8QXP/i.MX8QM/i.MX8MP
Screenshots or console output
root@imx8qmmek:~# audio_dsp_sof.sh -t 4 -c wm8960 -f p -n 50
DSP_SOF_PLAY_RECORD_WORK_TOGETHER 0 TINFO : test 4: DSP_SOF_PLAY_RECORD_WORK_TOGETHER
TINFO : Do full hardware capacity test
TINFO : Do full hardware capacity test
TINFO : Start audio test, please check the HEADPHONE,hear if there is voice.
TINFO : Audio TEST: Total 3 combinations of formats.
TINFO : No.[1] Now playing audio stream with format S16_LE, channel 2,sample rate 48000
TINFO : Test #1: ADC record test. Headphone is need to check the voice and quality of recording.
TINFO : Audio TEST: Total 3 combinations of formats.
TINFO : No.[1] Now Recording audio stream with format S16_LE, channel 2,sample rate 48000
TINFO : No.[2] Now playing audio stream with format S24_LE, channel 2,sample rate 48000
TINFO : No.[3] Now playing audio stream with format S32_LE, channel 2,sample rate 48000
TINFO : No.[2] Now Recording audio stream with format S24_LE, channel 2,sample rate 48000
TINFO : Start audio test, please check the HEADPHONE,hear if there is voice.
TINFO : Audio TEST: Total 3 combinations of formats.
TINFO : No.[4] Now playing audio stream with format S16_LE, channel 2,sample rate 48000
TINFO : No.[5] Now playing audio stream with format S24_LE, channel 2,sample rate 48000
TINFO : No.[3] Now Recording audio stream with format S32_LE, channel 2,sample rate 48000
TFAIL : ltpapicmd.c:188: Test #1: Playing back audio48k24b2c_sle.pcm Failed on hw:1,0
Playing raw data '/tmp/tmpfs/tmp.jWsafwNfuh/audio48k24b2c_sle.pcm' : Signed 24 bit Little Endian, Rate 48000 Hz, Stereo
aplay: pcm_write:2061: write error: Input/output error
TINFO : No.[6] Now playing audio stream with format S32_LE, channel 2,sample rate 48000
TINFO : Test #1: ADC record test. Headphone is need to check the voice and quality of recording.
TINFO : Audio TEST: Total 3 combinations of formats.
TINFO : No.[4] Now Recording audio stream with format S16_LE, channel 2,sample rate 48000
TFAIL: Audio Playback test fails in loop time 2
TFAIL: Test Failed on below file: audio48k24b2c_sle.pcm
TGE_LV_DAC2 1 TFAIL : ltpapicmd.c:188: Test FAIL
^CTFAIL: Test #1: Recording audio48k16b2c_sle.pcm Failed on hw:1,0
Recording raw data '/tmp/tmpfs/tmp.Nzsd3l5HpA/audio48k16b2c_sle.pcm' : Signed 16 bit Little Endian, Rate 48000 Hz, Stereo
Aborted by signal Interrupt...
^C^Caplay: no process found
arecord: no process found
root@imx8qmmek:~# ^C
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
IMXApplies to i.MX platformApplies to i.MX platformbugSomething isn't working as expectedSomething isn't working as expected
Activity
dai: correct the order for DAI and DMA start/stop
drivers: imx: sai: update start/stop operations
dai: correct the order for DAI and DMA start/stop
drivers: imx: sai: update start/stop operations
dai: correct the order for DAI and DMA start/stop
drivers: imx: sai: update start/stop operations
paulstelian97 commentedon Mar 16, 2021
Is this issue fixed?
iuliana-prodan commentedon Mar 16, 2021
Yes, fixed by #3867.
Another issue remains, after hundreds of playback/record we get:
But his will be handled in another issue.
paulstelian97 commentedon Mar 16, 2021
Just checked, sometimes issues are accidentally closed by merging of pull requests on GH (the "fixes" keyword does that)
lgirdwood commentedon Mar 16, 2021
@iuliana-prodan is this working in v1.7 ? @keyonjie has created a PR pulling all the fixes ready for final release ? so please let me know if anything is missing ?
iuliana-prodan commentedon Mar 16, 2021
@lgirdwood yes, is working on v1.7. But these patches are not included in @keyonjie PR #3914
Can I push these patches on #3914 or @keyonjie will update that PR?
lgirdwood commentedon Mar 16, 2021
@iuliana-prodan just send another PR with your patches for v1.7
dai: correct the order for DAI and DMA start/stop
drivers: imx: sai: update start/stop operations
dai: correct the order for DAI and DMA start/stop
drivers: imx: sai: update start/stop operations