Skip to content

Conversation

@ranj063
Copy link
Collaborator

@ranj063 ranj063 commented Dec 16, 2019

This is a replacement for #1524.

Rename the enum sof_dsp_d0_substate to sof_dsp_power_state
and extend it to add the D3 state for the DSP.
Also, modify users of this enum to reflect the change.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Add the system_suspend_state field to struct snd_sof_dev
to track the intended system suspend power target. This will
be used as one of the criteria for determining the
final DSP power state.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
…me ops

Set the DSP power state in the platform-specific
suspend/resume op to make it transparent to the
top-level SOF device PM callbacks.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Add a helper to determine the target DSP power state.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Remove snd_sof_set_dsp_power_state() as it is no longer used.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
…tive

Add helper to determine if only D0i3-compatible streams are active.

Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
This patch implements support for DSP D0i3 when the system
is in S0. The basic idea is to schedule a delayed work after
every successful IPC TX that checks if there are only
D0I3-compatible streams active and if so transition
the DSP to D0i3.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Extend the set_power_state() op to specify if the trace
DMA should be enabled/disabled during D0i3.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
With the introduction of DSP D0I3 in S0, we need to
ensure that the DSP is in D0 before sending any new IPC's.
The exception fo this would be the PM_GATE IPC's that are
used to set the DSP in D0i3/D0 states. So, add a new helper
that can be used to send these IPC's without the need for
resuming the DSP if it is in D0i3.

Signed-off-by: Keyon Jie <yang.jie@linux.intel.com>
Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
@ranj063
Copy link
Collaborator Author

ranj063 commented Dec 16, 2019

@keyonjie I've opened this PR as a possible replacement for yours. I've taken the important bits needed from your PR into this as well. I did not take the ps_mutex bits because I couldnt convince myself that it is needed at all. Once you and I agree upon the solution we can take it to the others for review.

@ranj063 ranj063 closed this Dec 16, 2019
@ranj063 ranj063 deleted the fix/s0ix_work branch December 16, 2019 18:04
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.

1 participant