All of lore.kernel.org
 help / color / mirror / Atom feed
From: Matthew Ranostay <mranostay@embeddedalley.com>
To: alsa-devel@alsa-project.org
Cc: Takashi Iwai <tiwai@suse.de>, "Tellman, Steven" <Steven.Tellman@idt.com>
Subject: [PATCH] hda: Add dmux to STAC 9228
Date: Thu, 18 Oct 2007 17:36:32 -0400	[thread overview]
Message-ID: <4717D1E0.9080903@embeddedalley.com> (raw)

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

Added a dmux to the STAC9228 cards with DMIC support. And added a 
STAC_DIGITAL_INPUT_SOURCE macro for repeating mixer code.
---
Signed-off-by: Matthew Ranostay <mranostay@embeddedalley.com>

[-- Attachment #2: stac9228_dmux.patch --]
[-- Type: text/plain, Size: 1512 bytes --]

diff -r 821a4558dd47 pci/hda/patch_sigmatel.c
--- a/pci/hda/patch_sigmatel.c	Thu Oct 18 17:38:17 2007 +0200
+++ b/pci/hda/patch_sigmatel.c	Thu Oct 18 17:35:56 2007 -0400
@@ -430,6 +430,16 @@ static struct hda_verb stac9205_core_ini
 	{}
 };
 
+#define STAC_DIGITAL_INPUT_SOURCE(cnt) \
+	{ \
+		.iface = SNDRV_CTL_ELEM_IFACE_MIXER, \
+		.name = "Digital Input Source", \
+		.count = cnt, \
+		.info = stac92xx_dmux_enum_info, \
+		.get = stac92xx_dmux_enum_get, \
+		.put = stac92xx_dmux_enum_put,\
+	}
+
 #define STAC_INPUT_SOURCE(cnt) \
 	{ \
 		.iface = SNDRV_CTL_ELEM_IFACE_MIXER, \
@@ -482,14 +492,7 @@ static struct snd_kcontrol_new stac925x_
 };
 
 static struct snd_kcontrol_new stac9205_mixer[] = {
-	{
-		.iface = SNDRV_CTL_ELEM_IFACE_MIXER,
-		.name = "Digital Input Source",
-		.count = 1,
-		.info = stac92xx_dmux_enum_info,
-		.get = stac92xx_dmux_enum_get,
-		.put = stac92xx_dmux_enum_put,
-	},
+	STAC_DIGITAL_INPUT_SOURCE(1),
 	STAC_INPUT_SOURCE(2),
 	STAC_ANALOG_LOOPBACK(0xFE0, 0x7E0),
 	STAC_VOLKNOB(0x24),
@@ -521,6 +524,7 @@ static struct snd_kcontrol_new stac922x_
 
 
 static struct snd_kcontrol_new stac927x_mixer[] = {
+	STAC_DIGITAL_INPUT_SOURCE(1),
 	STAC_INPUT_SOURCE(3),
 	STAC_VOLKNOB(0x24),
 	STAC_ANALOG_LOOPBACK(0xFEB, 0x7EB),
@@ -2773,6 +2777,7 @@ static int patch_stac927x(struct hda_cod
 	case 0x10280209: /* STAC 9228 */
 		spec->dmic_nids = stac927x_dmic_nids;
 		spec->num_dmics = STAC927X_NUM_DMICS;
+		spec->dmux_nid = 0x1c;
 		break;
 	default:
 		spec->num_dmics = 0;	

[-- 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:[~2007-10-18 21:36 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2007-10-18 21:36 Matthew Ranostay [this message]
2007-10-19  5:31 ` [PATCH] hda: Add dmux to STAC 9228 Takashi Iwai
2007-10-19 16:45 ` Tim Gardner
2007-10-19 17:59   ` Matthew Ranostay
2007-10-19 18:45     ` Tim Gardner
2007-10-19 18:59       ` Matthew Ranostay

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=4717D1E0.9080903@embeddedalley.com \
    --to=mranostay@embeddedalley.com \
    --cc=Steven.Tellman@idt.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.