diff options
Diffstat (limited to 'sound/ppc/tumbler.c')
-rw-r--r-- | sound/ppc/tumbler.c | 19 |
1 files changed, 10 insertions, 9 deletions
diff --git a/sound/ppc/tumbler.c b/sound/ppc/tumbler.c index 15c63cb2ccba..838fc113c441 100644 --- a/sound/ppc/tumbler.c +++ b/sound/ppc/tumbler.c | |||
@@ -239,8 +239,8 @@ static int tumbler_set_master_volume(struct pmac_tumbler *mix) | |||
239 | block[4] = (right_vol >> 8) & 0xff; | 239 | block[4] = (right_vol >> 8) & 0xff; |
240 | block[5] = (right_vol >> 0) & 0xff; | 240 | block[5] = (right_vol >> 0) & 0xff; |
241 | 241 | ||
242 | if (i2c_smbus_write_block_data(mix->i2c.client, TAS_REG_VOL, | 242 | if (i2c_smbus_write_i2c_block_data(mix->i2c.client, TAS_REG_VOL, 6, |
243 | 6, block) < 0) { | 243 | block) < 0) { |
244 | snd_printk("failed to set volume \n"); | 244 | snd_printk("failed to set volume \n"); |
245 | return -EINVAL; | 245 | return -EINVAL; |
246 | } | 246 | } |
@@ -345,8 +345,8 @@ static int tumbler_set_drc(struct pmac_tumbler *mix) | |||
345 | val[1] = 0; | 345 | val[1] = 0; |
346 | } | 346 | } |
347 | 347 | ||
348 | if (i2c_smbus_write_block_data(mix->i2c.client, TAS_REG_DRC, | 348 | if (i2c_smbus_write_i2c_block_data(mix->i2c.client, TAS_REG_DRC, |
349 | 2, val) < 0) { | 349 | 2, val) < 0) { |
350 | snd_printk("failed to set DRC\n"); | 350 | snd_printk("failed to set DRC\n"); |
351 | return -EINVAL; | 351 | return -EINVAL; |
352 | } | 352 | } |
@@ -381,8 +381,8 @@ static int snapper_set_drc(struct pmac_tumbler *mix) | |||
381 | val[4] = 0x60; | 381 | val[4] = 0x60; |
382 | val[5] = 0xa0; | 382 | val[5] = 0xa0; |
383 | 383 | ||
384 | if (i2c_smbus_write_block_data(mix->i2c.client, TAS_REG_DRC, | 384 | if (i2c_smbus_write_i2c_block_data(mix->i2c.client, TAS_REG_DRC, |
385 | 6, val) < 0) { | 385 | 6, val) < 0) { |
386 | snd_printk("failed to set DRC\n"); | 386 | snd_printk("failed to set DRC\n"); |
387 | return -EINVAL; | 387 | return -EINVAL; |
388 | } | 388 | } |
@@ -492,8 +492,8 @@ static int tumbler_set_mono_volume(struct pmac_tumbler *mix, | |||
492 | vol = info->table[vol]; | 492 | vol = info->table[vol]; |
493 | for (i = 0; i < info->bytes; i++) | 493 | for (i = 0; i < info->bytes; i++) |
494 | block[i] = (vol >> ((info->bytes - i - 1) * 8)) & 0xff; | 494 | block[i] = (vol >> ((info->bytes - i - 1) * 8)) & 0xff; |
495 | if (i2c_smbus_write_block_data(mix->i2c.client, info->reg, | 495 | if (i2c_smbus_write_i2c_block_data(mix->i2c.client, info->reg, |
496 | info->bytes, block) < 0) { | 496 | info->bytes, block) < 0) { |
497 | snd_printk("failed to set mono volume %d\n", info->index); | 497 | snd_printk("failed to set mono volume %d\n", info->index); |
498 | return -EINVAL; | 498 | return -EINVAL; |
499 | } | 499 | } |
@@ -625,7 +625,8 @@ static int snapper_set_mix_vol1(struct pmac_tumbler *mix, int idx, int ch, int r | |||
625 | for (j = 0; j < 3; j++) | 625 | for (j = 0; j < 3; j++) |
626 | block[i * 3 + j] = (vol >> ((2 - j) * 8)) & 0xff; | 626 | block[i * 3 + j] = (vol >> ((2 - j) * 8)) & 0xff; |
627 | } | 627 | } |
628 | if (i2c_smbus_write_block_data(mix->i2c.client, reg, 9, block) < 0) { | 628 | if (i2c_smbus_write_i2c_block_data(mix->i2c.client, reg, |
629 | 9, block) < 0) { | ||
629 | snd_printk("failed to set mono volume %d\n", reg); | 630 | snd_printk("failed to set mono volume %d\n", reg); |
630 | return -EINVAL; | 631 | return -EINVAL; |
631 | } | 632 | } |