[PATCH 6/9] ASoC: fsl: switch to use snd_soc_daifmt_parse_format/clock_provider()

Mark Brown broonie at kernel.org
Tue Jun 8 14:34:53 CEST 2021


On Tue, Jun 08, 2021 at 09:50:52AM +0200, Jerome Brunet wrote:

> I understand you are trying to fold some code but I'm not sure about this
> snd_soc_daifmt_clock_provider_pickup().

> Instead of repeating the if clause around DAIFMT (which is a bit verbose
> but fairly easy to understand and maintain) there is now the calculation
> of a made up constant (which is rather opaque as it is), which later
> translate to the same type of test around DAIFMT. 

> I'd be in favor of dropping the snd_soc_daifmt_clock_provider_pickup()
> part for the sake or readability. This apply to the rest of the series,
> not just fsl.

Yeah, I'm also just finding the _pickup() name unclear and can't really
immediately think how to make it clearer - I think the bit being
factored out needs to be at least as complex/unclear as the interface
being introduced to do so.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20210608/2a65b38c/attachment.sig>


More information about the Alsa-devel mailing list