ASoC: Don't use codec->control_data in bulk write
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 13 Jun 2011 17:44:52 +0000 (18:44 +0100)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 13 Jun 2011 18:17:33 +0000 (19:17 +0100)
In order to facilitate merging with the register map I/O replace the use
of control_data for the bulk writes with direct lookup of the client data
from the device.

Signed-off-by: Mark Brown <broonie@opensource.wolfsonmicro.com>
Acked-by: Liam Girdwood <lrg@ti.com>
sound/soc/soc-io.c

index 855e5cde2793b37200abdb35a0f04ba94c23a8a4..df9338aa1a52cef7f8e58665372733ee5a9a2db0 100644 (file)
@@ -269,12 +269,12 @@ static int snd_soc_hw_bulk_write_raw(struct snd_soc_codec *codec, unsigned int r
        switch (codec->control_type) {
 #if defined(CONFIG_I2C) || (defined(CONFIG_I2C_MODULE) && defined(MODULE))
        case SND_SOC_I2C:
-               ret = i2c_master_send(codec->control_data, data, len);
+               ret = i2c_master_send(to_i2c_client(codec->dev), data, len);
                break;
 #endif
 #if defined(CONFIG_SPI_MASTER)
        case SND_SOC_SPI:
-               ret = spi_write(codec->control_data, data, len);
+               ret = spi_write(to_spi_device(codec->dev), data, len);
                break;
 #endif
        default: