[alsa-devel] [PATCH 03/11] ASoC: core: Add widget SND_SOC_DAPM_CLOCK_SUPPLY
Mark Brown
broonie at opensource.wolfsonmicro.com
Tue May 8 17:40:28 CEST 2012
On Tue, May 08, 2012 at 03:56:40PM +0200, Ola Lilja wrote:
> +{
> + if (SND_SOC_DAPM_EVENT_ON(event))
> + return clk_enable(w->priv);
> + else {
> + clk_disable(w->priv);
> + return 0;
Coding style - you need more { }. This also all needs to be
conditionally complied for the many platforms that don't provide the
clock API.
> + case snd_soc_dapm_clock_supply:
> + w->priv = (w->shift) ? clk_get_sys(w->name, NULL) :
> + clk_get(dapm->dev, w->name);
I don't think supporting clk_get_sys() is a particularly good idea
here... Also, I think Liam was wanting to add per-user data to the
widget rather than reuse the priv pointer.
> + /**
> + * snd_soc_dapm_get_power_status - get widget power status
> + * @dapm: DAPM context
> + * @pin: Widget name
> + *
> + * Get widget power status - Enabled or disabled.
> + *
> + * Returns -1 for failure.
> + * Returns 0 if disabled.
> + * Returns 1 if enabled.
> + */
> +int snd_soc_dapm_get_power_status(struct snd_soc_dapm_context *dapm,
> + const char *pin)
This appears to be *nothing* to do with the rest of the patch! It's
also not clear what it's for.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 836 bytes
Desc: Digital signature
Url : http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20120508/846038a8/attachment.sig
More information about the Alsa-devel
mailing list