Skip to content

Conversation

@singalsu
Copy link
Collaborator

No description provided.

If DMIC0_DEEP_BUFFER is defined as true in topology build
a deep buffer capture PCM is branched from module copier
in DMIC0 capture pipeline.

The patch adds a pipeline class deepbuffer-capture.conf and
a topology .conf snippet dmic-deep-buffer.conf that is
conditionally included from dmic-generic.conf.

Signed-off-by: Seppo Ingalsuo <[email protected]>
This patch adds build of these development topologies:

- sof-hda-generic-2ch-dmicdeepbuf.tplg
- sof-hda-generic-4ch-dmicdeepbuf.tplg
- sof-ptl-rt721-4ch-dmicdeepbuf.tplg

Signed-off-by: Seppo Ingalsuo <[email protected]>
@singalsu singalsu force-pushed the add_dmic0_deepbuffer_capture branch from e069a7b to 2667a94 Compare November 27, 2025 12:01
@lgirdwood
Copy link
Member

@singalsu LGTM so far, do we need any kernel PRs to be merged ?

@singalsu
Copy link
Collaborator Author

singalsu commented Dec 1, 2025

@singalsu LGTM so far, do we need any kernel PRs to be merged ?

Yes, there is thesofproject/linux#5605 .

Unfortunately there are glitches in capture about every 50 ms that need to be investigated. It's unlikely that the problem is in these PR's content but possibly a FW bug. There's some control code logic in host-copier for deep buffer playback DMA reload and might be that the rules are not suitable for capture as such.

@singalsu singalsu marked this pull request as ready for review December 12, 2025 17:31
Copilot AI review requested due to automatic review settings December 12, 2025 17:31
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 adds deep buffer capture support for DMIC (Digital Microphone) devices. Deep buffer capture enables larger buffer sizes to reduce DMA interrupts and improve power efficiency during audio capture operations.

Key changes:

  • Introduces a new deepbuffer-capture pipeline configuration for DMIC devices
  • Adds configuration options to enable/disable deep buffer capture via the DMIC0_DEEP_BUFFER flag
  • Creates topology targets for testing deep buffer DMIC configurations

Reviewed changes

Copilot reviewed 7 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
tools/topology/topology2/sof-hda-generic.conf Includes the new deepbuffer-capture configuration file
tools/topology/topology2/platform/intel/dmic-generic.conf Adds conditional include for DMIC deep buffer configuration
tools/topology/topology2/platform/intel/dmic-default.conf Defines default values for deep buffer capture parameters
tools/topology/topology2/platform/intel/dmic-deep-buffer.conf Implements the DMIC deep buffer pipeline, PCM device, and routing configuration
tools/topology/topology2/include/pipelines/cavs/deepbuffer-capture.conf Defines the reusable deepbuffer-capture pipeline class with audio format configurations
tools/topology/topology2/development/tplg-targets.cmake Adds build targets for testing DMIC deep buffer configurations
tools/topology/topology2/cavs-sdw.conf Includes the deepbuffer-capture configuration for SoundWire platforms

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

}
]
Object.Base.route [
{
Copy link

Copilot AI Dec 12, 2025

Choose a reason for hiding this comment

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

The route configuration references 'module-copier.$DMIC0_DAI_PIPELINE_ID.2' but there is no comment explaining what the '.2' suffix represents or why this specific instance is used. Adding a brief comment would improve maintainability.

Suggested change
{
{
# The '.2' suffix refers to the second instance of the module-copier for this pipeline,
# which is used for deep buffer capture in the DMIC pipeline.

Copilot uses AI. Check for mistakes.
Copy link
Member

@lgirdwood lgirdwood left a comment

Choose a reason for hiding this comment

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

LGTM, but lets wait for kernel patch to get merged 1st as we could have to revisit teh topology if kernel need fixes.

# Deep buffer capture
DMIC0_DEEP_BUFFER_PCM_NAME "DMIC Deep Buffer"
DMIC0_DEEP_BUFFER_PIPELINE_ID 18
DMIC0_DEEP_BUFFER_PCM_ID 46
Copy link
Member

Choose a reason for hiding this comment

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

Longterm, do we have a topology file that lists all PCM IDs ? Not a blocker now.

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.

2 participants