Lines Matching defs:ice

35 static inline void stac9460_put(struct snd_ice1712 *ice, int reg,
38 snd_vt1724_write_i2c(ice, STAC9460_I2C_ADDR, reg, val);
41 static inline unsigned char stac9460_get(struct snd_ice1712 *ice, int reg)
43 return snd_vt1724_read_i2c(ice, STAC9460_I2C_ADDR, reg);
49 static inline void stac9460_2_put(struct snd_ice1712 *ice, int reg,
52 snd_vt1724_write_i2c(ice, STAC9460_2_I2C_ADDR, reg, val);
55 static inline unsigned char stac9460_2_get(struct snd_ice1712 *ice, int reg)
57 return snd_vt1724_read_i2c(ice, STAC9460_2_I2C_ADDR, reg);
64 static void stac9460_dac_mute_all(struct snd_ice1712 *ice, unsigned char mute,
77 old = stac9460_get(ice, idx);
81 stac9460_put(ice, idx, new);
96 old = stac9460_2_get(ice, idx);
100 stac9460_2_put(ice, idx, new);
116 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
117 struct wtm_spec *spec = ice->spec;
131 val = stac9460_get(ice, idx);
133 val = stac9460_2_get(ice, idx - 6);
143 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
150 old = stac9460_get(ice, idx);
155 stac9460_put(ice, idx, new);
156 stac9460_2_put(ice, idx, new);
162 old = stac9460_get(ice, idx);
164 old = stac9460_2_get(ice, idx - 6);
170 stac9460_put(ice, idx, new);
172 stac9460_2_put(ice, idx - 6, new);
194 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
206 vol = stac9460_get(ice, idx) & 0x7f;
208 vol = stac9460_2_get(ice, idx - 6) & 0x7f;
216 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
224 tmp = stac9460_get(ice, idx);
228 stac9460_put(ice, idx, (0x7f - nvol) | (tmp & 0x80));
229 stac9460_2_put(ice, idx, (0x7f - nvol) | (tmp & 0x80));
236 tmp = stac9460_get(ice, idx);
238 tmp = stac9460_2_get(ice, idx - 6);
243 stac9460_put(ice, idx, (0x7f - nvol) |
246 stac9460_2_put(ice, idx-6, (0x7f - nvol) |
261 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
268 val = stac9460_get(ice, STAC946X_MIC_L_VOLUME + i);
273 val = stac9460_2_get(ice, STAC946X_MIC_L_VOLUME + i);
283 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
292 old = stac9460_get(ice, reg);
297 stac9460_put(ice, reg, new);
302 old = stac9460_2_get(ice, reg);
307 stac9460_2_put(ice, reg, new);
329 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
337 vol = stac9460_get(ice, reg) & 0x0f;
343 vol = stac9460_2_get(ice, reg) & 0x0f;
353 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
363 ovol = 0x0f - stac9460_get(ice, reg);
366 stac9460_put(ice, reg, (0x0f - nvol) |
373 ovol = 0x0f - stac9460_2_get(ice, reg);
376 stac9460_2_put(ice, reg, (0x0f - nvol) |
398 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
404 val = stac9460_get(ice, STAC946X_GENERAL_PURPOSE);
406 val = stac9460_2_get(ice, STAC946X_GENERAL_PURPOSE);
414 struct snd_ice1712 *ice = snd_kcontrol_chip(kcontrol);
420 old = stac9460_get(ice, STAC946X_GENERAL_PURPOSE);
422 old = stac9460_2_get(ice, STAC946X_GENERAL_PURPOSE);
427 stac9460_put(ice, STAC946X_GENERAL_PURPOSE, new);
429 stac9460_2_put(ice, STAC946X_GENERAL_PURPOSE, new);
438 static void stac9460_set_rate_val(struct snd_ice1712 *ice, unsigned int rate)
442 struct wtm_spec *spec = ice->spec;
453 old = stac9460_get(ice, STAC946X_MASTER_CLOCKING);
461 stac9460_dac_mute_all(ice, 0, &changed);
463 stac9460_put(ice, STAC946X_MASTER_CLOCKING, new);
464 stac9460_2_put(ice, STAC946X_MASTER_CLOCKING, new);
468 stac9460_dac_mute_all(ice, 1, &changed);
554 static int wtm_add_controls(struct snd_ice1712 *ice)
560 err = snd_ctl_add(ice->card,
561 snd_ctl_new1(&stac9640_controls[i], ice));
568 static int wtm_init(struct snd_ice1712 *ice)
579 ice->num_total_dacs = 8;
580 ice->num_total_adcs = 4;
581 ice->force_rdma1 = 1;
587 ice->spec = spec;
594 stac9460_put(ice, p[0], p[1]);
595 stac9460_2_put(ice, p[0], p[1]);
597 ice->gpio.set_pro_rate = stac9460_set_rate_val;