Skip to content

Conversation

@keqiaozhang
Copy link
Contributor

Signed-off-by: Keqiao Zhang keqiao.zhang@intel.com

miRoox
miRoox previously requested changes Dec 9, 2022
Copy link
Contributor

@miRoox miRoox left a comment

Choose a reason for hiding this comment

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

Why don't we ignore the difference between IPC3/IPC4, like trimming the model name to exclude the 4th part?

@keqiaozhang
Copy link
Contributor Author

Why don't we ignore the difference between IPC3/IPC4, like trimming the model name to exclude the 4th part?

Because the tplgs are different, so the volume control names are different between IPC3 and IPC4.
IPC3 volume control names are: PGA7.0 7 Master ....
IPC4 volume control names are: gain. ..

@miRoox miRoox dismissed their stale review December 9, 2022 08:53

I don't like this solution, but it's acceptable for me.

@plbossart
Copy link
Member

@ranj063 I think most of the settings will have to be changed with your topology cleanups, no?

@keqiaozhang
Copy link
Contributor Author

@ranj063 , please help to confirm if we need to change the amixer setting after your topology cleanups?

@ranj063
Copy link
Contributor

ranj063 commented Dec 19, 2022

@ranj063 , please help to confirm if we need to change the amixer setting after your topology cleanups?

@keqiaozhang @plbossart , Im going to punt this to @jsarha. He's working on cleaning up the mixer names.

EDIT:

Signed-off-by: Keqiao Zhang <keqiao.zhang@intel.com>
@keqiaozhang
Copy link
Contributor Author

I have verified this patch with PR991, the results are as expected:https://sof-ci.sh.intel.com/#/result/planresultdetail/19443

image

@keqiaozhang
Copy link
Contributor Author

@aiChaoSONG please help to review this PR, since we have enabled alsabat test on all our IPC4 platforms, so we need this PR to set the amixer settings before the test. This PR is well tested.

amixer -c sofnocodec cset name='gain.3.1 Playback Volume 3' 45
amixer -c sofnocodec cset name='gain.4.1 Main Playback Volume 4' 45
amixer -c sofnocodec cset name='gain.5.1 Playback Volume 5' 45
amixer -c sofnocodec cset name='gain.6.1 Main Playback Volume 6' 45
Copy link
Member

Choose a reason for hiding this comment

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

Can you remind me why we should care about the volume settings in the firmware? This should be 0dB by default, always. the way this is implemented will break for every topology change or rename of controls.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Yes, the default volume should be 0dB, but we cannot ensure that these volumes will not be modified before testing alsabat.

Copy link
Collaborator

Choose a reason for hiding this comment

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

@keqiaozhang you mean because other tests may change them? Why?

I've seen a large number of discussions about ALSA settings and UCM for a few years now and I still don't know how the "ideal state" should look like. Exceptions and quirks are sometimes necessary but I still can't tell what is a quirk versus what is a Good Thing. Is this already documented somewhere or would a new https://github.com/thesofproject/sof-test/discussions help?

Copy link
Member

Choose a reason for hiding this comment

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

Yes, the default volume should be 0dB, but we cannot ensure that these volumes will not be modified before testing alsabat.

then use a script to find all gain/PGA for the firmware using regexps and reset the value separately from codec stuff.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

then use a script to find all gain/PGA for the firmware using regexps and reset the value separately from codec stuff

Can we merge this PR first? I will try your suggestion next. It's not only related to volume, but also related to switch.

Copy link
Collaborator

Choose a reason for hiding this comment

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

then use a script to find all gain/PGA for the firmware using regexps and reset the value separately from codec stuff.

@keqiaozhang is this what you're trying to do in #1010?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@keqiaozhang is this what you're trying to do in #1010?

Yes, I'm working on it.

@keqiaozhang
Copy link
Contributor Author

Closing. New PR:#1012

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.

6 participants