-
Notifications
You must be signed in to change notification settings - Fork 349
IPC4: fix for pipaline cleanup #5342
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
src/ipc/ipc4/helper.c
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tmleman can I ask you a question regarding the unbinding of modules, lets say you have a topology like this:

And pipeline 12 is stopped while pipeline 1 is still active. Should we unbind mixin12.1 and mixout.2.1 before pipeline 12 is deleted? Would it cause any issues because mixout.2.1 is in active state still?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I made some research and its was my mistake to assume that unbind of modules under the same pipeline should be normally processed.
Documentation informs that this operation should be ignored, so error reporting via IPC is also incorrect.
@RanderWang will returning 0 and adding a warning in the log will be enough?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@tmleman I didnt get what you mean by returning 0? in which case would be return 0? when 2 modules belong to different pipelines?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
return 0 instead of the error code as it has been done so far. Change is for case when modules belong to the same pipeline.
RanderWang
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested on windows. Is pipaline a typo ?
59001fc to
3cfae37
Compare
When both module instances are parts of the same pipeline Unbind IPC would be ignored by FW since FW does not support changing internal topology of pipeline during run-time. The only way to change pipeline topology is to delete the whole pipeline and create it in modified form. Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
During pipeline reset all components remains in previous state. This cause issue at pipeline deletion. This patch allowed to propagate state transition to all pipeline components. Signed-off-by: Tomasz Leman <tomasz.m.leman@intel.com>
3cfae37 to
84c53f2
Compare
|
CI showing known and unrelated issues. |
|
@tmleman for commit ipc4: fix pipeline reset I found a regression issue on windows. The problem is propagate_state_to_ppl_comp set component to reset and pipeline_reset will also set component to reset then a error will returned that the component is already set to reset. I want to know in which case pipeline_reset() can't set component to reset state ? It should set them to reset state and don't need to explicitly set it to reset ret = propagate_state_to_ppl_comp(ipc, id, COMP_TRIGGER_RESET);
if (ret != 0)
return ret;
/* resource is not released by triggering reset which is used by current FW */
ret = pipeline_reset(host->cd->pipeline, host->cd); |
|
@RanderWang function propagate_state_to_ppl_comp was added because pipeline_reset did not set reset state to pipeline components. If that has changed this function is no longer necessary. |
|
@tmleman do you have any test case for me to validate it ? thanks. If none, I will remove this function |
|
@RanderWang can you point to a change that changes the behavior of pipeline_reset? I can't find in history in which cases problem described on commit message was visible. |
|
@tmleman please check pipeline_reset function. I don't make any change but it should call comp_reset to set component state to reset. So I want to check your case to find why it doesn't work. |
|
@RanderWang earlier pipeline components was not set to RESET state and that caused error during pipeline delete. I don't see this behavior right now. My fault I didn't see pipeline_comp_reset. I think you can delete propagate_state_to_ppl_comp function. |
|
@tmleman thanks for your explanation. I will do it. |
Regularly used flow when removing pipeline:
Changes made: