aboutsummaryrefslogtreecommitdiffstats
path: root/sound
diff options
context:
space:
mode:
authorTakashi Iwai <tiwai@suse.de>2009-08-25 16:07:08 +0200
committerTakashi Iwai <tiwai@suse.de>2009-08-25 16:07:08 +0200
commit23112d6d2d9b265c959ecb671366c7c3b9c83611 (patch)
tree9f5edef13165fb4cf32dc12327d1bd911811f218 /sound
parentcb162b6bf2f445d67a45f5485d4ce32addaf8fe0 (diff)
downloadkernel_samsung_crespo-23112d6d2d9b265c959ecb671366c7c3b9c83611.zip
kernel_samsung_crespo-23112d6d2d9b265c959ecb671366c7c3b9c83611.tar.gz
kernel_samsung_crespo-23112d6d2d9b265c959ecb671366c7c3b9c83611.tar.bz2
ALSA: hda - Improve auto-cfg mixer name for ALC260
Instead of fixed "Front" mixer name, try to assign a better name, e.g. "Master" or "Speaker" fot the primary output volume controls of ALC260 codec. Signed-off-by: Takashi Iwai <tiwai@suse.de>
Diffstat (limited to 'sound')
-rw-r--r--sound/pci/hda/patch_realtek.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 07fbf7d..00ed126 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -6017,7 +6017,14 @@ static int alc260_auto_create_multi_out_ctls(struct alc_spec *spec,
nid = cfg->line_out_pins[0];
if (nid) {
- err = alc260_add_playback_controls(spec, nid, "Front", &vols);
+ const char *pfx;
+ if (!cfg->speaker_pins[0] && !cfg->hp_pins[0])
+ pfx = "Master";
+ else if (cfg->line_out_type == AUTO_PIN_SPEAKER_OUT)
+ pfx = "Speaker";
+ else
+ pfx = "Front";
+ err = alc260_add_playback_controls(spec, nid, pfx, &vols);
if (err < 0)
return err;
}