Uh oh!
There was an error while loading. Please reload this page.
module: prepare sink & source in bind & unbind function - #8594
Conversation
marcinszkudlinski
left a comment
There was a problem hiding this comment.
Don't duplicate identical functionality - pointers to sink and sources are set twice, using identical code
remove module_adapter_sink_src_prepare from module adapter - consider applying d0bf41b together with this patch
2382968 to
f2dbad7CompareRanderWang
commented
Dec 8, 2023
@marcinszkudlinski Thanks, integrate your suggestion. |
f2dbad7 to
2cb6e3fCompareserhiy-katsyuba-intel
commented
Dec 8, 2023
Looks like CI reports problems with commits from this PR cherry-picked here #8576. On previous versions of this fix there were no such CI failures. |
lgirdwood
commented
Dec 8, 2023
@RanderWang we are getting a failure loading topology then a leak (which could be in testbench and NOT in pipeline). @andrula-song and @singalsu can you help here. |
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
kv2019i
commented
Dec 11, 2023
This looks good to go otherwise, but the testbench failure needs to be fixed. If it's a problem in testbench, we can have a fix in separate PR, but we need a rootcause before we can merge this. |
singalsu
commented
Dec 11, 2023
singalsu
commented
Dec 11, 2023
@RanderWang Does the SRC work in a normal IPC4 device with this PR? I'm not sure we have in CI test that runs a SRC pipeline. Looks that mod->num_of_sources and mod->num_of_sinks() are set after calling module_prepare() in module_adapter_dp_queue_prepare(). For testbench in module_adapter_prepare() the first if true is not taken because mod->dev->ipc_config.proc_domain is not COMP_PROCESSING_DOMAIN_DP. Then in the second else if the num_of_ arguments are zeros. |
2cb6e3f to
fec1eb1CompareRanderWang
commented
Dec 12, 2023
I tested SRC. but it is working LL mode not in DP mode |
RanderWang
commented
Dec 12, 2023
I also tested SRC in DP mode, but no issue found |
fec1eb1 to
87837d9Compare87837d9 to
58a5bfeCompareModule will update source & sink information when bind & unbind event happen. Signed-off-by: Rander Wang <rander.wang@intel.com>
58a5bfe to
bcedb1bComparesingalsu
commented
Dec 12, 2023
Thanks, then it looks like this is only issue for IPC3 or testbench. Can you check if adding for IPC3 build some of the removed num_of calculations fixes the test issue? In the above code snippet, for the else if call before calling module_prepare(). |
ipc4 They are done in bind & unbind(). But we need to keep it for ipc3. Signed-off-by: Marcin Szkudlinski <marcin.szkudlinski@intel.com> Signed-off-by: Rander Wang <rander.wang@intel.com>
bcedb1b to
47f4c21CompareRanderWang
commented
Dec 12, 2023
thanks, I got the same idea. IPC3 doesnt has bind & unbind |
kv2019i
commented
Dec 12, 2023
Looks better now, let's wait for the mandatory CI runs to complete and if all good, this is ready to be merged. |
kv2019i
commented
Dec 13, 2023
CI almost clean. I do see one fail here: Looks like a case of thesofproject/linux#4832 but triggered in a different test case. |
kv2019i
commented
Dec 13, 2023
@RanderWang Can you check the above fail? I browsed through history of PR tests and I don't see this failing for any other PR. |
RanderWang
commented
Dec 13, 2023
@kv2019i it was a old bug hard to be reproduced. Let run it again. [ 53.980498] <err>dai_comp: dai_common_new: comp:10x10004dai_new(): dai_get() failedtocreateDAI.
[ 53.980518] <err>copier: copier_dai_create: comp:10x10004failedtocreatedai |
RanderWang
commented
Dec 13, 2023
SOFCI TEST |
RanderWang
commented
Dec 14, 2023
@kv2019i pass. It is unlucky that it can't be reproduced again. |
After thesofproject#8594 been merged, sources and sinks are now setup on .bind() and .unbind(). Previously they were setup in .prepare(). However, there were code left in module_adapter_reset() which clears sources and sinks arrays. That broke some tests: modules which use source/sink API stopped working correctly after pipeline reset. Signed-off-by: Serhiy Katsyuba <serhiy.katsyuba@intel.com>
After #8594 been merged, sources and sinks are now setup on .bind() and .unbind(). Previously they were setup in .prepare(). However, there were code left in module_adapter_reset() which clears sources and sinks arrays. That broke some tests: modules which use source/sink API stopped working correctly after pipeline reset. Signed-off-by: Serhiy Katsyuba <serhiy.katsyuba@intel.com>
After #8594 been merged, sources and sinks are now setup on .bind() and .unbind(). Previously they were setup in .prepare(). However, there were code left in module_adapter_reset() which clears sources and sinks arrays. That broke some tests: modules which use source/sink API stopped working correctly after pipeline reset. Signed-off-by: Serhiy Katsyuba <serhiy.katsyuba@intel.com>

Module will update source & sink information when bind & unbind event happen.