Skip to content

audioreach-driver: Improve board-specific audio support and playback handling#65

Merged
quic-aditrath merged 3 commits into
AudioReach:masterfrom
mohsRafi:fix-glymur-b2b-playback
Jul 14, 2026
Merged

audioreach-driver: Improve board-specific audio support and playback handling#65
quic-aditrath merged 3 commits into
AudioReach:masterfrom
mohsRafi:fix-glymur-b2b-playback

Conversation

@mohsRafi

@mohsRafi mohsRafi commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

This change enhances the AudioReach machine driver infrastructure to better support board-specific audio configurations on Qualcomm platforms and fixes a playback mute/unmute issue observed on Glymur.
The current SC8280XP machine driver largely assumes a common audio topology across all boards. However, multiple products based on the same SoC integrate different external codecs, amplifiers, and audio paths, requiring board-specific configuration and clock management.
To address this, the series adds support for board-specific DAPM widgets and routes, enables MI2S clock control through the q6apm-lpass DAI layer, and allows machine drivers to configure external codec requirements such as MCLK programming. These changes provide a more flexible framework for supporting platforms with diverse audio hardware while keeping common AudioReach infrastructure reusable.
In addition, the series fixes a Glymur playback regression where speaker streams could remain muted after consecutive playback sessions. The mute/unmute handling is moved to DAPM event callbacks so that stream state remains synchronized with audio path power transitions, restoring reliable back-to-back playback.

Changes included:

  1. audioreach-driver: q6apm-lpass-dummy-dais: Add MI2S clock control.
    Add MI2S MCLK/BCLK/ECLK management through the DAI .set_sysclk callback.
    Retrieve clock handles from Device Tree for per-port configuration.
    Enable and disable clocks during stream startup and shutdown.

  2. audioreach-driver: Enhance machine driver for board-specific config.
    Add support for board-specific DAPM widgets and routes.
    Allow platform-specific audio topology descriptions.
    Add support for MI2S MCLK programming required by boards using external codecs.

  3. audioreach-driver: Fix Glymur playback mute/unmute handling.
    Move stream mute control to DAPM event handlers.
    Synchronize mute state with playback path power transitions.
    Fix speaker remaining muted after consecutive playback sessions.

Validated on Glymur-crd and RB3Gen2

@mohsRafi
mohsRafi requested review from a team July 9, 2026 07:59

@nandamajay nandamajay 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.

LGTM

mohsRafi added 3 commits July 14, 2026 12:02
Add support for MI2S clock control within q6apm-lpass DAIs, including
handling of MCLK, BCLK, and ECLK via the DAI .set_sysclk callback.
Each MI2S port now retrieves its clock handles from the device tree,
allowing per-port clock configuration and proper enable/disable during
startup and shutdown.

Signed-off-by: Mohammad Rafi Shaik <mohammad.rafi.shaik@oss.qualcomm.com>
The sc8280xp machine driver is currently written with a largely
SoC-centric view and assumes a uniform audio topology across all
boards. In practice, multiple products based on the same SoC use
different board designs and external audio components, which
require board-specific configuration to function correctly.

Several Qualcomm platforms like talos integrate third-party audio
codecs or use different external audio paths. These designs often
require additional configuration such as explicit MI2S MCLK
settings for audio to work.

This change enhances the sc8280xp machine driver to support
board-specific configuration such as allowing each board variant to
provide its own DAPM widgets and routes, reflecting the actual audio
components and connectors present and enabling MI2S MCLK programming
for boards that use external codecs requiring a stable master clock.

Signed-off-by: Mohammad Rafi Shaik <mohammad.rafi.shaik@oss.qualcomm.com>
Fix a back-to-back playback issue on Glymur where the speaker stream
remains muted after a previous playback session.

The existing mute handling is not synchronized with the DAPM power
state transitions, which can leave the audio path in an incorrect
state when streams are stopped and restarted in quick succession.

Resolve this by moving the mute/unmute stream control to DAPM event
handlers, ensuring the stream is unmuted when the playback path is
powered up and muted when the path is powered down.

This restores correct audio playback across consecutive playback.

Signed-off-by: Mohammad Rafi Shaik <mohammad.rafi.shaik@oss.qualcomm.com>
@mohsRafi
mohsRafi force-pushed the fix-glymur-b2b-playback branch from 84b718d to bc901df Compare July 14, 2026 06:34
@quic-aditrath
quic-aditrath merged commit 50d379e into AudioReach:master Jul 14, 2026
13 of 14 checks passed
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.

6 participants