From: David Henningsson <david.henningsson@canonical.com>
To: alsa-devel@alsa-project.org
Cc: Takashi Iwai <tiwai@suse.de>, losinski@wh2.tu-dresden.de
Subject: [PATCH] ALSA: HDA: Realtek: Avoid unnecessary volume control index on Surround/Side
Date: Wed, 23 Mar 2011 08:56:34 +0100 [thread overview]
Message-ID: <4D89A7B2.6050204@canonical.com> (raw)
In-Reply-To: <20110321231321.GA13972@atlantis.wh2.tu-dresden.de.de>
[-- Attachment #1: Type: text/plain, Size: 1109 bytes --]
On 2011-03-22 00:13, Jan Losinski wrote:
> * David Henningsson<david.henningsson@canonical.com> [2011-03-21 22:44]:
>> Hmm, I made one or two patches in relation to this but they aimed at=20
>> moving index 1 to index 0, not the other way around. Could you please=20
>> give alsa-info (see wiki.ubuntu.com/Audio/AlsaInfo ) information,=20
>> preferably with 2.6.38 (and without your workaround) installed?
>
> Of course, it's located at [1] (2.6.38 without my "fix". Let me know if
> you need more information or if you need someone to test).
>
> Jan Losinski
>
> [1] http://www.alsa-project.org/db/?f=3D80bc05cada24ed993c4f964d4188add6d0e=
> 1dddb
Thanks, I've attached a patch that fixes this issue - Takashi, will you
apply it?
> PS1: The tool does not work with LANG=3Dde_DE.UTF-8
Could not reproduce here, tried "LANG=de_DE.UTF-8 ./alsa-info.sh" and it
succeeded normally.
> PS2: I've subscribed the list ;)
Great! Nevertheless I like being CC:ed myself when something concerns me
in person, so I tend to do the same to others.
--
David Henningsson, Canonical Ltd.
http://launchpad.net/~diwic
[-- Attachment #2: 0001-ALSA-HDA-Realtek-Avoid-unnecessary-volume-control-in.patch --]
[-- Type: text/x-patch, Size: 2626 bytes --]
>From bda10a777732d2f31d1a5a51954fe73b37177f2d Mon Sep 17 00:00:00 2001
From: David Henningsson <david.henningsson@canonical.com>
Date: Wed, 23 Mar 2011 08:35:07 +0100
Subject: [PATCH] ALSA: HDA: Realtek: Avoid unnecessary volume control index on Surround/Side
Similar to commit 7e59e097c09b82760bb0fe08b0fa2b704d76c3f4, this patch
avoids unnecessary volume control indices for more
Realtek auto-parsers, e g the ALC66x family, on the "Surround" and "Side"
controls.
These indices cause these volume controls to be ignored by PulseAudio and
vmaster and should be removed whenever possible.
Cc: stable@kernel.org
Reported-by: Jan Losinski <losinski@wh2.tu-dresden.de>
Signed-off-by: David Henningsson <david.henningsson@canonical.com>
---
sound/pci/hda/patch_realtek.c | 25 +++++++++++++++++--------
1 files changed, 17 insertions(+), 8 deletions(-)
diff --git a/sound/pci/hda/patch_realtek.c b/sound/pci/hda/patch_realtek.c
index f1a03f2..dc67c5d 100644
--- a/sound/pci/hda/patch_realtek.c
+++ b/sound/pci/hda/patch_realtek.c
@@ -16006,9 +16006,12 @@ static int alc861_auto_create_multi_out_ctls(struct hda_codec *codec,
return err;
} else {
const char *name = pfx;
- if (!name)
+ int index = i;
+ if (!name) {
name = chname[i];
- err = __alc861_create_out_sw(codec, name, nid, i, 3);
+ index = 0;
+ }
+ err = __alc861_create_out_sw(codec, name, nid, index, 3);
if (err < 0)
return err;
}
@@ -17159,16 +17162,19 @@ static int alc861vd_auto_create_multi_out_ctls(struct alc_spec *spec,
return err;
} else {
const char *name = pfx;
- if (!name)
+ int index = i;
+ if (!name) {
name = chname[i];
+ index = 0;
+ }
err = __add_pb_vol_ctrl(spec, ALC_CTL_WIDGET_VOL,
- name, i,
+ name, index,
HDA_COMPOSE_AMP_VAL(nid_v, 3, 0,
HDA_OUTPUT));
if (err < 0)
return err;
err = __add_pb_sw_ctrl(spec, ALC_CTL_BIND_MUTE,
- name, i,
+ name, index,
HDA_COMPOSE_AMP_VAL(nid_s, 3, 2,
HDA_INPUT));
if (err < 0)
@@ -19217,12 +19223,15 @@ static int alc662_auto_create_multi_out_ctls(struct hda_codec *codec,
return err;
} else {
const char *name = pfx;
- if (!name)
+ int index = i;
+ if (!name) {
name = chname[i];
- err = __alc662_add_vol_ctl(spec, name, nid, i, 3);
+ index = 0;
+ }
+ err = __alc662_add_vol_ctl(spec, name, nid, index, 3);
if (err < 0)
return err;
- err = __alc662_add_sw_ctl(spec, name, mix, i, 3);
+ err = __alc662_add_sw_ctl(spec, name, mix, index, 3);
if (err < 0)
return err;
}
--
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
next prev parent reply other threads:[~2011-03-23 7:56 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-03-21 11:37 Problem and dirty Fix for hda-intel on ALC892 Jan Losinski
2011-03-21 21:44 ` David Henningsson
2011-03-21 23:13 ` Jan Losinski
2011-03-23 7:56 ` David Henningsson [this message]
2011-03-23 8:25 ` [PATCH] ALSA: HDA: Realtek: Avoid unnecessary volume control index on Surround/Side Takashi Iwai
2011-03-23 18:39 ` Jan Losinski
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=4D89A7B2.6050204@canonical.com \
--to=david.henningsson@canonical.com \
--cc=alsa-devel@alsa-project.org \
--cc=losinski@wh2.tu-dresden.de \
--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.