[alsa-devel] DAPM core: update bits in the same i2c operation

Mark Brown broonie at kernel.org
Tue Jan 19 01:47:39 CET 2016


On Mon, Jan 18, 2016 at 03:16:39PM -0800, noman pouigt wrote:

> I have two DAC's: left and right and I have made this two as dapm controls.
> However left and right dac needs to be enabled in the same I2C write operation.
> 
> I can easily make a callback and can enable both left and right bits in one
> operation however wondering if ALSA dapm core would have a better way
> to handle this.

> Where is the relevant code to handle this i.e. merging two dapm widgets
> writes to the same register in one? I looked through the code and found
>  that every widget gets added in the up and down list which is individually
> powered on/off.

You're looking for dapm_seq_run() which coalesces any writes it can.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 473 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20160119/3f1c798b/attachment.sig>


More information about the Alsa-devel mailing list