diff options
Diffstat (limited to 'sound/i2c')
| -rw-r--r-- | sound/i2c/cs8427.c | 7 | ||||
| -rw-r--r-- | sound/i2c/i2c.c | 2 |
2 files changed, 6 insertions, 3 deletions
diff --git a/sound/i2c/cs8427.c b/sound/i2c/cs8427.c index 9deba80a587c..cb89f7eb9236 100644 --- a/sound/i2c/cs8427.c +++ b/sound/i2c/cs8427.c | |||
| @@ -291,11 +291,13 @@ static void snd_cs8427_reset(struct snd_i2c_device *cs8427) | |||
| 291 | { | 291 | { |
| 292 | struct cs8427 *chip; | 292 | struct cs8427 *chip; |
| 293 | unsigned long end_time; | 293 | unsigned long end_time; |
| 294 | int data; | 294 | int data, aes3input = 0; |
| 295 | 295 | ||
| 296 | snd_assert(cs8427, return); | 296 | snd_assert(cs8427, return); |
| 297 | chip = cs8427->private_data; | 297 | chip = cs8427->private_data; |
| 298 | snd_i2c_lock(cs8427->bus); | 298 | snd_i2c_lock(cs8427->bus); |
| 299 | if ((chip->regmap[CS8427_REG_CLOCKSOURCE] & CS8427_RXDAES3INPUT) == CS8427_RXDAES3INPUT) /* AES3 bit is set */ | ||
| 300 | aes3input = 1; | ||
| 299 | chip->regmap[CS8427_REG_CLOCKSOURCE] &= ~(CS8427_RUN | CS8427_RXDMASK); | 301 | chip->regmap[CS8427_REG_CLOCKSOURCE] &= ~(CS8427_RUN | CS8427_RXDMASK); |
| 300 | snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE, | 302 | snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE, |
| 301 | chip->regmap[CS8427_REG_CLOCKSOURCE]); | 303 | chip->regmap[CS8427_REG_CLOCKSOURCE]); |
| @@ -316,7 +318,8 @@ static void snd_cs8427_reset(struct snd_i2c_device *cs8427) | |||
| 316 | } | 318 | } |
| 317 | snd_i2c_lock(cs8427->bus); | 319 | snd_i2c_lock(cs8427->bus); |
| 318 | chip->regmap[CS8427_REG_CLOCKSOURCE] &= ~CS8427_RXDMASK; | 320 | chip->regmap[CS8427_REG_CLOCKSOURCE] &= ~CS8427_RXDMASK; |
| 319 | chip->regmap[CS8427_REG_CLOCKSOURCE] |= CS8427_RXDAES3INPUT; | 321 | if (aes3input) |
| 322 | chip->regmap[CS8427_REG_CLOCKSOURCE] |= CS8427_RXDAES3INPUT; | ||
| 320 | snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE, | 323 | snd_cs8427_reg_write(cs8427, CS8427_REG_CLOCKSOURCE, |
| 321 | chip->regmap[CS8427_REG_CLOCKSOURCE]); | 324 | chip->regmap[CS8427_REG_CLOCKSOURCE]); |
| 322 | snd_i2c_unlock(cs8427->bus); | 325 | snd_i2c_unlock(cs8427->bus); |
diff --git a/sound/i2c/i2c.c b/sound/i2c/i2c.c index c4e1f2c23ced..edfe76fb0074 100644 --- a/sound/i2c/i2c.c +++ b/sound/i2c/i2c.c | |||
| @@ -88,7 +88,7 @@ int snd_i2c_bus_create(struct snd_card *card, const char *name, | |||
| 88 | bus = kzalloc(sizeof(*bus), GFP_KERNEL); | 88 | bus = kzalloc(sizeof(*bus), GFP_KERNEL); |
| 89 | if (bus == NULL) | 89 | if (bus == NULL) |
| 90 | return -ENOMEM; | 90 | return -ENOMEM; |
| 91 | init_MUTEX(&bus->lock_mutex); | 91 | mutex_init(&bus->lock_mutex); |
| 92 | INIT_LIST_HEAD(&bus->devices); | 92 | INIT_LIST_HEAD(&bus->devices); |
| 93 | INIT_LIST_HEAD(&bus->buses); | 93 | INIT_LIST_HEAD(&bus->buses); |
| 94 | bus->card = card; | 94 | bus->card = card; |
