[alsa-devel] [PATCH 7/7] ASoC: soc-cache: Introduce raw bulk write support

Mark Brown broonie at opensource.wolfsonmicro.com
Tue May 10 23:13:18 CEST 2011

On Tue, Mar 22, 2011 at 10:37:03AM +0000, Dimitris Papastamos wrote:

> +	switch (codec->control_type) {
> +	case SND_SOC_I2C:
> +		ret = i2c_master_send(codec->control_data, data, len);
> +		break;
> +	case SND_SOC_SPI:
> +		ret = do_spi_write(codec->control_data, data, len);
> +		break;

Hrm, I now realise that this doesn't actually do what I'd expect - it
only writes out the provided data, there's no inclusion of the register
address.  I'd been mislead by the fact that it is taking in the register
address as an argument and an overly hasty review it seems.  That's a
little too raw for me, we should be prefixing the data with the base
register address.

More information about the Alsa-devel mailing list