Skip to content

Conversation

@shumingfan
Copy link

@shumingfan shumingfan commented Oct 21, 2022

Add BQ params into the device property at the machine driver level, then the codec driver will get the BQ params and apply them.
The Dell XPS 17 9710 model needs the BQ params for the tweeter/woofer.
Issue #3896

Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

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

thanks @shumingfan, I have a couple of nit-picks but also concerns on the error flows, see below.

Copy link
Member

Choose a reason for hiding this comment

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

u16

@shumingfan
Copy link
Author

thanks @shumingfan, I have a couple of nit-picks but also concerns on the error flows, see below.

@plbossart Thanks for your review, I will update the PR.

@shumingfan shumingfan force-pushed the fix-rt1308-distorted-sound branch from 16aed2d to f94c98f Compare October 24, 2022 07:11
@shumingfan shumingfan force-pushed the fix-rt1308-distorted-sound branch from f94c98f to 7e15a7d Compare October 24, 2022 08:55
plbossart
plbossart previously approved these changes Oct 24, 2022
Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

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

looks good @shumingfan, now we need to do this for all other SKUs with 4 speakers...

Copy link
Member

Choose a reason for hiding this comment

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

nit-pick: I would have used u8 for consistency with the device property definition but that works.

Copy link
Member

Choose a reason for hiding this comment

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

also maybe move this table to a new file which will only contain coefficients. The C file should be more about the programming sequences, the binary data should be in a separate file IMHO.

Copy link
Author

Choose a reason for hiding this comment

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

Sure, will move it to a separate .h file.

RanderWang
RanderWang previously approved these changes Oct 25, 2022
@shumingfan
Copy link
Author

looks good @shumingfan, now we need to do this for all other SKUs with 4 speakers...

@plbossart I will collect the information from our hardware engineer. If other models need to set BQ parameters, I will add them to PR.

@shumingfan shumingfan dismissed stale reviews from RanderWang and plbossart via b40a1a7 October 27, 2022 10:09
@shumingfan shumingfan force-pushed the fix-rt1308-distorted-sound branch from 7e15a7d to b40a1a7 Compare October 27, 2022 10:09
@shumingfan shumingfan changed the title fixup! ASoC: sof_sdw_rt1308/rt1308-sdw: fix distorted sound fixup! ASoC: sof_sdw_rt1308/sof_sdw_rt1316/rt1308-sdw/rt1316-sdw: fix distorted sound Oct 27, 2022
@shumingfan
Copy link
Author

@plbossart I got the settings of all 4-speakers cases from the Windows team. Some models don't have BQ parameters.
However, the rest of the models of rt1308 having BQ parameters have the same parameters. The same situation happened to rt1316. The hardware engineer said those models use the same speaker design.

@plbossart
Copy link
Member

@plbossart I got the settings of all 4-speakers cases from the Windows team. Some models don't have BQ parameters. However, the rest of the models of rt1308 having BQ parameters have the same parameters. The same situation happened to rt1316. The hardware engineer said those models use the same speaker design.

Makes sense, and that makes our life simpler, we just need to add the quirks for the relevant skus and point to the same table. Thanks for looking into this!

@shumingfan shumingfan force-pushed the fix-rt1308-distorted-sound branch from b40a1a7 to dec7140 Compare October 28, 2022 03:04
RanderWang
RanderWang previously approved these changes Oct 28, 2022
Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

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

Missing SKUs @shumingfan ?

Copy link
Member

Choose a reason for hiding this comment

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

this list needs to be aligned with what we already have in sof_sdw.c, e.g. 0AFF is not listed here.

Copy link
Author

@shumingfan shumingfan Nov 1, 2022

Choose a reason for hiding this comment

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

@plbossart I got the list from the agents. The 0AFF is used in the ADL platform and the model name is Stradale ADL.
The 0BDA/0BDB should be new models. They are used in the RPL platform and the model name is Stradale RPL.
If you want to remove those models for now, it will be ok for me.

Copy link
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 that's quite right @shumingfan, we have not added any RPL devices just yet. @gongjun-song is working on RPL support with PR #3978

Copy link
Author

Choose a reason for hiding this comment

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

@plbossart Yeah, I know. I just follow the list information and the settings of the Windows driver to add those models.
The agents give me the latest list and the Windows team goes faster than Linux.

If the machine driver level sets the BQ params into the device property,
the codec driver will get the BQ params and apply them.

Signed-off-by: Shuming Fan <shumingf@realtek.com>
If the machine driver level sets the BQ params into the device property,
the codec driver will get the BQ params and apply them.

Signed-off-by: Shuming Fan <shumingf@realtek.com>
The Dell SKU 0A5D/0A5E/0990/098F model needs the BQ params for the tweeter/woofer.

Signed-off-by: Shuming Fan <shumingf@realtek.com>
The Dell SKU 0B00/0B01/0AFE/0AFF model needs the BQ params for the tweeter/woofer.

Signed-off-by: Shuming Fan <shumingf@realtek.com>
@shumingfan shumingfan force-pushed the fix-rt1308-distorted-sound branch from 3762b34 to 43a60be Compare November 3, 2022 06:07
Copy link
Member

@plbossart plbossart left a comment

Choose a reason for hiding this comment

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

LGTM @shumingfan can you send this upstream? Feel free to add my

Reviewed-by: Pierre-Louis Bossart pierre-louis.bossart@linux.intel.com

@plbossart
Copy link
Member

closing, this should go upstream now

@plbossart plbossart closed this Nov 9, 2022
@shumingfan
Copy link
Author

LGTM @shumingfan can you send this upstream? Feel free to add my

Reviewed-by: Pierre-Louis Bossart pierre-louis.bossart@linux.intel.com

@plbossart OK, thanks. I will send this upstream today.

@JuanFcoMiranda
Copy link

Hi, how could I apply this patch? I tried copying only the modifications and also downloading the modified files but when I compile my kernel, it always fails.

Thanks in advance.

@plbossart
Copy link
Member

?? The code is upstream now:

1b435e4 ASoC: Intel: sof_sdw_rt1308: add BQ params for the Dell models
3c46b58 ASoC: rt1316-sdw: get BQ params property and apply them
5efb40b ASoC: rt1308-sdw: get BQ params property and apply them
f0c4d9f (tag: v6.1-rc4) Linux 6.1-rc4

@shumingfan shumingfan deleted the fix-rt1308-distorted-sound branch December 13, 2022 05:36
@JuanFcoMiranda
Copy link

JuanFcoMiranda commented Dec 13, 2022

Has it already been published? On which version of the kernel?

@plbossart
Copy link
Member

@JuanFcoMiranda I am not sure what you mean by "published", all patches first go to the ASoC maintainer tree, and they will flow into Linus Torvalds' tree during the merge window. this patch will be in 6.2 which will tentatively be released in 10 weeks or so.

@JuanFcoMiranda
Copy link

@plbossart I was meant when it would be available in the final release of the kernel. I'll be waiting for that version.

Thank you very much.

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