All of lore.kernel.org
 help / color / mirror / Atom feed
From: David Henningsson <david.henningsson@canonical.com>
To: ALSA Development Mailing List <alsa-devel@alsa-project.org>,
	Takashi Iwai <tiwai@suse.de>
Subject: [PATCH 3/3] ALSA: HDA: Add Front control for ALC887
Date: Fri, 19 Nov 2010 10:31:20 +0100	[thread overview]
Message-ID: <4CE643E8.1090208@canonical.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 204 bytes --]

HP and Line out share DAC, so we need a switch to turn line out off.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>

-- 
David Henningsson, Canonical Ltd.
http://launchpad.net/~diwic

[-- Attachment #2: 0003-ALSA-HDA-Add-Front-control-for-ALC887.patch --]
[-- Type: text/x-patch, Size: 1358 bytes --]

>From 955438a1e0f21218d207196456d8e46295f5feec Mon Sep 17 00:00:00 2001
From: David Henningsson <david.henningsson@canonical.com>
Date: Wed, 17 Nov 2010 15:06:15 +0100
Subject: [PATCH 3/3] ALSA: HDA: Add Front control for ALC887

HP and Line out share DAC, so we need a switch to turn line out off.

Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---
 sound/pci/hda/patch_realtek.c |   10 +++++++++-
 1 files changed, 9 insertions(+), 1 deletions(-)

diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index 4cc7bb2..86df37c 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -10836,8 +10836,16 @@ static int alc882_parse_auto_config(struct hda_codec *codec)
 	err = alc880_auto_fill_dac_nids(spec, &spec->autocfg);
 	if (err < 0)
 		return err;
-	if (codec->vendor_id == 0x10ec0887)
+	if (codec->vendor_id == 0x10ec0887) {
 		err = alc861vd_auto_create_multi_out_ctls(spec, &spec->autocfg);
+		if (err < 0)
+			return err;
+		/* We need something to switch that doesn't affect headphones */
+		if (spec->autocfg.line_out_pins[0])
+			err = add_pb_sw_ctrl(spec, ALC_CTL_WIDGET_MUTE, "Front",
+				  HDA_COMPOSE_AMP_VAL(spec->autocfg.line_out_pins[0], 3, 0, HDA_OUTPUT));
+
+        }
 	else
 		err = alc880_auto_create_multi_out_ctls(spec, &spec->autocfg);
 	if (err < 0)
-- 
1.7.1


[-- Attachment #3: Type: text/plain, Size: 160 bytes --]

_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

             reply	other threads:[~2010-11-19  9:31 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2010-11-19  9:31 David Henningsson [this message]
2010-11-22  6:51 ` [PATCH 3/3] ALSA: HDA: Add Front control for ALC887 Takashi Iwai

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=4CE643E8.1090208@canonical.com \
    --to=david.henningsson@canonical.com \
    --cc=alsa-devel@alsa-project.org \
    --cc=tiwai@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.