Skip to content

[TEST] [RFC] ASoC: SOF: Intel: hda-ctrl: add reset cycle before parsing capabilities - #1354

Closed
plbossart wants to merge 1 commit into
thesofproject:topic/sof-devfrom
plbossart:fix/hda_caps_parsing
Closed

plbossart wants to merge 1 commit into
thesofproject:topic/sof-devfrom
plbossart:fix/hda_caps_parsing

Conversation

@plbossart

Copy link
Copy Markdown
Member

Without this cycle, HDaudio capability parsing fails on some SoundWire-enabled devices.

We are not sure if this sequence is required or not, but it's definitively used by the Skylake driver which successfully parses these capabilities.

Adding as a test to see if this patch has any side effects on existing devices. It would be really nice if people can test on additional devices not covered by CI.

Without this cycle, HDaudio capability parsing fails on some devices.

Signed-off-by: Pierre-Louis Bossart <pierre-louis.bossart@linux.intel.com>
@ranj063

ranj063 commented Oct 22, 2019

Copy link
Copy Markdown
Collaborator

@plbossart the logic makes sense but how about moving hda_dsp_ctrl_get_caps() to after the controller init in hda_init_caps()?

@plbossart

Copy link
Copy Markdown
Member Author

@plbossart the logic makes sense but how about moving hda_dsp_ctrl_get_caps() to after the controller init in hda_init_caps()?

I thought about it, but the first thing hda_init_caps() does is to check the bus->ppcap, which is precisely set by hda_dsp_ctrl_get_caps()...

What we could do is split hda_dsp_ctrl_init_chip in two, and do the reset before reading the capabilities, but then we'll have questions on his_dsp_ctrl_misc_clock_gating() - not sure when it's needed or not.

@ranj063

ranj063 commented Oct 22, 2019

Copy link
Copy Markdown
Collaborator

I thought about it, but the first thing hda_init_caps() does is to check the bus->ppcap, which is precisely set by hda_dsp_ctrl_get_caps()...

@plbossart yes but the check does nothing if it is not there?

@plbossart

Copy link
Copy Markdown
Member Author

I thought about it, but the first thing hda_init_caps() does is to check the bus->ppcap, which is precisely set by hda_dsp_ctrl_get_caps()...

@plbossart yes but the check does nothing if it is not there?

Indeed, I missed this.
I don't have a clue what "PP capability, will probe DSP later" is supposed to mean and what the expected flow was. That looks like historical comments from @lgirdwood and @keyonjie

@ranj063

ranj063 commented Oct 22, 2019

Copy link
Copy Markdown
Collaborator

I don't have a clue what "PP capability, will probe DSP later" is supposed to mean and what the expected flow was. That looks like historical comments from @lgirdwood and @keyonjie

@plbossart this comment is stale now I think. In the skylake driver, the bus->ppcap is used to check if the DSP capability exists and then only go on to load the firmware. But in the case of SOF, we dont quite seem to do that. Irrespective of whether this is set or not, we go on and load the firmware anyway.

@bardliao bardliao left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

This looks good to me. It is the minimal change for now.

@kv2019i kv2019i left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

Looks good!

@plbossart

Copy link
Copy Markdown
Member Author

closing, will resubmit when we have better information on the hardware needs

@plbossart plbossart closed this Dec 7, 2019
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.

4 participants