soundwire: intel: Move suspend tracking from trigger to pm suspend#5711
Open
ujfalusi wants to merge 1 commit intothesofproject:topic/sof-devfrom
Open
soundwire: intel: Move suspend tracking from trigger to pm suspend#5711ujfalusi wants to merge 1 commit intothesofproject:topic/sof-devfrom
ujfalusi wants to merge 1 commit intothesofproject:topic/sof-devfrom
Conversation
Mark all open DAI runtimes as suspended in the component .suspend callback instead of relying on SNDRV_PCM_TRIGGER_SUSPEND, which is not delivered during PAUSE or xrun states. If during system suspend a dai is open it means that it is in either in SUSPENDED, PAUSED or STOPPED (due to xrun) state and they will need to be re-initialized during resume (which is done in .prepare callback). Signed-off-by: Peter Ujfalusi <peter.ujfalusi@linux.intel.com>
There was a problem hiding this comment.
Pull request overview
This PR updates SoundWire Intel ASoC DAI suspend tracking to no longer rely on SNDRV_PCM_TRIGGER_SUSPEND (which may be skipped for PAUSE/xrun scenarios), and instead marks open DAI runtimes as suspended from the component-level .suspend callback so resume reinitialization can consistently occur via .prepare().
Changes:
- Remove
SNDRV_PCM_TRIGGER_SUSPENDhandling from the DAI.trigger()path. - Mark all open DAI runtimes as
suspended = trueduring component suspend (new inintel_ace2x.c, simplified inintel.c).
Reviewed changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated no comments.
| File | Description |
|---|---|
| drivers/soundwire/intel_ace2x.c | Adds component .suspend callback to mark all open DAI runtimes suspended; removes trigger-based suspend tracking. |
| drivers/soundwire/intel.c | Removes trigger-based suspend tracking and simplifies component suspend logic to mark all open DAI runtimes suspended. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Mark all open DAI runtimes as suspended in the component .suspend callback instead of relying on SNDRV_PCM_TRIGGER_SUSPEND, which is not delivered during PAUSE or xrun states.
If during system suspend a dai is open it means that it is in either in SUSPENDED, PAUSED or STOPPED (due to xrun) state and they will need to be re-initialized during resume (which is done in .prepare callback).