Re: [PATCH v4] ASoC: Add MediaTek MT6660 Speaker Amp Driver

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

 



On Thu, 09 Jan 2020 18:18:36 +0100,
Sriram Periyasamy wrote:
> 
> On Tue, Jan 07, 2020 at 11:09:05AM +0800, Jeff Chang wrote:
> > From: Jeff Chang <jeff_chang@xxxxxxxxxxx>
> > 
> > The MT6660 is a boosted BTL class-D amplifier with V/I sensing.
> > A built-in DC-DC step-up converter is used to provide efficient
> > power for class-D amplifier with multi-level class-G operation.
> > The digital audio interface supports I2S, left-justified,
> > right-justified, TDM and DSP A/B format for audio in with a data
> > out used for chip information like voltage sense and current
> > sense, which are able to be monitored via DATAO through proper
> > 
> > diff --git a/sound/soc/codecs/mt6660.c b/sound/soc/codecs/mt6660.c
> > new file mode 100644
> > index 0000000..b8fc53b
> > --- /dev/null
> > +++ b/sound/soc/codecs/mt6660.c
> > @@ -0,0 +1,628 @@
> 
> > +
> > +struct codec_reg_val {
> > +	u32 addr;
> > +	u32 mask;
> > +	u32 data;
> > +};
> 
> packed structures could have been better.

It depends.  Packing may break alignment and the performance may
suffer from it.  So, in general, __packed is recommended when the size
matters (e.g. lots of objects / arrays are created) or it's about ABI
that needs the fixed consistent size.


thanks,

Takashi
_______________________________________________
Alsa-devel mailing list
Alsa-devel@xxxxxxxxxxxxxxxx
https://mailman.alsa-project.org/mailman/listinfo/alsa-devel



[Index of Archives]     [ALSA User]     [Linux Audio Users]     [Pulse Audio]     [Kernel Archive]     [Asterisk PBX]     [Photo Sharing]     [Linux Sound]     [Video 4 Linux]     [Gimp]     [Yosemite News]

  Powered by Linux