Skip to content

Commit

Permalink
ALSA: hda - Don't enable beep for digital-only ALC262
Browse files Browse the repository at this point in the history
When ALC262 codec is configured as digital-only, it's meaningless to
add the digital beep input.

Signed-off-by: Takashi Iwai <tiwai@suse.de>
  • Loading branch information
Takashi Iwai committed Feb 19, 2009
1 parent b3bdb30 commit 07eba61
Showing 1 changed file with 8 additions and 5 deletions.
13 changes: 8 additions & 5 deletions sound/pci/hda/patch_realtek.c
Original file line number Diff line number Diff line change
Expand Up @@ -11051,10 +11051,12 @@ static int patch_alc262(struct hda_codec *codec)
}
}

err = snd_hda_attach_beep_device(codec, 0x1);
if (err < 0) {
alc_free(codec);
return err;
if (!spec->no_analog) {
err = snd_hda_attach_beep_device(codec, 0x1);
if (err < 0) {
alc_free(codec);
return err;
}
}

if (board_config != ALC262_AUTO)
Expand Down Expand Up @@ -11087,7 +11089,8 @@ static int patch_alc262(struct hda_codec *codec)
}
if (!spec->cap_mixer && !spec->no_analog)
set_capture_mixer(spec);
set_beep_amp(spec, 0x0b, 0x05, HDA_INPUT);
if (!spec->no_analog)
set_beep_amp(spec, 0x0b, 0x05, HDA_INPUT);

spec->vmaster_nid = 0x0c;

Expand Down

0 comments on commit 07eba61

Please sign in to comment.