From: David Henningsson <david.henningsson@canonical.com>
To: tiwai@suse.de, alsa-devel@alsa-project.org
Cc: David Henningsson <david.henningsson@canonical.com>
Subject: [PATCH 1/3] ALSA: hda - do not add non-existing Mic boost controls
Date: Wed, 16 Jan 2013 15:58:43 +0100 [thread overview]
Message-ID: <1358348325-308-2-git-send-email-david.henningsson@canonical.com> (raw)
In-Reply-To: <1358348325-308-1-git-send-email-david.henningsson@canonical.com>
If the input node does not have any volume capable input amp,
don't add such a control.
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---
sound/pci/hda/hda_generic.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c
index 3ef38da..72325a9 100644
--- a/sound/pci/hda/hda_generic.c
+++ b/sound/pci/hda/hda_generic.c
@@ -2820,6 +2820,9 @@ static int parse_mic_boost(struct hda_codec *codec)
struct nid_path *path;
unsigned int val;
+ if (!nid_has_volume(codec, nid, HDA_INPUT))
+ continue;
+
label = hda_get_autocfg_input_label(codec, cfg, i);
if (prev_label && !strcmp(label, prev_label))
type_idx++;
--
1.7.9.5
next prev parent reply other threads:[~2013-01-16 14:58 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-01-16 14:58 [PATCH 0/3] ...and three more fixes for the new generic parser David Henningsson
2013-01-16 14:58 ` David Henningsson [this message]
2013-01-16 14:58 ` [PATCH 2/3] ALSA: hda - force different capture controls if amp caps differ David Henningsson
2013-01-16 14:58 ` [PATCH 3/3] ALSA: hda - Make sure fill_all_dac_nids is called for digital only codecs David Henningsson
2013-01-16 15:26 ` [PATCH 0/3] ...and three more fixes for the new generic parser 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=1358348325-308-2-git-send-email-david.henningsson@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).