Re: [PATCH v2 2/3] ASoC: codecs: Add support for the Renesas IDT821034 codec

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Mark,

On Fri, 20 Jan 2023 12:12:44 +0000
Mark Brown <broonie@xxxxxxxxxx> wrote:

> On Fri, Jan 20, 2023 at 10:50:35AM +0100, Herve Codina wrote:
> 
> > +static int idt821034_kctrl_gain_put(struct snd_kcontrol *kcontrol,
> > +				    struct snd_ctl_elem_value *ucontrol)
> > +{
> > +	struct soc_mixer_control *mc = (struct soc_mixer_control *)kcontrol->private_value;
> > +	struct snd_soc_component *component = snd_soc_kcontrol_component(kcontrol);
> > +	struct idt821034 *idt821034 = snd_soc_component_get_drvdata(component);
> > +	struct idt821034_amp *amp;  
> 
> > +
> > +	amp->gain = val;
> > +	ret = 0;
> > +end:
> > +	mutex_unlock(&idt821034->mutex);
> > +	return ret;  
> 
> _put() methods should return 1 if the value changed to generate
> events - if you use the mixer-test selftest it'll spot this and
> other issues for you.
> 

Thanks for pointing this. I will look at mixer-test and fix the _put()
methods return code in v3.

> Otherwise this looks fine.

Thanks for the review.

Best regards,
Hervé

-- 
Hervé Codina, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com




[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux