Skip to content

[TEST] soundwire: stream: make sure peripheral is initialized before program it - #4572

Closed
bardliao wants to merge 1 commit into
thesofproject:topic/sof-devfrom
bardliao:sdw-stream
Closed

bardliao wants to merge 1 commit into
thesofproject:topic/sof-devfrom
bardliao:sdw-stream

Conversation

@bardliao

@bardliao bardliao commented Sep 6, 2023

Copy link
Copy Markdown
Collaborator

A peripheral may experience an unexpected unattach and attach cycle before a stream is prepared. It will fail to program registers if we try to program them before the peripheral is attached.

A peripheral may experience an unexpected unattach and attach cycle
before a stream is prepared. It will fail to program registers if we try
to program them before the peripheral is attached.

Signed-off-by: Bard Liao <yung-chuan.liao@linux.intel.com>

@plbossart plbossart left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this can work reliably @bardliao

return -ETIMEDOUT;
}
mutex_lock(&bus->bus_lock);

@plbossart plbossart Sep 6, 2023 •

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the problem is that the detach could perfectly happen while you already started programming the first port register. There's nothing that tells us when the codec will lose sync. So I will assert that the electrical parts need to be fixed, there's no reason why the de-attach should happen other than a bad link

@bardliao

Copy link
Copy Markdown
Collaborator Author

Let's focus on the reason of UNATTACHED

@bardliao bardliao closed this Sep 12, 2023
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.

2 participants