Skip to content

Conversation

@lyakh
Copy link
Collaborator

@lyakh lyakh commented Jan 6, 2026

Switch one of the two SRC instances in the nocodec topology to DP mode by default.

@softwarecki softwarecki self-requested a review January 7, 2026 14:31
@lgirdwood
Copy link
Member

@lyakh Some nocodec failings.

@lyakh
Copy link
Collaborator Author

lyakh commented Jan 8, 2026

@lyakh Some nocodec failings.

@lgirdwood yes, I've traced it back to an update in Zephyr, which had disabled double mapping. I'm working to fix it.

@lyakh lyakh marked this pull request as ready for review January 9, 2026 13:39
Copilot AI review requested due to automatic review settings January 9, 2026 13:39
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR switches the playback SRC (Sample Rate Converter) to use the DP (Data Processing) domain by default in the nocodec topology, while keeping the capture SRC in the default domain. Additionally, it adds cached memory partition support for DP scheduler tasks.

Key changes:

  • Splits the SRC domain configuration into separate playback and capture domains
  • Adds cached memory partition support (HEAP_CACHE and CFG_CACHE) for improved memory access patterns
  • Updates test topology parameters to maintain capture path DP testing

Reviewed changes

Copilot reviewed 4 out of 4 changed files in this pull request and generated no comments.

File Description
tools/topology/topology2/cavs-nocodec.conf Splits SRC_DOMAIN into SRC_DOMAIN_PLAYBACK (DP) and SRC_DOMAIN_CAPTURE (default) and updates widget configurations
tools/topology/topology2/development/tplg-targets.cmake Updates test topology parameters from SRC_DOMAIN to SRC_DOMAIN_CAPTURE for MTL, LNL, and PTL platforms
src/schedule/zephyr_dp_schedule_application.c Adds cached memory partition initialization and cleanup for both heap and mailbox partitions
src/schedule/zephyr_dp_schedule.h Extends the sof_dp_part_type enum with HEAP_CACHE and CFG_CACHE partition types

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@lyakh lyakh added the DNM Do Not Merge tag label Jan 9, 2026
@lyakh
Copy link
Collaborator Author

lyakh commented Jan 12, 2026

SOFCI TEST

@lyakh
Copy link
Collaborator Author

lyakh commented Jan 12, 2026

retest with #10474 merged

@lyakh
Copy link
Collaborator Author

lyakh commented Jan 12, 2026

SOFCI TEST

@lyakh
Copy link
Collaborator Author

lyakh commented Jan 14, 2026

SOFCI TEST

@lyakh lyakh force-pushed the tplg branch 3 times, most recently from b653aa5 to 1f3c6ed Compare January 22, 2026 09:40
@lyakh
Copy link
Collaborator Author

lyakh commented Jan 22, 2026

SOFCI TEST

CONFIG_MM_DRV_INTEL_VIRTUAL_REGION_COUNT=2
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=38400000
CONFIG_SYS_CLOCK_TICKS_PER_SEC=12000
CONFIG_ACE_V1X_RTC_COUNTER=n
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I assume this is disabled only for test.

zephyrproject-rtos/zephyr#103465 should be merged very soon and this will not be needed

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I've asked for this to be prioritized since its tainting CI results.

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@lyakh lets remove this conf change as we can rebase with the west fix for above Zephyr fix.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

but do we need that driver? If we don't need it anyway, why include it?

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not critical feature but it is actually used in intel base_fw.

Someone made a regression in zephyr and it just needs to be fixed, luckily it's easy

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Not critical feature but it is actually used in intel base_fw.

@abonislawski interesting, disabling it still passed all the tests. Could you point out where exactly it's used? Maybe we need to add a test for it

@lyakh
Copy link
Collaborator Author

lyakh commented Feb 6, 2026

lyakh added 4 commits February 6, 2026 10:52
Since Zephyr has removed double mapping per Kconfig switch we need to
restore it in SOF. Next we should try to optimize mappings to only
use the ones we really need.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
DP tasks don't need to be rescheduled when pause is released. Default
handling works correctly in that case too.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
We compare flags on repeated allocations from an existing pool, but
initialisation got forgotten in the process. Restore it.

Fixes: d6e6ac5 ("Add a object pool allocator")
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
When an objpool allocation fails an error should be returned. Fix the
missing error code assignment.

Fixes: fc73f9d ("sp: application: switch memory domains to object pools")
Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
@lyakh
Copy link
Collaborator Author

lyakh commented Feb 6, 2026

d263649 reverted because of a regression in SRC DP:

[  280.863861] <wrn> module_adapter: module_ext_init_decode: dp_data object too small 12 < 20
[  280.864021] <wrn> module_adapter: z_impl_mod_alloc_ext: mngr (nil) != cur 0x401907d0
[  280.865958] <inf> dp_schedule: dp_thread_fn: comp:0 0x100f userspace thread started
[  280.866228] <err> src_init: comp:0 0x100f Missing or bad size (44) init data
[  280.866368] <err> module_adapter: module_init: comp:0 0x100f error -22: module specific init failed
[  280.866446] <err> module_adapter: module_adapter_new_ext: comp:0 0x100f -22: module initialization failed
[  280.866905] <err> module_adapter: z_impl_mod_free: comp:0 0x100f error: could not find memory pointed by 0x40204380
[  280.867976] <err> ipc: ipc4_init_module_instance: error: failed to init module 100f : 0
[  280.868035] <err> ipc: ipc_cmd: ipc4: MODULE_MSG failed with err 104

https://sof-ci.01.org/sofpr/PR10469/build19047/devicetest/index.html?model=PTLH_RVP_NOCODEC&testcase=check-playback-10sec

A recent module-adapter feature addition broke SRC DP support. Fix it
by adding a test for incomplete initialization data.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
@lyakh
Copy link
Collaborator Author

lyakh commented Feb 6, 2026

SOFCI TEST

@lyakh
Copy link
Collaborator Author

lyakh commented Feb 6, 2026

nocodec PTL missing. rerun

@lgirdwood
Copy link
Member

nocodec PTL missing. rerun

Results in with some data about the failure. https://sof-ci.01.org/sofpr/PR10469/build19078/devicetest/index.html?model=PTLH_RVP_NOCODEC&testcase=check-capture-3times

@lyakh lyakh force-pushed the tplg branch 2 times, most recently from 2f076d8 to b0263bd Compare February 10, 2026 11:28
This reverts commit 8acc9ca. It
seems to break certain capture flows, revert it until fixed.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Userspace modules should only call mod_fast_get() and mod_fast_put(),
which already can cross into the kernel space on their own, so
fast_get() and fast_put() themselves don't need to be syscalls.
Remove their syscall implementations.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
fast_get.c doesn't have a "trace context" - it doesn't have a
DECLARE_TR_CTX() call. Hencs all calls to tr_err() and friends are
wrong. Replace them with respective LOG_*() analogs.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
If a module fast-gets memory for a specific its instance, running in
userspace and then another usuerspace instance wants to share it,
access has to be granted to that object by that thread too. This
patch does that while also restricting object sharing to "large"
objects (currently larger than half a page), and smaller objects are
just copied.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
Switch both SRC instances in the nocodec topology on PTL to DP mode
by default.

Signed-off-by: Guennadi Liakhovetski <guennadi.liakhovetski@linux.intel.com>
@lgirdwood lgirdwood dismissed softwarecki’s stale review February 10, 2026 15:52

Old review from earlier version of PR. PR changed, updates for FLIX and alignment was reached to maintain the review history over splitting PR to re-review.

@lgirdwood lgirdwood merged commit 73c9684 into thesofproject:main Feb 10, 2026
49 of 52 checks passed
@lyakh lyakh deleted the tplg branch February 10, 2026 15:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants