[alsa-devel] [RFC PATCH 1/2] ALSA: hda - Fix "PCM" name being used on one DAC when there are two DACs
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Signed-off-by: David Henningsson david.henningsson@canonical.com --- sound/pci/hda/hda_generic.c | 13 +++++++++++++ 1 file changed, 13 insertions(+)
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 64220c0..1d742ea 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -1038,6 +1038,19 @@ static const char *get_line_out_pfx(struct hda_codec *codec, int ch, break; *index = ch; return "Headphone"; + case AUTO_PIN_LINE_OUT: + /* This deals with the case where we have two DACs and + * one LO, one HP and one Speaker */ + if (!ch && cfg->speaker_outs && cfg->hp_outs) { + bool hp_lo_shared = !path_has_mixer(codec, spec->hp_paths[0], ctl_type); + bool spk_lo_shared = !path_has_mixer(codec, spec->speaker_paths[0], ctl_type); + if (hp_lo_shared && spk_lo_shared) + return spec->vmaster_mute.hook ? "PCM" : "Master"; + if (hp_lo_shared) + return "Headphone+LO"; + if (spk_lo_shared) + return "Speaker+LO"; + } }
/* for a single channel output, we don't have to name the channel */
In case there are speakers or headphones as well, anything that only covers the line out should not be labelled "PCM". Let's name it "Line Out" instead for clarity.
Signed-off-by: David Henningsson david.henningsson@canonical.com --- sound/pci/hda/hda_generic.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 1d742ea..c037bab 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -1055,7 +1055,7 @@ static const char *get_line_out_pfx(struct hda_codec *codec, int ch,
/* for a single channel output, we don't have to name the channel */ if (cfg->line_outs == 1 && !spec->multi_ios) - return "PCM"; + return "Line Out";
if (ch >= ARRAY_SIZE(channel_name)) { snd_BUG();
At Thu, 16 Oct 2014 15:33:45 +0200, David Henningsson wrote:
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Signed-off-by: David Henningsson david.henningsson@canonical.com
The changes look good. If this passes the tests and is confirmed to work with the real machine, let's merge them. As this is rather a fix, we can merge them to 3.18, too, IMO.
thanks,
Takashi
sound/pci/hda/hda_generic.c | 13 +++++++++++++ 1 file changed, 13 insertions(+)
diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 64220c0..1d742ea 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -1038,6 +1038,19 @@ static const char *get_line_out_pfx(struct hda_codec *codec, int ch, break; *index = ch; return "Headphone";
case AUTO_PIN_LINE_OUT:
/* This deals with the case where we have two DACs and
* one LO, one HP and one Speaker */
if (!ch && cfg->speaker_outs && cfg->hp_outs) {
bool hp_lo_shared = !path_has_mixer(codec, spec->hp_paths[0], ctl_type);
bool spk_lo_shared = !path_has_mixer(codec, spec->speaker_paths[0], ctl_type);
if (hp_lo_shared && spk_lo_shared)
return spec->vmaster_mute.hook ? "PCM" : "Master";
if (hp_lo_shared)
return "Headphone+LO";
if (spk_lo_shared)
return "Speaker+LO";
}
}
/* for a single channel output, we don't have to name the channel */
-- 1.9.1
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
seem there are two cases
1) business desktop with internal speaker 2) notebook with dock line out
On 2014-10-16 17:02, Raymond Yau wrote:
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1" when developing the patches.
I don't have any hardware available myself that exposes this behavior, but I can maybe fake one with hdajackretask, if that counts...
// David
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1" when developing the patches.
I don't have any hardware available myself that exposes this behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master volume/switch ?
hdajackretask won't help if the topology of the codecs are different
Seem the badness still prevent the driver to support surround 5.1 with three rear panel jacks, internal speaker and front panel headphone for Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or "Speaker+LO" ?
At Sat, 18 Oct 2014 20:33:49 +0800, Raymond Yau wrote:
In the scenario where there is one "Line Out", one "Speaker" and one "Headphone", and there are only two DACs, two outputs will share a DAC. Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1" when developing the patches.
I don't have any hardware available myself that exposes this behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master volume/switch ?
hdajackretask won't help if the topology of the codecs are different
Seem the badness still prevent the driver to support surround 5.1 with three rear panel jacks, internal speaker and front panel headphone for Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
Takashi
In the scenario where there is one "Line Out", one "Speaker" and
one
"Headphone", and there are only two DACs, two outputs will share a
DAC.
Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1"
when
developing the patches.
I don't have any hardware available myself that exposes this behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master volume/switch ?
hdajackretask won't help if the topology of the codecs are different
Seem the badness still prevent the driver to support surround 5.1 with three rear panel jacks, internal speaker and front panel headphone for Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
At Sun, 19 Oct 2014 07:02:07 +0800, Raymond Yau wrote:
In the scenario where there is one "Line Out", one "Speaker" and
one
"Headphone", and there are only two DACs, two outputs will share a
DAC.
Currently any mixer on such a DAC will get the "PCM" name, which is misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1"
when
developing the patches.
I don't have any hardware available myself that exposes this behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master volume/switch ?
hdajackretask won't help if the topology of the codecs are different
Seem the badness still prevent the driver to support surround 5.1 with three rear panel jacks, internal speaker and front panel headphone for Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
ALC662 has three DACs, so it's a different problem, if any. ALC269 and its variants have only two DACs.
Takashi
> > In the scenario where there is one "Line Out", one "Speaker"
and
one
> "Headphone", and there are only two DACs, two outputs will
share a
DAC.
> Currently any mixer on such a DAC will get the "PCM" name,
which is
> misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1"
when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround 5.1
with
three rear panel jacks, internal speaker and front panel headphone
for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
ALC662 has three DACs, so it's a different problem, if any. ALC269 and its variants have only two DACs.
These two patches not only affect those four channels hda codecs notebook with dock station or desktop with internal speaker, it also affect some codecs in hda-emu/codecs
1) two channels hda codec such as stac9200 (e.g Dell precision 490 workstation) 2) 8 channels codecs such as stac9228, cmi9880 (e.g. lg-lw60 and dell xps)
The proposed patches still not able to handle the case when line out , headphone and speaker share the same volume control
Refer to hardware mainteance manual of a58, there is only one internal speaker , it is most likely a mono speaker if it use a two pin internal speaker connector
http://www.desktopreview.com/default.asp?newsID=760&Review+Lenovo+ThinkC...
Here you can see the built-in speaker in the lower right
It is unlikely for stereo speaker to use two pin connector
Other Thinkcenter with 6 channels ad1986a has enough volume controls for line out, headphone and speaker
https://answers.launchpad.net/ubuntu/+source/alsa-driver/+question/146830
At Mon, 20 Oct 2014 09:10:05 +0800, Raymond Yau wrote:
> > > > In the scenario where there is one "Line Out", one "Speaker"
and
one
> > "Headphone", and there are only two DACs, two outputs will
share a
DAC.
> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> > specify what the volume actually controls. > > Are there any examples ? >
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1"
when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround 5.1
with
three rear panel jacks, internal speaker and front panel headphone
for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
ALC662 has three DACs, so it's a different problem, if any. ALC269 and its variants have only two DACs.
These two patches not only affect those four channels hda codecs notebook with dock station or desktop with internal speaker, it also affect some codecs in hda-emu/codecs
- two channels hda codec such as stac9200 (e.g Dell precision 490
workstation) 2) 8 channels codecs such as stac9228, cmi9880 (e.g. lg-lw60 and dell xps)
The proposed patches still not able to handle the case when line out , headphone and speaker share the same volume control
We need to test through all codecs and configs, but I thought the case 1 won't hit. This should still result in "PCM" volume.
Which problem does the latter case have? Do they have also shared volumes although they have more number of DACs than pins?
Refer to hardware mainteance manual of a58, there is only one internal speaker , it is most likely a mono speaker if it use a two pin internal speaker connector
http://www.desktopreview.com/default.asp?newsID=760&Review+Lenovo+ThinkC...
Here you can see the built-in speaker in the lower right
It is unlikely for stereo speaker to use two pin connector
Raymond, this is utterly irrelevant with the volume control assignment. Just open up a different discussion thread.
Takashi
On 2014-10-19 01:02, Raymond Yau wrote:
In the scenario where there is one "Line Out", one "Speaker"
and one
"Headphone", and there are only two DACs, two outputs will
share a DAC.
Currently any mixer on such a DAC will get the "PCM" name,
which is
misleading. Instead use "Headphone+LO" or "Speaker+LO" to better specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are different
Seem the badness still prevent the driver to support surround 5.1 with three rear panel jacks, internal speaker and front panel headphone for Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover - after all, it's mostly a band aid given the lack of topology information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
> > In the scenario where there is one "Line Out", one "Speaker"
and one
> "Headphone", and there are only two DACs, two outputs will
share a DAC.
> Currently any mixer on such a DAC will get the "PCM" name,
which is
> misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> specify what the volume actually controls.
Are there any examples ?
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround 5.1
with
three rear panel jacks, internal speaker and front panel headphone
for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover -
after all, it's mostly a band aid given the lack of topology information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
At Mon, 20 Oct 2014 17:55:23 +0800, Raymond Yau wrote:
> > > > In the scenario where there is one "Line Out", one "Speaker"
and one
> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> > specify what the volume actually controls. > > Are there any examples ? >
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround 5.1
with
three rear panel jacks, internal speaker and front panel headphone
for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover -
after all, it's mostly a band aid given the lack of topology information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
Takashi
>> > >> > In the scenario where there is one "Line Out", one
"Speaker"
and one
>> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
>> > Currently any mixer on such a DAC will get the "PCM" name,
which is
>> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
>> > specify what the volume actually controls. >> >> Are there any examples ? >> > > I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches. > > I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts... >
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround
5.1
with
three rear panel jacks, internal speaker and front panel
headphone
for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
-
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
At Mon, 20 Oct 2014 19:31:59 +0800, Raymond Yau wrote:
> > >> > > >> > In the scenario where there is one "Line Out", one
"Speaker"
and one
> >> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
> >> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> >> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> >> > specify what the volume actually controls. > >> > >> Are there any examples ? > >> > > > > I used "hda-emu >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
> developing the patches. > > > > I don't have any hardware available myself that exposes this
behavior,
> but I can maybe fake one with hdajackretask, if that counts... > > > > How about adding these names to slaves of virtual master
volume/switch ?
> > hdajackretask won't help if the topology of the codecs are
different
> > Seem the badness still prevent the driver to support surround
5.1
with
> three rear panel jacks, internal speaker and front panel
headphone
for
> Thinkcenter A58 using alc662 > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
> "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
Takashi
> > > > >> > > > >> > In the scenario where there is one "Line Out", one
"Speaker"
and one > > >> > "Headphone", and there are only two DACs, two outputs
will
share a DAC. > > >> > Currently any mixer on such a DAC will get the "PCM"
name,
which is > > >> > misleading. Instead use "Headphone+LO" or "Speaker+LO"
to
better
> > >> > specify what the volume actually controls. > > >> > > >> Are there any examples ? > > >> > > > > > > I used "hda-emu > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when > > developing the patches. > > > > > > I don't have any hardware available myself that exposes
this
behavior, > > but I can maybe fake one with hdajackretask, if that
counts...
> > > > > > > How about adding these names to slaves of virtual master volume/switch ? > > > > hdajackretask won't help if the topology of the codecs are
different
> > > > Seem the badness still prevent the driver to support
surround
5.1
with
> > three rear panel jacks, internal speaker and front panel
headphone
for
> > Thinkcenter A58 using alc662 > > > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > > > Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or > > "Speaker+LO" ? > > The problem is just the lack of DACs, so it cannot cover all
three
> outputs, no matter how the pins are chosen. That is, it's no
6
> channels at all but 4 channels at most. > >
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not
cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a
*regression*? If
so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
At Mon, 20 Oct 2014 22:24:40 +0800, Raymond Yau wrote:
> > > > > > > > >> > > > > >> > In the scenario where there is one "Line Out", one
"Speaker"
> and one > > > >> > "Headphone", and there are only two DACs, two outputs
will
> share a DAC. > > > >> > Currently any mixer on such a DAC will get the "PCM"
name,
> which is > > > >> > misleading. Instead use "Headphone+LO" or "Speaker+LO"
to
better
> > > >> > specify what the volume actually controls. > > > >> > > > >> Are there any examples ? > > > >> > > > > > > > > I used "hda-emu > > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
> 1" when > > > developing the patches. > > > > > > > > I don't have any hardware available myself that exposes
this
> behavior, > > > but I can maybe fake one with hdajackretask, if that
counts...
> > > > > > > > > > How about adding these names to slaves of virtual master > volume/switch ? > > > > > > hdajackretask won't help if the topology of the codecs are
different
> > > > > > Seem the badness still prevent the driver to support
surround
5.1
with
> > > three rear panel jacks, internal speaker and front panel
headphone
for
> > > Thinkcenter A58 using alc662 > > > > > > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > > > > > Why 3stack desktops with 6 channels codecs not using > "Headphone+LO" or > > > "Speaker+LO" ? > > > > The problem is just the lack of DACs, so it cannot cover all
three
> > outputs, no matter how the pins are chosen. That is, it's no
6
> > channels at all but 4 channels at most. > > > > > > http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/ > > The technical specification of a58 > > 2 pin internal speaker connector > Alc662 5.1 > > https://bbs.archlinux.org/viewtopic.php?id=156433 > > Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not
cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a
*regression*? If
so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
I thought it's a jack retask issue? You commented so in kernel bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=70791
Takashi
>> >> >> > > >> > > >> > >> > > >> > In the scenario where there is one "Line Out", one
"Speaker"
>> and one >> > > >> > "Headphone", and there are only two DACs, two
outputs
will
>> share a DAC. >> > > >> > Currently any mixer on such a DAC will get the
"PCM"
name,
>> which is >> > > >> > misleading. Instead use "Headphone+LO" or
"Speaker+LO"
to
better >> > > >> > specify what the volume actually controls. >> > > >> >> > > >> Are there any examples ? >> > > >> >> > > > >> > > > I used "hda-emu >> > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
>> 1" when >> > > developing the patches. >> > > > >> > > > I don't have any hardware available myself that
exposes
this
>> behavior, >> > > but I can maybe fake one with hdajackretask, if that
counts...
>> > > > >> > > >> > > How about adding these names to slaves of virtual master >> volume/switch ? >> > > >> > > hdajackretask won't help if the topology of the codecs
are
different >> > > >> > > Seem the badness still prevent the driver to support
surround
5.1
with >> > > three rear panel jacks, internal speaker and front panel
headphone
for >> > > Thinkcenter A58 using alc662 >> > > >> > > >>
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
>> > > >> > > Why 3stack desktops with 6 channels codecs not using >> "Headphone+LO" or >> > > "Speaker+LO" ? >> > >> > The problem is just the lack of DACs, so it cannot cover
all
three
>> > outputs, no matter how the pins are chosen. That is,
it's no
6
>> > channels at all but 4 channels at most. >> > >> > >> >>
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
>> >> The technical specification of a58 >> >> 2 pin internal speaker connector >> Alc662 5.1 >> >> https://bbs.archlinux.org/viewtopic.php?id=156433 >> >> Seem windows support surround 5.1 > > > Raymond, there can certainly be cases which this patch does
not
cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a
*regression*? If
so, could you point me to alsa-info for the machine where this
patch
causes
a regression? >
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support
independent
headphone
This mean the driver should not create "Lineout+HP" Playback
volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it
easily
via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear
jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
I thought it's a jack retask issue? You commented so in kernel bugzilla: https://bugzilla.kernel.org/show_bug.cgi?id=70791
The other cases which may also need share volume control when the jacks are retasked
1) The driver hack the pin default of those Dell xps series notebooks to support dual headphone , the original pin defaults are line out, hp, mic at same location for external 5.1 speaker and with internal speaker with stac9228
2) those notebook with four jacks ( headphone, line out , mic and line in ) external 7.1 and internal speaker i.e. previous model "targa8ch"
3) Dell Alienware 14,17 and 18 have three jacks : headset, headphone and mic jack and support ext 5.1 speakers and internal 2.1 speaker with alc668
On Mon, Oct 20, 2014 at 8:24 AM, Raymond Yau superquad.vortex2@gmail.com wrote:
> > > > > > > > >> > > > > >> > In the scenario where there is one "Line Out", one
"Speaker"
> and one > > > >> > "Headphone", and there are only two DACs, two outputs > will > share a DAC. > > > >> > Currently any mixer on such a DAC will get the "PCM" > name, > which is > > > >> > misleading. Instead use "Headphone+LO" or "Speaker+LO" > to
better
> > > >> > specify what the volume actually controls. > > > >> > > > >> Are there any examples ? > > > >> > > > > > > > > I used "hda-emu > > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
> 1" when > > > developing the patches. > > > > > > > > I don't have any hardware available myself that exposes > this > behavior, > > > but I can maybe fake one with hdajackretask, if that > counts... > > > > > > > > > > How about adding these names to slaves of virtual master > volume/switch ? > > > > > > hdajackretask won't help if the topology of the codecs are
different
> > > > > > Seem the badness still prevent the driver to support > surround
5.1
with
> > > three rear panel jacks, internal speaker and front panel
headphone
for
> > > Thinkcenter A58 using alc662 > > > > > > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > > > > > Why 3stack desktops with 6 channels codecs not using > "Headphone+LO" or > > > "Speaker+LO" ? > > > > The problem is just the lack of DACs, so it cannot cover all > three > > outputs, no matter how the pins are chosen. That is, it's no > 6 > > channels at all but 4 channels at most. > > > > > > http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/ > > The technical specification of a58 > > 2 pin internal speaker connector > Alc662 5.1 > > https://bbs.archlinux.org/viewtopic.php?id=156433 > > Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
As I mentioned on Bugzilla, that problem ended up being due to some kind of motherboard defect in the particular machine. On the replacement 800 G1 machine, the headphone jack works fine. I can't really say whether or not dual independent audio streams work, though.
>> >> >> > > >> > > >> > >> > > >> > In the scenario where there is one "Line Out", one
"Speaker"
>> and one >> > > >> > "Headphone", and there are only two DACs, two
outputs
>> will >> share a DAC. >> > > >> > Currently any mixer on such a DAC will get the "PCM" >> name, >> which is >> > > >> > misleading. Instead use "Headphone+LO" or
"Speaker+LO"
>> to better >> > > >> > specify what the volume actually controls. >> > > >> >> > > >> Are there any examples ? >> > > >> >> > > > >> > > > I used "hda-emu >> > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
>> 1" when >> > > developing the patches. >> > > > >> > > > I don't have any hardware available myself that exposes >> this >> behavior, >> > > but I can maybe fake one with hdajackretask, if that >> counts... >> > > > >> > > >> > > How about adding these names to slaves of virtual master >> volume/switch ? >> > > >> > > hdajackretask won't help if the topology of the codecs
are
different >> > > >> > > Seem the badness still prevent the driver to support >> surround
5.1
with >> > > three rear panel jacks, internal speaker and front panel
headphone
for >> > > Thinkcenter A58 using alc662 >> > > >> > > >>
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
>> > > >> > > Why 3stack desktops with 6 channels codecs not using >> "Headphone+LO" or >> > > "Speaker+LO" ? >> > >> > The problem is just the lack of DACs, so it cannot cover
all
>> three >> > outputs, no matter how the pins are chosen. That is, it's
no
>> 6 >> > channels at all but 4 channels at most. >> > >> > >> >>
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
>> >> The technical specification of a58 >> >> 2 pin internal speaker connector >> Alc662 5.1 >> >> https://bbs.archlinux.org/viewtopic.php?id=156433 >> >> Seem windows support surround 5.1 > > > Raymond, there can certainly be cases which this patch does not > cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this
patch
causes
a regression? >
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support
independent
headphone
This mean the driver should not create "Lineout+HP" Playback
volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it
easily
via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
As I mentioned on Bugzilla, that problem ended up being due to some kind of motherboard defect in the particular machine. On the replacement 800 G1 machine, the headphone jack works fine. I can't really say whether or not dual independent audio streams work, though.
If your prodesk 800 g1 are still using alc221, you can disable the speaker node 0x17 by hda-jack-retask and add hint indep_hp=1 to hda-jack-retask.fw
[Hint] indep_hp=1
or
in hda/hda_generic.c
Force the driver to add badness when assign dac to speaker first by
if (spec-indep_hp && !indep_hp_possible(codec)) badness += BAD_NO_INDEP_HP; + if (cfg->hp_outs > 0 && cfg->line_outs > 0) + if (get_defcfg_location(snd_hda_codec_get_pincfg(codec, cfg->line_out_pins[0])) == AC_JACK_LOC_REAR) + if (fill_hardwired) + badness += BAD_NO_INDEP_HP;
Driver create volume control for line out instead of speaker first
Driver create "Speaker+LO" instead of "Headphone+LO" when you apply david's patch
and add the following to patch_alc269 in patch_realtek.c
spec->gen.indep_hp=1;
The driver will create
device 2 alt analog
and independent hp switch
You can play another audio stream to device 2 while playing stereo stream to line out through device 0 at the same time when independent hp switch is "ON"
Assume alc221 is at card 1
speaker-test -c2 -D hw:1,0 -t wav
aplay -v -D hw:1,2 stereo.wav
> >> > > > >> > > >> > > >> > > >> > In the scenario where there is one "Line Out", one
"Speaker"
> >> and one > >> > > >> > "Headphone", and there are only two DACs, two
outputs
> >> will > >> share a DAC. > >> > > >> > Currently any mixer on such a DAC will get the
"PCM"
> >> name, > >> which is > >> > > >> > misleading. Instead use "Headphone+LO" or
"Speaker+LO"
> >> to > better > >> > > >> > specify what the volume actually controls. > >> > > >> > >> > > >> Are there any examples ? > >> > > >> > >> > > > > >> > > > I used "hda-emu > >> > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
> >> 1" when > >> > > developing the patches. > >> > > > > >> > > > I don't have any hardware available myself that
exposes
> >> this > >> behavior, > >> > > but I can maybe fake one with hdajackretask, if that > >> counts... > >> > > > > >> > > > >> > > How about adding these names to slaves of virtual
master
> >> volume/switch ? > >> > > > >> > > hdajackretask won't help if the topology of the codecs
are
> different > >> > > > >> > > Seem the badness still prevent the driver to support > >> surround
5.1
> with > >> > > three rear panel jacks, internal speaker and front
panel
headphone
> for > >> > > Thinkcenter A58 using alc662 > >> > > > >> > > > >> >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> >> > > > >> > > Why 3stack desktops with 6 channels codecs not using > >> "Headphone+LO" or > >> > > "Speaker+LO" ? > >> > > >> > The problem is just the lack of DACs, so it cannot cover
all
> >> three > >> > outputs, no matter how the pins are chosen. That is,
it's no
> >> 6 > >> > channels at all but 4 channels at most. > >> > > >> > > >> > >>
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
> >> > >> The technical specification of a58 > >> > >> 2 pin internal speaker connector > >> Alc662 5.1 > >> > >> https://bbs.archlinux.org/viewtopic.php?id=156433 > >> > >> Seem windows support surround 5.1 > > > > > > Raymond, there can certainly be cases which this patch does
not
> > cover
> after all, it's mostly a band aid given the lack of topology
information -
> but do you see cases where this patch actually causes a > *regression*? If > so, could you point me to alsa-info for the machine where this
patch
causes
> a regression? > > > >
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
> > I expect those desktop with 2+2 HD Audio codec support
independent
headphone
> > This mean the driver should not create "Lineout+HP" Playback
volume
> > Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it
easily
via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to
allow
independent audio streams to be sent to/from the front and rear
jacks
This is the implementation detail and it's a matter of taste which should be dependent and which not. There is no bible here.
You can forcibly do that by a fixed DAC assignment (or add some badness) if you want, too...
http://mailman.alsa-project.org/pipermail/alsa-devel/2014-February/072775.ht...
Seem headphone not working properly on hp prodesk 600 g1
As I mentioned on Bugzilla, that problem ended up being due to some kind of motherboard defect in the particular machine. On the replacement 800 G1 machine, the headphone jack works fine. I can't really say whether or not dual independent audio streams work, though.
If your prodesk 800 g1 are still using alc221, you can disable the
speaker node 0x17 by hda-jack-retask and add hint indep_hp=1 to hda-jack-retask.fw
[Hint] indep_hp=1
or
in hda/hda_generic.c
Force the driver to add badness when assign dac to speaker first by
if (spec-indep_hp && !indep_hp_possible(codec)) badness += BAD_NO_INDEP_HP;
- if (cfg->hp_outs > 0 && cfg->line_outs > 0)
if (get_defcfg_location(snd_hda_codec_get_pincfg(codec,
cfg->line_out_pins[0])) == AC_JACK_LOC_REAR)
if (fill_hardwired)
badness += BAD_NO_INDEP_HP;
Driver create volume control for line out instead of speaker first
Driver create "Speaker+LO" instead of "Headphone+LO" when you apply
david's patch
and add the following to patch_alc269 in patch_realtek.c
spec->gen.indep_hp=1;
The driver will create
device 2 alt analog
and independent hp switch
You can play another audio stream to device 2 while playing stereo stream
to line out through device 0 at the same time when independent hp switch is "ON"
Assume alc221 is at card 1
speaker-test -c2 -D hw:1,0 -t wav
aplay -v -D hw:1,2 stereo.wav
To ensure independent hp control not add to those notebooks with dock line out
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986
static bool indep_hp_possible(struct hda_codec *codec)
+ if (get_defcfg_location(snd_hda_codec_get_pincfg(codec, cfg->line_out_pins[0])) != AC_JACK_LOC_REAR) + return false;
> > > > >> > > > >> > In the scenario where there is one "Line Out", one
"Speaker"
and one > > >> > "Headphone", and there are only two DACs, two outputs
will
share a DAC. > > >> > Currently any mixer on such a DAC will get the "PCM"
name,
which is > > >> > misleading. Instead use "Headphone+LO" or "Speaker+LO"
to
better
> > >> > specify what the volume actually controls. > > >> > > >> Are there any examples ? > > >> > > > > > > I used "hda-emu > >
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when > > developing the patches. > > > > > > I don't have any hardware available myself that exposes
this
behavior, > > but I can maybe fake one with hdajackretask, if that
counts...
> > > > > > > How about adding these names to slaves of virtual master volume/switch ? > > > > hdajackretask won't help if the topology of the codecs are
different
> > > > Seem the badness still prevent the driver to support
surround
5.1
with
> > three rear panel jacks, internal speaker and front panel
headphone
for
> > Thinkcenter A58 using alc662 > > > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > > > Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or > > "Speaker+LO" ? > > The problem is just the lack of DACs, so it cannot cover all
three
> outputs, no matter how the pins are chosen. That is, it's no
6
> channels at all but 4 channels at most. > >
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not
cover
after all, it's mostly a band aid given the lack of topology
information -
but do you see cases where this patch actually causes a
*regression*? If
so, could you point me to alsa-info for the machine where this patch
causes
a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
Do you have a pincfg representing this? Then we can check it easily via hda-emu.
http://git.kernel.org/cgit/linux/kernel/git/tiwai/hda-emu.git/tree/codecs/ca...
Both HP (0x21) and LO (0x14) can share the same DAC (0x03) over mixer (0x0d). So the statement above "Line out and headphone cannot share same DAC" isn't correct.
Refer to user manual
Multi-streaming can be enabled in the Realtek control panel to allow independent audio streams to be sent to/from the front and rear jacks
https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pc...
Do it mean that the volume control should be named as "Headphone+Side" ?
On 2014-10-20 11:55, Raymond Yau wrote:
> > > > In the scenario where there is one "Line Out", one "Speaker"
and one
> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> > specify what the volume actually controls. > > Are there any examples ? >
I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches.
I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts...
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround
5.1 with
three rear panel jacks, internal speaker and front panel
headphone for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4 http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for more testing first?
At Mon, 20 Oct 2014 11:59:30 +0200, David Henningsson wrote:
On 2014-10-20 11:55, Raymond Yau wrote:
>> > >> > In the scenario where there is one "Line Out", one "Speaker"
and one
>> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
>> > Currently any mixer on such a DAC will get the "PCM" name,
which is
>> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
>> > specify what the volume actually controls. >> >> Are there any examples ? >> > > I used "hda-emu codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches. > > I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts... >
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround
5.1 with
three rear panel jacks, internal speaker and front panel
headphone for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4 http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for more testing first?
I'll test a bit more. I have a machine that is affected by this issue, so I can test on a real machine.
How about the changes in PA side, BTW? Is it ready?
Takashi
On 2014-10-20 12:02, Takashi Iwai wrote:
At Mon, 20 Oct 2014 11:59:30 +0200, David Henningsson wrote:
On 2014-10-20 11:55, Raymond Yau wrote:
> > >> > > >> > In the scenario where there is one "Line Out", one "Speaker"
and one
> >> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
> >> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> >> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> >> > specify what the volume actually controls. > >> > >> Are there any examples ? > >> > > > > I used "hda-emu > codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
> developing the patches. > > > > I don't have any hardware available myself that exposes this
behavior,
> but I can maybe fake one with hdajackretask, if that counts... > > > > How about adding these names to slaves of virtual master
volume/switch ?
> > hdajackretask won't help if the topology of the codecs are
different
> > Seem the badness still prevent the driver to support surround
5.1 with
> three rear panel jacks, internal speaker and front panel
headphone for
> Thinkcenter A58 using alc662 > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
> "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4 http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for more testing first?
I'll test a bit more. I have a machine that is affected by this issue, so I can test on a real machine.
How about the changes in PA side, BTW? Is it ready?
I will cook up a quick patch once you have merged. But there will not be any big regression: we already control the vmaster, which in turn controls the hw volume of the DAC. So I will expect things to just work, assume the new controls will be initialized correctly. I'm attaching an (untested) alsa-utils patch for that.
At Mon, 20 Oct 2014 12:15:37 +0200, David Henningsson wrote:
On 2014-10-20 12:02, Takashi Iwai wrote:
At Mon, 20 Oct 2014 11:59:30 +0200, David Henningsson wrote:
On 2014-10-20 11:55, Raymond Yau wrote:
> > > > >> > > > >> > In the scenario where there is one "Line Out", one "Speaker" and one > > >> > "Headphone", and there are only two DACs, two outputs will share a DAC. > > >> > Currently any mixer on such a DAC will get the "PCM" name, which is > > >> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> > >> > specify what the volume actually controls. > > >> > > >> Are there any examples ? > > >> > > > > > > I used "hda-emu > > codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i 1" when > > developing the patches. > > > > > > I don't have any hardware available myself that exposes this behavior, > > but I can maybe fake one with hdajackretask, if that counts... > > > > > > > How about adding these names to slaves of virtual master volume/switch ? > > > > hdajackretask won't help if the topology of the codecs are
different
> > > > Seem the badness still prevent the driver to support surround
5.1 with
> > three rear panel jacks, internal speaker and front panel
headphone for
> > Thinkcenter A58 using alc662 > > > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > > > Why 3stack desktops with 6 channels codecs not using "Headphone+LO" or > > "Speaker+LO" ? > > The problem is just the lack of DACs, so it cannot cover all three > outputs, no matter how the pins are chosen. That is, it's no 6 > channels at all but 4 channels at most. > >
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4 http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for more testing first?
I'll test a bit more. I have a machine that is affected by this issue, so I can test on a real machine.
How about the changes in PA side, BTW? Is it ready?
I will cook up a quick patch once you have merged.
Both kernel and PA patches shouldn't give regressions and should be applicable individually, so you don't have to wait for me merging it. I'm fine with the new control names, so just go ahead.
But there will not be any big regression: we already control the vmaster, which in turn controls the hw volume of the DAC. So I will expect things to just work, assume the new controls will be initialized correctly. I'm attaching an (untested) alsa-utils patch for that.
Actually these initializations are superfluous when they are vmaster slaves. Nowadays the slaves are initialized as 0dB.
But, in your patch, one piece is missing: the addition to slave controls. The additional fix patch is below.
With a quick test, it seems working fine.
thanks,
Takashi
--- diff --git a/sound/pci/hda/hda_generic.c b/sound/pci/hda/hda_generic.c index 3ffbf94a6ce6..06d721085e72 100644 --- a/sound/pci/hda/hda_generic.c +++ b/sound/pci/hda/hda_generic.c @@ -4537,7 +4537,7 @@ static const char * const slave_pfxs[] = { "CLFE", "Bass Speaker", "PCM", "Speaker Front", "Speaker Surround", "Speaker CLFE", "Speaker Side", "Headphone Front", "Headphone Surround", "Headphone CLFE", - "Headphone Side", + "Headphone Side", "Headphone+LO", "Speaker+LO", NULL, };
At Mon, 20 Oct 2014 12:02:04 +0200, Takashi Iwai wrote:
At Mon, 20 Oct 2014 11:59:30 +0200, David Henningsson wrote:
On 2014-10-20 11:55, Raymond Yau wrote:
> > >> > > >> > In the scenario where there is one "Line Out", one "Speaker"
and one
> >> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
> >> > Currently any mixer on such a DAC will get the "PCM" name,
which is
> >> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
> >> > specify what the volume actually controls. > >> > >> Are there any examples ? > >> > > > > I used "hda-emu > codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
> developing the patches. > > > > I don't have any hardware available myself that exposes this
behavior,
> but I can maybe fake one with hdajackretask, if that counts... > > > > How about adding these names to slaves of virtual master
volume/switch ?
> > hdajackretask won't help if the topology of the codecs are
different
> > Seem the badness still prevent the driver to support surround
5.1 with
> three rear panel jacks, internal speaker and front panel
headphone for
> Thinkcenter A58 using alc662 > >
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
> > Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
> "Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4 http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
I expect those desktop with 2+2 HD Audio codec support independent headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for more testing first?
I'll test a bit more. I have a machine that is affected by this issue, so I can test on a real machine.
FYI, the patches are merged now to for-next branch and pushed out.
Takashi
>> > >> > In the scenario where there is one "Line Out", one
"Speaker"
and one
>> > "Headphone", and there are only two DACs, two outputs will
share a DAC.
>> > Currently any mixer on such a DAC will get the "PCM" name,
which is
>> > misleading. Instead use "Headphone+LO" or "Speaker+LO" to
better
>> > specify what the volume actually controls. >> >> Are there any examples ? >> > > I used "hda-emu
codecs/canonical/alc3226-dell-precision-m2800-ccert-201404-14986 -i
1" when
developing the patches. > > I don't have any hardware available myself that exposes this
behavior,
but I can maybe fake one with hdajackretask, if that counts... >
How about adding these names to slaves of virtual master
volume/switch ?
hdajackretask won't help if the topology of the codecs are
different
Seem the badness still prevent the driver to support surround
5.1 with
three rear panel jacks, internal speaker and front panel
headphone for
Thinkcenter A58 using alc662
https://www.mail-archive.com/alsa-user@lists.sourceforge.net/msg29203.html
Why 3stack desktops with 6 channels codecs not using
"Headphone+LO" or
"Speaker+LO" ?
The problem is just the lack of DACs, so it cannot cover all three outputs, no matter how the pins are chosen. That is, it's no 6 channels at all but 4 channels at most.
http://shop.lenovo.com/us/en/desktops/thinkcentre/a-series/a58/
The technical specification of a58
2 pin internal speaker connector Alc662 5.1
https://bbs.archlinux.org/viewtopic.php?id=156433
Seem windows support surround 5.1
Raymond, there can certainly be cases which this patch does not cover
- after all, it's mostly a band aid given the lack of topology
information - but do you see cases where this patch actually causes a *regression*? If so, could you point me to alsa-info for the machine where this patch causes a regression?
www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&PFid=27&Level=5&Conn=4
<
http://www.realtek.com.tw/products/productsView.aspx?Langid=1&PNid=24&am...
I expect those desktop with 2+2 HD Audio codec support independent
headphone
This mean the driver should not create "Lineout+HP" Playback volume
Line out and headphone cannot share same DAC
I doubt that, but if they cannot share the same DAC, that needs to be
addressed in a separate patch. This patch just deals with the naming, given that the previous logic has determined that headphone and Line out should share the same DAC.
Takashi, are you planning to apply this patch? Or are you looking for
more testing first?
Do you have the machine which has "Headphone+LO" ?
There is no headphone playback volume
speaker is muted when either headphone or line out is plugged and unmuted when both jacks are unplugged
participants (4)
-
David Henningsson
-
Raymond Yau
-
Robert Hancock
-
Takashi Iwai