• Home
  • Raw
  • Download

Lines Matching refs:vol

153 	int vol[2];  in snd_pmac_awacs_get_volume()  local
156 vol[0] = (chip->awacs_reg[reg] >> lshift) & 0xf; in snd_pmac_awacs_get_volume()
157 vol[1] = chip->awacs_reg[reg] & 0xf; in snd_pmac_awacs_get_volume()
160 vol[0] = 0x0f - vol[0]; in snd_pmac_awacs_get_volume()
161 vol[1] = 0x0f - vol[1]; in snd_pmac_awacs_get_volume()
163 ucontrol->value.integer.value[0] = vol[0]; in snd_pmac_awacs_get_volume()
164 ucontrol->value.integer.value[1] = vol[1]; in snd_pmac_awacs_get_volume()
177 unsigned int vol[2]; in snd_pmac_awacs_put_volume() local
179 vol[0] = ucontrol->value.integer.value[0]; in snd_pmac_awacs_put_volume()
180 vol[1] = ucontrol->value.integer.value[1]; in snd_pmac_awacs_put_volume()
181 if (vol[0] > 0x0f || vol[1] > 0x0f) in snd_pmac_awacs_put_volume()
184 vol[0] = 0x0f - vol[0]; in snd_pmac_awacs_put_volume()
185 vol[1] = 0x0f - vol[1]; in snd_pmac_awacs_put_volume()
187 vol[0] &= 0x0f; in snd_pmac_awacs_put_volume()
188 vol[1] &= 0x0f; in snd_pmac_awacs_put_volume()
192 val |= vol[0] << lshift; in snd_pmac_awacs_put_volume()
193 val |= vol[1]; in snd_pmac_awacs_put_volume()
309 static void awacs_amp_set_master(struct awacs_amp *amp, int vol) in awacs_amp_set_master() argument
311 amp->amp_master = vol; in awacs_amp_set_master()
312 if (vol <= 79) in awacs_amp_set_master()
313 vol = 32 + (79 - vol); in awacs_amp_set_master()
315 vol = 32 - (vol - 79); in awacs_amp_set_master()
316 awacs_set_cuda(1, vol); in awacs_amp_set_master()
360 int vol[2]; in snd_pmac_awacs_put_volume_amp() local
363 vol[0] = (31 - (ucontrol->value.integer.value[0] & 31)) in snd_pmac_awacs_put_volume_amp()
365 vol[1] = (31 - (ucontrol->value.integer.value[1] & 31)) in snd_pmac_awacs_put_volume_amp()
367 return awacs_amp_set_vol(amp, index, vol[0], vol[1], 1); in snd_pmac_awacs_put_volume_amp()
389 int vol[2]; in snd_pmac_awacs_put_switch_amp() local
392 vol[0] = (ucontrol->value.integer.value[0] ? 0 : 32) in snd_pmac_awacs_put_switch_amp()
394 vol[1] = (ucontrol->value.integer.value[1] ? 0 : 32) in snd_pmac_awacs_put_switch_amp()
396 return awacs_amp_set_vol(amp, index, vol[0], vol[1], 1); in snd_pmac_awacs_put_switch_amp()
790 int vol[2]; in toggle_amp_mute() local
791 vol[0] = amp->amp_vol[index][0] & 31; in toggle_amp_mute()
792 vol[1] = amp->amp_vol[index][1] & 31; in toggle_amp_mute()
794 vol[0] |= 32; in toggle_amp_mute()
795 vol[1] |= 32; in toggle_amp_mute()
797 return awacs_amp_set_vol(amp, index, vol[0], vol[1], 1); in toggle_amp_mute()
864 int err, vol; in snd_pmac_awacs_init() local
882 vol = 0x0f; /* no, on alsa, muted as default */ in snd_pmac_awacs_init()
883 vol = vol + (vol << 6); in snd_pmac_awacs_init()
884 chip->awacs_reg[2] = vol; in snd_pmac_awacs_init()
885 chip->awacs_reg[4] = vol; in snd_pmac_awacs_init()
888 chip->awacs_reg[5] = vol; in snd_pmac_awacs_init()