Beispiel #1
0
static int cmi_ch_mode_put(struct snd_kcontrol *kcontrol, struct snd_ctl_elem_value *ucontrol)
{
    struct hda_codec *codec = snd_kcontrol_chip(kcontrol);
    struct cmi_spec *spec = codec->spec;
    return snd_hda_ch_mode_put(codec, ucontrol, spec->channel_modes,
                   spec->num_channel_modes, &spec->multiout.max_channels);
}
Beispiel #2
0
static int ad198x_ch_mode_put(struct snd_kcontrol *kcontrol,
			      struct snd_ctl_elem_value *ucontrol)
{
	struct hda_codec *codec = snd_kcontrol_chip(kcontrol);
	struct ad198x_spec *spec = codec->spec;
	int err = snd_hda_ch_mode_put(codec, ucontrol, spec->channel_mode,
				      spec->num_channel_mode,
				      &spec->multiout.max_channels);
	if (err >= 0 && spec->need_dac_fix)
		spec->multiout.num_dacs = spec->multiout.max_channels / 2;
	return err;
}