[alsa-devel] [PATCH V3 3/4] ASoC: SPEAr spdif_out: Add spdif out support

Mark Brown broonie at opensource.wolfsonmicro.com
Thu Jun 28 14:27:28 CEST 2012


On Thu, Jun 28, 2012 at 12:31:39PM +0530, Rajeev Kumar wrote:

> +	void *io_base;

Should be __iomem.  Looking at the code I suspect this might benefit
from using regmap like Tegra, you'd save having to open code your mute
control if nothing else.

> +static const struct snd_kcontrol_new spdif_out_controls[] = {
> +	SOC_SINGLE_BOOL_EXT("SPDIF Play Mute", (unsigned long)&spdif_out_mute,
> +			spdif_mute_get, spdif_mute_put),

Should be "IEC958 Playback Switch".

> +int spdif_soc_dai_probe(struct snd_soc_dai *dai)
> +{
> +	struct snd_soc_card *card = dai->card;
> +	struct snd_soc_pcm_runtime *rtd = card->rtd;
> +	struct snd_soc_codec *codec = rtd->codec;
> +
> +	return snd_soc_add_codec_controls(codec, spdif_out_controls,
> +				ARRAY_SIZE(spdif_out_controls));

We should add a framework thing for this...

> +	.ops = (struct snd_soc_dai_ops *)&spdif_out_dai_ops,

Why do you need this cast?
-------------- 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/20120628/062b7517/attachment.sig 


More information about the Alsa-devel mailing list