Repository navigation
Closed
Labels
APLApplies to ApolloLake platformApplies to ApolloLake platformP2Critical bugs or normal featuresCritical bugs or normal featuresbugSomething isn't workingSomething isn't working
Description
Summary:
pcm_read error occurs when capturing with nocodec DMIC.
Test steps:
- arecord -l
**** List of CAPTURE Hardware Devices ****
card 0: sofnocodec [sof-nocodec], device 0: Port0 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 1: Port1 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 2: Port2 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 3: Port3 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 4: Port4 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 5: Port5 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
card 0: sofnocodec [sof-nocodec], device 6: DMIC01 (*) []
Subdevices: 1/1
Subdevice #0: subdevice #0
--
2. arecord -Dhw:0,6 -fS32_LE -c2 -r 48000 -vv -i /dev/null
Recording WAVE '/dev/null' : Signed 32 bit Little Endian, Rate 48000 Hz, Stereo
Hardware PCM card 0 'sof-nocodec' device 6 subdevice 0
Its setup is:
stream : CAPTURE
access : RW_INTERLEAVED
format : S32_LE
subformat : STD
channels : 2
rate : 48000
exact rate : 48000 (48000/1)
msbits : 32
buffer_size : 8064
period_size : 1920
period_time : 40000
tstamp_mode : NONE
tstamp_type : MONOTONIC
period_step : 1
avail_min : 1920
period_event : 0
start_threshold : 1
stop_threshold : 8064
silence_threshold: 0
silence_size : 0
boundary : 9079256848778919936
appl_ptr : 0
hw_ptr : 0
arecord: pcm_read:2103: read error: Input/output error
Test env:
sof master: 5838f71,73475e3f
sof tool: 2cd668c
kernel sof-dev: 9b81e16,165b34de
tplg: sof-apl-nocodec.tplg-2cd668c
Log:
dmesg-apl-dmic.log
logger-apl-dmic.log
logger-apl-t-dmic.log
Metadata
Metadata
Assignees
Labels
APLApplies to ApolloLake platformApplies to ApolloLake platformP2Critical bugs or normal featuresCritical bugs or normal featuresbugSomething isn't workingSomething isn't working
Activity
ranj063 commentedon Nov 13, 2018
@keyonjie @plbossart this is due to the added reserved bytes in struct sof_ipc_dai_dmic_params.
Removing the reserved bytes fixes the issue but I cant understand why it would fail in the first place.
ranj063 commentedon Nov 13, 2018
@mengdonglin @libinyang I already have a fix for this. I will submit a PR soon.
ranj063 commentedon Nov 13, 2018
@plbossart the issue is because of the bug in the incorrect dai_config during link_load() while parsing topology
plbossart commentedon Nov 13, 2018
@ranj063 sorry, what "incorrect dai_config" bug are you referring to?
ranj063 commentedon Nov 13, 2018
@plbossart this issue is specific to DMIC dai_config. But after sending the ipc to set the dai config in link_load(), the last step is to save the config for all dai's so it can be restored upon resuming from runtime suspend. At the moment only sizeof(struct sof_ipc_dai_config) bytes get copied. In the case of dmic, there are variable number of pdm controller configs making it larger than this size. I am still working on the PR to fix it. I will submit it soon.
plbossart commentedon Nov 14, 2018
please test and check PR283 fixes the issue.
plbossart commentedon Nov 17, 2018
@markyang can you please close this issue unless you still see a problem?
markyang commentedon Nov 19, 2018
Summary:
The issue cannot be reproduced any more.
driver core: Fix uevent_show() vs driver detach race
selftests/bpf: Add more ring buffer test coverage