lkml.org 
[lkml]   [2014]   [Nov]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [alsa-devel] [PATCH 1/2] ASoC: tfa9879: New driver for NXP Semiconductors TFA9879 amplifier.
On 11/06/2014 01:54 PM, Peter Rosin wrote:
[...]
> +#define TFA9879_REG(codec, reg, field, value) \
> + snd_soc_update_bits(codec, TFA9879_ ## reg, \
> + TFA9879_ ## field ## _MASK, \
> + (value) << TFA9879_ ## field ## _SHIFT)
> +

I'm not sure I like this macro. Just using snd_soc_update_bits should make
it easier to review the patch since people understand its sematnics.

[...]
> +static int tfa9879_probe(struct snd_soc_codec *codec)
> +{
> + struct tfa9879_priv *tfa9879 = snd_soc_codec_get_drvdata(codec);
> +
> + codec->control_data = tfa9879->regmap;

This is no longer necessary and won't even build with the latest ASoC tree.

> +
> + return 0;
> +}
> +
[...]
> +static struct snd_soc_dai_ops tfa9879_dai_ops = {

const

> + .prepare = tfa9879_prepare,
> + .hw_params = tfa9879_hw_params,
> + .shutdown = tfa9879_shutdown,
> + .digital_mute = tfa9879_digital_mute,
> + .set_fmt = tfa9879_set_fmt,
> +};
[...]



\
 
 \ /
  Last update: 2014-11-06 15:01    [W:0.069 / U:0.352 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site