Repository navigation
Conversation
ranj063
force-pushed
the
sof-dev-081023
branch
2 times, most recently
from
February 14, 2024 23:12
7b67a91 to
c805c20
Compare
ranj063
force-pushed
the
sof-dev-081023
branch
4 times, most recently
from
February 15, 2024 14:04
79beba5 to
c2be407
Compare
Collaborator
Author
|
SOFCI TEST |
ranj063
force-pushed
the
sof-dev-081023
branch
13 times, most recently
from
February 16, 2024 01:53
e874c07 to
eb60f8a
Compare
plbossart
reviewed
Feb 16, 2024
| int i; | ||
|
|
||
| for (i = 0; i < SOF_IPC4_DMA_DEVICE_MAX_COUNT; i++) { | ||
| if (!blob->alh_cfg.mapping[i].device) { |
Collaborator
Author
There was a problem hiding this comment.
yeah I need to think about where to reset it but in my defense, the original code never reset it either just overwrote it
ranj063
force-pushed
the
sof-dev-081023
branch
from
February 16, 2024 02:27
eb60f8a to
54818ce
Compare
plbossart
reviewed
Feb 16, 2024
| blob->alh_cfg.mapping[i].device = | ||
| copier_data->gtw_cfg.node_id; | ||
| blob->alh_cfg.mapping[i].device |= | ||
| SOF_IPC4_NODE_INDEX(data->dai_node_id); |
Member
There was a problem hiding this comment.
@ranj063 this won't work for LNL+ , see line 1725. 54818ce#diff-694481cfb73dd1682c248c54855215595dc96ca4ee65b1d3ef9cdc4a478158e0R1725
maybe it's just simpler to save the dai_node_id somewhere and reset the node_id in the unprepare?
Collaborator
Author
There was a problem hiding this comment.
@plbossart I changed the logic to save the ALH dai index during hw_params instead. Hopefully this is a better solution
ranj063
force-pushed
the
sof-dev-081023
branch
3 times, most recently
from
February 16, 2024 06:02
c2b3718 to
a0043a3
Compare
Make sure to stop the DMA and stop/reset the pipelines during the stop trigger for IPC4. In the case of IPC4, pipelines must be paused before they are reset. So, add a post_trigger op in struct sof_pcm_ops that can be called after stopping the DMA to reset the pipelines. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Add a state variable to keep track of whether a stream is previously stopped. It is meant to be set only if the post-trigger op is also set. This patch should be iso-functionality, possibly removing no-op cases. The main purpose of this new state variable is to prepare a follow-up patch to reset all PCM and DMAs in case of stop/prepare xrun sequences. Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com> Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
Just stopping the DMA and resetting the pipelines during stop isn't enough in the case of xruns. So, reset the DMA and free all widgets to start over from a clean state. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
When an xrun happens, the BE DAI hw_params doesn't get invoked before the stream restarts with a prepare. In this case, clearing the node ID when the DAI widget is freed and unprepared will result in an error when it is re-initialized. In order to avoid this, bring back the free_stream ops for ACE1x platforms and move the code to clear the node ID to this op to keep it balanced with the BE DAI hw_params. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
The node_id for multi-gateway ALH DAI's get overwritten with the group_id during the DAI copier's ipc_prepare op. So, save the ALH dai_index during the BE DAI hw_params in the dai_index field of struct ipc4_copier and use that to set the device ID in the configuration blob. This will avoid errors during copier init after an xrun. Signed-off-by: Ranjani Sridharan <ranjani.sridharan@linux.intel.com>
ranj063
force-pushed
the
sof-dev-081023
branch
from
February 16, 2024 16:15
a0043a3 to
0b6c36d
Compare
Collaborator
Author
|
closing this in favor of #4816 |
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.
Instead of pausing the DMA during stop trigger for IPC4 and leaving the pipelines in the paused state, always stop the DMA and reset the pipelines so that they can be restarted cleanly during a prepare/start in case of xruns.