[PATCH 01/10] ASoC: codecs: va-macro: add runtime pm support
Mark Brown
broonie at kernel.org
Mon Feb 21 16:24:45 CET 2022
On Mon, Feb 21, 2022 at 01:10:28PM +0000, Srinivas Kandagatla wrote:
> +static int __maybe_unused va_macro_runtime_resume(struct device *dev)
> +{
> + struct va_macro *va = dev_get_drvdata(dev);
> +
> + clk_prepare_enable(va->clks[2].clk);
This magic number stuff is going to be excessively fragile, and the fact
that this is sometimes managed via the bulk APIs and sometimes not isn't
going to help either. Either all the clocks should be managed here or
this should be pulled out of the array.
Also consider error checking.
-------------- 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/20220221/5b111c9a/attachment-0001.sig>
More information about the Alsa-devel
mailing list