Commit 40d03e63 authored by David Henningsson's avatar David Henningsson Committed by Takashi Iwai

ALSA: HDA: Fix master control for Cirrus Logic 421X

The control name "HP/Speakers" is non-standard, and since there is
only one DAC on this chip there is no need for a virtual master
anyway.

Cc: stable@kernel.org
Signed-off-by: default avatarDavid Henningsson <david.henningsson@canonical.com>
Signed-off-by: default avatarTakashi Iwai <tiwai@suse.de>
parent 716e5db4
...@@ -1779,30 +1779,19 @@ static int build_cs421x_output(struct hda_codec *codec) ...@@ -1779,30 +1779,19 @@ static int build_cs421x_output(struct hda_codec *codec)
struct auto_pin_cfg *cfg = &spec->autocfg; struct auto_pin_cfg *cfg = &spec->autocfg;
struct snd_kcontrol *kctl; struct snd_kcontrol *kctl;
int err; int err;
char *name = "HP/Speakers"; char *name = "Master";
fix_volume_caps(codec, dac); fix_volume_caps(codec, dac);
if (!spec->vmaster_sw) {
err = add_vmaster(codec, dac);
if (err < 0)
return err;
}
err = add_mute(codec, name, 0, err = add_mute(codec, name, 0,
HDA_COMPOSE_AMP_VAL(dac, 3, 0, HDA_OUTPUT), 0, &kctl); HDA_COMPOSE_AMP_VAL(dac, 3, 0, HDA_OUTPUT), 0, &kctl);
if (err < 0) if (err < 0)
return err; return err;
err = snd_ctl_add_slave(spec->vmaster_sw, kctl);
if (err < 0)
return err;
err = add_volume(codec, name, 0, err = add_volume(codec, name, 0,
HDA_COMPOSE_AMP_VAL(dac, 3, 0, HDA_OUTPUT), 0, &kctl); HDA_COMPOSE_AMP_VAL(dac, 3, 0, HDA_OUTPUT), 0, &kctl);
if (err < 0) if (err < 0)
return err; return err;
err = snd_ctl_add_slave(spec->vmaster_vol, kctl);
if (err < 0)
return err;
if (cfg->speaker_outs) { if (cfg->speaker_outs) {
err = snd_hda_ctl_add(codec, 0, err = snd_hda_ctl_add(codec, 0,
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment