Skip to content

topology2: add WebRTC HPF/AGC capture chaining, HDA AEC, and PTL targets - #11426

Draft
lgirdwood wants to merge 3 commits into
thesofproject:mainfrom
lgirdwood:topic/webrtc-pr2
Draft

lgirdwood wants to merge 3 commits into
thesofproject:mainfrom
lgirdwood:topic/webrtc-pr2

Conversation

@lgirdwood

Copy link
Copy Markdown
Member

Summary

Follow-up topology2 improvements for the WebRTC audio processing module suite (#11044, #11419):

  1. topology2: add missing direction attribute to capture pipelines

    • Add explicit direction "capture" to the pipeline."1" scheduler widget in dai-copier-eqiir-module-copier-capture.conf, host-gateway-capture.conf, and webrtc-{aec,ns,ns2}-capture.conf so the pipeline widget direction matches the enclosing capture pipeline class.
  2. topology2: cavs-mixin-mixout-hda: add WebRTC AEC capture support

    • Add an optional AEC_PROCESSING flag to cavs-mixin-mixout-hda.conf that inserts webrtc-aec.3.1 between module-copier.4.2 and host-copier.0.capture on the analog capture path, and register sof-hda-generic-webrtc-aec in development/tplg-targets.cmake.
  3. topology2: wire webrtc-hpf and webrtc-agc into capture and add PTL

    • Chain webrtc-hpf and webrtc-agc into webrtc-ns-capture.conf (dai-copier -> webrtc-hpf -> webrtc-vad -> webrtc-ns -> webrtc-agc -> host-copier) and add webrtc-hpf pre-filtering ahead of webrtc-ns2 in webrtc-ns2-capture.conf.
    • Add Panther Lake (PTL / ACE 3.0) development topology targets sof-ptl-nocodec-webrtc-{ns,ns2,aec} in development/tplg-targets.cmake.

Add explicit direction "capture" to the pipeline."1" scheduler widget in
dai-copier-eqiir-module-copier-capture.conf, host-gateway-capture.conf,
and webrtc-{aec,ns,ns2}-capture.conf so the pipeline widget direction
matches the enclosing capture pipeline class.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Add AEC_PROCESSING support to cavs-mixin-mixout-hda.conf to insert
webrtc-aec.3.1 into the HDA analog capture path (module-copier.4.2 ->
webrtc-aec.3.1 -> host-copier.0.capture) with runtime ALSA switch
controls ('Pre Mixer Analog Capture AEC Switch' and
'Pre Mixer Analog Capture AEC Suppression Switch').

Register the sof-hda-generic-webrtc-aec development topology target in
tplg-targets.cmake.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>
Instantiate webrtc-hpf (DC/<80 Hz removal) and webrtc-agc (digital gain
control and saturation limiter) in webrtc-ns-capture.conf alongside
webrtc-vad and webrtc-ns to form the complete WebRTC voice
pre-processing chain.

Add PTL nocodec topology targets (sof-ptl-nocodec-webrtc-{ns,aec,ns2})
in tplg-targets.cmake alongside the existing TGL targets.

Signed-off-by: Liam Girdwood <liam.r.girdwood@linux.intel.com>

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

🟡 Changes recommended

The HDA AEC lacks a playback-reference input needed to cancel speaker echo, and its default suppression control name exceeds ALSA topology’s 43-byte name limit.

2 open issues
What changed in this PR

This PR extends topology2’s WebRTC capture processing and adds development targets for HDA and Panther Lake.

Changes:

  • Sets explicit capture direction on five pipeline scheduler widgets.
  • Adds HPF and AGC stages to the existing VAD/NS capture chain.
  • Adds an optional HDA AEC capture path and registers HDA AEC and PTL WebRTC targets.
File Description
tools/​topology/​topology2/​include/​pipelines/​cavs/​webrtc-ns2-capture.conf Sets capture scheduler direction.
tools/​topology/​topology2/​include/​pipelines/​cavs/​webrtc-ns-capture.conf Adds HPF/AGC widgets and routes; sets capture direction.
tools/​topology/​topology2/​include/​pipelines/​cavs/​webrtc-aec-capture.conf Sets capture scheduler direction.
tools/​topology/​topology2/​include/​pipelines/​cavs/​host-gateway-capture.conf Sets capture scheduler direction.
tools/​topology/​topology2/​include/​pipelines/​cavs/​dai-copier-eqiir-module-copier-capture.conf Sets capture scheduler direction.
tools/​topology/​topology2/​development/​tplg-targets.cmake Registers PTL NS, NS2, and AEC targets plus HDA AEC.
tools/​topology/​topology2/​development/​cavs-nocodec-webrtc-ns.conf Updates comments and diagram for the expanded capture chain.
tools/​topology/​topology2/​cavs-mixin-mixout-hda.conf Adds optional AEC widget, controls, and analog capture routing.

Review effort: Balanced

Comment on lines +456 to +457
num_input_pins 1
num_input_audio_formats 1
name 'Pre Mixer $ANALOG_CAPTURE_PCM AEC Switch'
}
mixer."2" {
name 'Pre Mixer $ANALOG_CAPTURE_PCM AEC Suppression Switch'
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.

3 participants