All of lore.kernel.org
 help / color / mirror / Atom feed
* No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
@ 2013-12-19 10:05 Nicolas Kalkhof
  2013-12-22 12:47 ` Raymond Yau
  0 siblings, 1 reply; 10+ messages in thread
From: Nicolas Kalkhof @ 2013-12-19 10:05 UTC (permalink / raw)
  To: alsa-devel

   Hello, I have a Lenovo ThinkPad T440p laptop connected to an Ultra
   Docking Station. Sound works fine over Laptop Speakers and the 3,5mm
   Headphone Jack. However that is not the case when I connect the T440p
   to the Docking station Type 40A10065EU and use the Headphone Jack at
   the Dock. I've tried loading the alsa module with the "model=thinkpad"
   or "model=lenovo-dock"  without success. My Distro is Gentoo and the
   Kernel is 3.13-rc4.

   alsa.conf:
   # ALSA portion
   alias char-major-116 snd
   # OSS/Free portion
   alias char-major-14 soundcore
   ##
   ## IMPORTANT:
   ## You need to customise this section for your specific sound card(s)
   ## and then run `update-modules' command.
   ## Read alsa-driver's INSTALL file in /usr/share/doc for more info.
   ##
   ##  ALSA portion
   ## alias snd-card-0 snd-interwave
   ## alias snd-card-1 snd-ens1371
   ##  OSS/Free portion
   ## alias sound-slot-0 snd-card-0
   ## alias sound-slot-1 snd-card-1
   ##
   # OSS/Free portion - card #1
   alias sound-service-0-0 snd-mixer-oss
   alias sound-service-0-1 snd-seq-oss
   alias sound-service-0-3 snd-pcm-oss
   alias sound-service-0-8 snd-seq-oss
   alias sound-service-0-12 snd-pcm-oss
   ##  OSS/Free portion - card #2
   ## alias sound-service-1-0 snd-mixer-oss
   ## alias sound-service-1-3 snd-pcm-oss
   ## alias sound-service-1-12 snd-pcm-oss
   alias /dev/mixer snd-mixer-oss
   alias /dev/dsp snd-pcm-oss
   alias /dev/midi snd-seq-oss
   # Set this to the correct number of cards.
   options snd cards_limit=1
   #options snd-hda-intel model=thinkpad
   options snd-hda-intel model=thinkpad enable=1 index=0
   options snd-hda-intel model=hdmi enable=1 index=-2

   lspci -vv and dmesg goes here: [1]http://pastebin.ca/2510939

   Any Help?

References

   1. http://pastebin.ca/2510939

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2013-12-19 10:05 No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop Nicolas Kalkhof
@ 2013-12-22 12:47 ` Raymond Yau
  2013-12-22 13:41   ` Nicolas Kalkhof
                     ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Raymond Yau @ 2013-12-22 12:47 UTC (permalink / raw)
  To: Nicolas Kalkhof; +Cc: alsa-devel

>
>    Hello, I have a Lenovo ThinkPad T440p laptop connected to an Ultra
>    Docking Station. Sound works fine over Laptop Speakers and the 3,5mm
>    Headphone Jack. However that is not the case when I connect the T440p
>    to the Docking station Type 40A10065EU and use the Headphone Jack at
>    the Dock. I've tried loading the alsa module with the "model=thinkpad"
>    or "model=lenovo-dock"  without success. My Distro is Gentoo and the
>    Kernel is 3.13-rc4.

Do your dock station has one headphone and one mic Jack or just one combo
headset Jack ?

http://support.lenovo.com/en_US/detail.page?DocID=PD029485

Connect headphones or a headset that has a 3.5-mm (0.14-inch), 4-pole plug
to the audio connector to listen to the sound from the computer.

Remove the following lines

>    options snd cards_limit=1
>    #options snd-hda-intel model=thinkpad
>    options snd-hda-intel model=thinkpad enable=1 index=0
>    options snd-hda-intel model=hdmi enable=1 index=-2
>

https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_realtek.c?id=108cc108a3bb42fe4705df1317ff98e1e29428a6

lenovo-dock expect dock headphone Jack and dock Mic Jack ?

Post the output of alsa-info.sh when thinkpad is docked and not docked with
headphone pluggedd and unplugged

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2013-12-22 12:47 ` Raymond Yau
@ 2013-12-22 13:41   ` Nicolas Kalkhof
  2013-12-22 13:50   ` Nicolas Kalkhof
  2014-02-12 21:01   ` Bernhard
  2 siblings, 0 replies; 10+ messages in thread
From: Nicolas Kalkhof @ 2013-12-22 13:41 UTC (permalink / raw)
  To: Raymond Yau; +Cc: alsa-devel

> Do your dock station has one headphone and one mic Jack or just one combo
> headset Jack ?
> Connect headphones or a headset that has a 3.5-mm (0.14-inch), 4-pole plug
> to the audio connector to listen to the sound from the computer.

The Docking station as well as the Notebook has just one Stereo/Mic Combo Audio Jack. I've tried various Headset with 4-Pole and 3-pole plugs. They all work fine on the Notebook but not with the Docking station (40A20090EU). However the Laptop speakers mute as soon as I plug the Headset in the Docking Station so it seems that the driver is somehow aware of it!

> Remove the following lines
> options snd cards_limit=1
> #options snd-hda-intel model=thinkpad
> options snd-hda-intel model=thinkpad enable=1 index=0
> options snd-hda-intel model=hdmi enable=1 index=-2

I already tried that no success. Without the index parameter alsa switches to the HDMI output by default.

> https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_realtek.c?id=108cc108a3bb42fe4705df1317ff98e1e29428a6[https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_realtek.c?id=108cc108a3bb42fe4705df1317ff98e1e29428a6]

> lenovo-dock expect dock headphone Jack and dock Mic Jack ?

I guess so since there is only one plug. Again all works well when I use the Notebooks 3.5mm plug.

> Post the output of alsa-info.sh when thinkpad is docked and not docked with
> headphone pluggedd and unplugged

Well here I have another problem. The script doesn't get very far:
ALSA Information Script v 0.4.62
--------------------------------

This script visits the following commands/files to collect diagnostic
information about your ALSA installation and sound related hardware.

  dmesg
  lspci
  lsmod
  aplay
  amixer
  alsactl
  /proc/asound/
  /sys/class/sound/
  ~/.asoundrc (etc.)

See 'alsa-info.sh --help' for command line options.

cat: /proc/asound/modules: No such file or directory

Strange thing, /proc/asound exists:
HDMI  PCH  card0  card1  cards  devices  pcm  timers  version

I've compiled the drivers als modules and they are loaded!

lsmod shows:
thinkpad_acpi          52900  1
i915                  666771  5
snd_hda_intel          26867  6
snd_hda_codec         116484  2 snd_hda_codec_realtek,snd_hda_intel
cfbfillrect             3650  1 i915
cfbimgblt               2039  1 i915
cfbcopyarea             3350  1 i915
snd_pcm                65126  4 snd_hda_codec,snd_hda_intel
drm_kms_helper         27044  1 i915
intel_gtt              11928  1 i915
snd_page_alloc          6690  2 snd_pcm,snd_hda_intel

cat pcm:
00-00: ALC292 Analog : ALC292 Analog : playback 1 : capture 1
01-03: ID 2807 Digital : ID 2807 Digital : playback 1

cat cards:
 0 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf0634000 irq 44
 1 [HDMI           ]: HDA-Intel - HDA Intel HDMI
                     HDA Intel HDMI at 0xf0630000 irq 46

Any further help?

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2013-12-22 12:47 ` Raymond Yau
  2013-12-22 13:41   ` Nicolas Kalkhof
@ 2013-12-22 13:50   ` Nicolas Kalkhof
  2014-02-12 21:01   ` Bernhard
  2 siblings, 0 replies; 10+ messages in thread
From: Nicolas Kalkhof @ 2013-12-22 13:50 UTC (permalink / raw)
  To: Raymond Yau; +Cc: alsa-devel


> Post the output of alsa-info.sh when thinkpad is docked and not docked with
> headphone pluggedd and unplugged

Ok it seems that the script produces some more output after all when I upload the data. Here it is:
http://www.alsa-project.org/db/?f=7492d76dcae8320259b56478cfd846850f6edfaa

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2013-12-22 12:47 ` Raymond Yau
  2013-12-22 13:41   ` Nicolas Kalkhof
  2013-12-22 13:50   ` Nicolas Kalkhof
@ 2014-02-12 21:01   ` Bernhard
  2014-02-13  2:15     ` Raymond Yau
  2 siblings, 1 reply; 10+ messages in thread
From: Bernhard @ 2014-02-12 21:01 UTC (permalink / raw)
  To: alsa-devel

Raymond Yau <superquad.vortex2 <at> gmail.com> writes:
> 
> Post the output of alsa-info.sh when thinkpad is docked and not docked with
> headphone pluggedd and unplugged
> 

I created the output you requested (Lenovo ThinkPad T440p in UltraDock, no 
sound when docked via dock jack but notebook speakers are also mute).

not docked: http://pastebin.com/MFQT3R9S
docked, no headphones: http://pastebin.com/8UN1sHSM
docked, headphones plugged in dock: http://pastebin.com/7XauZLZz
docked, headphones plugged in notebook: http://pastebin.com/xfL5qkge

Based on that, can you help us getting sound to work on the dock?

Best,
Bernhard

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2014-02-12 21:01   ` Bernhard
@ 2014-02-13  2:15     ` Raymond Yau
  2014-02-20 11:34       ` Bernhard Kirchen
  0 siblings, 1 reply; 10+ messages in thread
From: Raymond Yau @ 2014-02-13  2:15 UTC (permalink / raw)
  To: Bernhard, nkalkhof; +Cc: ALSA Development Mailing List

2014-02-13 5:01 GMT+08:00 Bernhard <schlimmchen@yahoo.de>:

> Raymond Yau <superquad.vortex2 <at> gmail.com> writes:
> >
> > Post the output of alsa-info.sh when thinkpad is docked and not docked
> with
> > headphone pluggedd and unplugged
> >
>
> I created the output you requested (Lenovo ThinkPad T440p in UltraDock, no
> sound when docked via dock jack but notebook speakers are also mute).
>
> not docked: http://pastebin.com/MFQT3R9S
> docked, no headphones: http://pastebin.com/8UN1sHSM
> docked, headphones plugged in dock: http://pastebin.com/7XauZLZz
> docked, headphones plugged in notebook: http://pastebin.com/xfL5qkge
>
> Based on that, can you help us getting sound to work on the dock?
>
>
the headphone is at node 0x15

        control.16 {
                iface CARD
                name 'Headphone Jack'
                value true
                comment {
                        access read
                        type BOOLEAN
                        count 1
                }
        }

you need to use hda_jack_sense_test.py which require python and hda codec
parser of hda-analyzer to find out

https://bugzilla.kernel.org/show_bug.cgi?id=66621#c39

pd=1 when plugged and pd=0 when unplugged

or hda-verb GET_PIN_SENSE

https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/plain/Documentation/sound/alsa/HD-Audio.txt

1) the node of the headphone of the dock headset

node 0x16 , 0x18 and 0x19 which pincap support output

try hdajackretask or early patching to fix the pin default to dock headphone

2) for the dock headset mic , you need to find by trial and error from the
remaining unconnected nodes which pincap support input

node 0x13, 0x19, 0x1b, 0x1d


https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/log/sound/pci/hda/patch_realtek.c?qt=grep&q=dock

 0x21a11000  /* dock-mic */

need to set bit 8 if dock headset mic use jack detection of headphone
instead of jack detection of its own pin compex

 0x2121103f  /* dock-HP */
 0x21440100  /* dock SPDIF out */

you need to clear bit 8 if pincap of node 0x1e support DETECT

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2014-02-13  2:15     ` Raymond Yau
@ 2014-02-20 11:34       ` Bernhard Kirchen
  2014-02-21  0:26         ` Raymond Yau
                           ` (2 more replies)
  0 siblings, 3 replies; 10+ messages in thread
From: Bernhard Kirchen @ 2014-02-20 11:34 UTC (permalink / raw)
  To: Raymond Yau, nkalkhof; +Cc: ALSA Development Mailing List

Hey Raymond!

Sorry for the late reply!
I had trouble following your input as I am not experienced with this. 
"HD-Audio.txt" helped a lot!

To make a 5 hour story short, this is my result:
Using early patching, everything works to my linking:
0x16 0x2121101f # dock headphones
0x19 0x21a11030 # dock mic

Thank you very much for your help!

I guess that building a patch á la ALC269_FIXUP_LENOVO_DOCK is not a big 
deal, but not my business.
If wanted, I can do testing, as soon as I learn how to properly compile 
and install a custom kernel.

I'll post something on 
https://github.com/leoluk/thinkpad-stuff/wiki/Haswell-ThinkPad-problems 
to tell other people how to fix this right away.

More to my story:
I found /sys/class/sound/hwC1D0, which is a Realtek ALC292 device.
The NID (what does it stand for?) of interest for the jack's output is 
indeed 0x16.

When headphones plugged into docking station jack:
$ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
nid = 0x16, verb = 0xf09, param = 0x0
value = 0x80000000

When not plugged:
$ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
nid = 0x16, verb = 0xf09, param = 0x0
value = 0x0

GET_PIN_SENSE for 0x19 is 0x80000000 when headset with mic is plugged 
into dock.
Pin sense of 0x19 does not change to 0x80000000 when only plugging 3pole 
speaker cable.
Therefore, I assumed that 0x19 is the dock mic input (turned out later 
to be true).

I installed alsa-tools-gui and used hdajackretast to override the pin 
config.
It took a while to find out that not all changes are immediate (early 
patching and restart required).

Using the early patching values from above, the sound is being 
redirected from the internal speakers to the dock jack, when headphones 
are connected.
[When connecting an additional speaker to the left jack on the notebook, 
the sound is output to both dock and notebook jack.]
When connecting a mic to dock, the dock mic shows up as input and is 
used as such.
When only connecting a headset without mic, the internal mic stays 
functional.

Best,
Bernhard

On 02/13/2014 03:15 AM, Raymond Yau wrote:
> 2014-02-13 5:01 GMT+08:00 Bernhard <schlimmchen@yahoo.de 
> <mailto:schlimmchen@yahoo.de>>:
>
>     Raymond Yau <superquad.vortex2 <at> gmail.com <http://gmail.com>>
>     writes:
>     >
>     > Post the output of alsa-info.sh when thinkpad is docked and not
>     docked with
>     > headphone pluggedd and unplugged
>     >
>
>     I created the output you requested (Lenovo ThinkPad T440p in
>     UltraDock, no
>     sound when docked via dock jack but notebook speakers are also mute).
>
>     not docked: http://pastebin.com/MFQT3R9S
>     docked, no headphones: http://pastebin.com/8UN1sHSM
>     docked, headphones plugged in dock: http://pastebin.com/7XauZLZz
>     docked, headphones plugged in notebook: http://pastebin.com/xfL5qkge
>
>     Based on that, can you help us getting sound to work on the dock?
>
>
> the headphone is at node 0x15
>
>         control.16 {
>                 iface CARD
>                 name 'Headphone Jack'
>                 value true
>                 comment {
>                         access read
>                         type BOOLEAN
>                         count 1
>                 }
>         }
>
> you need to use hda_jack_sense_test.py which require python and hda 
> codec parser of hda-analyzer to find out
>
> https://bugzilla.kernel.org/show_bug.cgi?id=66621#c39
>
> pd=1 when plugged and pd=0 when unplugged
>
> or hda-verb GET_PIN_SENSE
>
> https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/plain/Documentation/sound/alsa/HD-Audio.txt
>
> 1) the node of the headphone of the dock headset
>
> node 0x16 , 0x18 and 0x19 which pincap support output
>
> try hdajackretask or early patching to fix the pin default to dock 
> headphone
>
> 2) for the dock headset mic , you need to find by trial and error from 
> the remaining unconnected nodes which pincap support input
>
> node 0x13, 0x19, 0x1b, 0x1d
>
>
> https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/log/sound/pci/hda/patch_realtek.c?qt=grep&q=dock
>
>  0x21a11000  /* dock-mic */
>
> need to set bit 8 if dock headset mic use jack detection of headphone 
> instead of jack detection of its own pin compex
>
>  0x2121103f  /* dock-HP */
>  0x21440100  /* dock SPDIF out */
>
> you need to clear bit 8 if pincap of node 0x1e support DETECT
>
>
>
>
>
>
>

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

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2014-02-20 11:34       ` Bernhard Kirchen
@ 2014-02-21  0:26         ` Raymond Yau
  2014-02-22  3:07         ` Raymond Yau
  2014-02-22  9:03         ` Raymond Yau
  2 siblings, 0 replies; 10+ messages in thread
From: Raymond Yau @ 2014-02-21  0:26 UTC (permalink / raw)
  To: Bernhard Kirchen; +Cc: tiwai, ALSA Development Mailing List, nkalkhof

>
> To make a 5 hour story short, this is my result:
> Using early patching, everything works to my linking:
> 0x16 0x2121101f # dock headphones
> 0x19 0x21a11030 # dock mic
>
> Thank you very much for your help!
>
> I guess that building a patch á la ALC269_FIXUP_LENOVO_DOCK is not a big
deal, but not my business.
> If wanted, I can do testing, as soon as I learn how to properly compile
and install a custom kernel.
>
> I'll post something on
https://github.com/leoluk/thinkpad-stuff/wiki/Haswell-ThinkPad-problems to
tell other people how to fix this right away.
>
> More to my story:
> I found /sys/class/sound/hwC1D0, which is a Realtek ALC292 device.
> The NID (what does it stand for?) of interest for the jack's output is
indeed 0x16.
>
> When headphones plugged into docking station jack:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x80000000
>
> When not plugged:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x0
>
> GET_PIN_SENSE for 0x19 is 0x80000000 when headset with mic is plugged
into dock.
> Pin sense of 0x19 does not change to 0x80000000 when only plugging 3pole
speaker cable.
> Therefore, I assumed that 0x19 is the dock mic input (turned out later to
be true).

Are you using the same dock station as Nicolas?

It seem this dock station has only 1x Stereo/Mic Combo Audio Port

http://outlet.lenovo.com/no/en/itemdetails/40A10065EU/460/6D501EE899104FF9A362D739642CFC27#overview

Do you mean when headset is plugged, both node 0x16 and node 0x19 can
detect the Jack state which is not different from those dock station which
have headphone Jack and Mic jack ?

Do this dock combo jack not support conventional Mic  similar to the
notebook combo Jack ?

Do you need to differentiate these two kind of dock stations if your ultra
dock cannot support conventional Mic ?

Dock Mic and dock headset mic

http://support.lenovo.com/en_US/detail.page?DocID=PD029485

Connect headphones or a headset that has a 3.5-mm (0.14-inch), 4-pole plug
to the audio connector to listen to the sound from the computer.

Notes:
• If you are using a headset with a function switch, for example, a headset
for an iPhone mobile digital device, do not press this switch while using
the headset. If you press the switch, the headset microphone will be
disabled, and the integrated microphones on the computer will be enabled
instead.

The audio connector does not support a conventional microphone.

>
> I installed alsa-tools-gui and used hdajackretast to override the pin
config.
> It took a while to find out that not all changes are immediate (early
patching and restart required).
>
> Using the early patching values from above, the sound is being redirected
from the internal speakers to the dock jack, when headphones are connected.
> [When connecting an additional speaker to the left jack on the notebook,
the sound is output to both dock and notebook jack.]
> When connecting a mic to dock, the dock mic shows up as input and is used
as such.
> When only connecting a headset without mic, the internal mic stays
functional.
>

>>> >
>>>
>>> I created the output you requested (Lenovo ThinkPad T440p in UltraDock,
no
>>> sound when docked via dock jack but notebook speakers are also mute).
>>>
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2014-02-20 11:34       ` Bernhard Kirchen
  2014-02-21  0:26         ` Raymond Yau
@ 2014-02-22  3:07         ` Raymond Yau
  2014-02-22  9:03         ` Raymond Yau
  2 siblings, 0 replies; 10+ messages in thread
From: Raymond Yau @ 2014-02-22  3:07 UTC (permalink / raw)
  To: Bernhard Kirchen, tiwai; +Cc: ALSA Development Mailing List, nkalkhof

>
> To make a 5 hour story short, this is my result:
> Using early patching, everything works to my linking:
> 0x16 0x2121101f # dock headphones
> 0x19 0x21a11030 # dock mic
>
> Thank you very much for your help!
>
> I guess that building a patch á la ALC269_FIXUP_LENOVO_DOCK is not a big
> deal, but not my business.
> If wanted, I can do testing, as soon as I learn how to properly compile
> and install a custom kernel.
>
> I'll post something on
> https://github.com/leoluk/thinkpad-stuff/wiki/Haswell-ThinkPad-problemsto tell other people how to fix this right away.
>
> More to my story:
> I found /sys/class/sound/hwC1D0, which is a Realtek ALC292 device.
> The NID (what does it stand for?) of interest for the jack's output is
> indeed 0x16.
>
> When headphones plugged into docking station jack:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x80000000
>
> When not plugged:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x0
>
> GET_PIN_SENSE for 0x19 is 0x80000000 when headset with mic is plugged into
> dock.
> Pin sense of 0x19 does not change to 0x80000000 when only plugging 3pole
> speaker cable.
> Therefore, I assumed that 0x19 is the dock mic input (turned out later to
> be true).
>
> I installed alsa-tools-gui and used hdajackretast to override the pin
> config.
> It took a while to find out that not all changes are immediate (early
> patching and restart required).
>
> Using the early patching values from above, the sound is being redirected
> from the internal speakers to the dock jack, when headphones are connected.
> [When connecting an additional speaker to the left jack on the notebook,
> the sound is output to both dock and notebook jack.]
>

autoconfig: line_outs=1 (0x14/0x0/0x0/0x0/0x0) type:speaker
   speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
   hp_outs=2 (0x15/0x1b/0x0/0x0/0x0)
   mono: mono_out=0x0
   inputs:
     Internal Mic=0x12
     Dock Mic=0x19
     Mic=0x1a


speaker-test -c 4 -t wav -Dhw:0,0

Do you mean the driver allow 4 channels play cannot get surround 4.0
playback when model=lenovo-dock is used ? (i.e. channels_max is incorrect )

==> Best config: lo_type=1, wired=1, mio=1
multi_outs = 14/0/0/0 : 2/0/0/0 (type SP)
  out path: depth=3 :02:0c:14
hp_outs = 15/1b/0/0 : 3/3/0/0
  hp  path: depth=3 :03:0d:15
  hp  path: depth=3 :03:0d:1b


 PCM 0 p 44100 4 16
Open PCM ALC292 Analog for play
Available PCM parameters:
  channels: 2/4
  formats: S16_LE S32_LE
  rates: 44100 48000 96000 192000
Prepare PCM, rate=44100, channels=4, format=16 bits
PCM format_val = 0x4013
hda_codec_setup_stream: NID=0x2, stream=0x1, channel=0, format=0x4013
send: NID=0x2, VERB=0xf06(get_channel_streamid), PARM=0x0
receive: 0x0
send: NID=0x2, VERB=0x706(set_channel_streamid), PARM=0x10
send: NID=0x2, VERB=0xa00(get_stream_format), PARM=0x0
receive: 0x0
send: NID=0x2, VERB=0x240(set_stream_format), PARM=0x13
hda_codec_setup_stream: NID=0x3, stream=0x1, channel=0, format=0x4013
send: NID=0x3, VERB=0xf06(get_channel_streamid), PARM=0x0
receive: 0x0
send: NID=0x3, VERB=0x706(set_channel_streamid), PARM=0x10
send: NID=0x3, VERB=0xa00(get_stream_format), PARM=0x0
receive: 0x0
send: NID=0x3, VERB=0x240(set_stream_format), PARM=0x13
hda_codec_setup_stream: NID=0x3, stream=0x1, channel=0, format=0x4013
PCM Clean up
hda_codec_cleanup_stream: NID=0x2
hda_codec_cleanup_stream: NID=0x3
hda_codec_cleanup_stream: NID=0x3
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 10+ messages in thread

* Re: No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop
  2014-02-20 11:34       ` Bernhard Kirchen
  2014-02-21  0:26         ` Raymond Yau
  2014-02-22  3:07         ` Raymond Yau
@ 2014-02-22  9:03         ` Raymond Yau
  2 siblings, 0 replies; 10+ messages in thread
From: Raymond Yau @ 2014-02-22  9:03 UTC (permalink / raw)
  To: Bernhard Kirchen, John McCarron, Takashi Iwai
  Cc: ALSA Development Mailing List, nkalkhof

> To make a 5 hour story short, this is my result:
> Using early patching, everything works to my linking:
> 0x16 0x2121101f # dock headphones
> 0x19 0x21a11030 # dock mic
>
> Thank you very much for your help!
>
> I guess that building a patch á la ALC269_FIXUP_LENOVO_DOCK is not a big
> deal, but not my business.
> If wanted, I can do testing, as soon as I learn how to properly compile
> and install a custom kernel.
>


https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_realtek.c?id=108cc108a3bb42fe4705df1317ff98e1e29428a6

There is already a model lenovo-dock for alc269  but the pins are different
from your t440p

so you need  ALC292_FIXUP_LENOVO_DOCK for your t440p


> I'll post something on
> https://github.com/leoluk/thinkpad-stuff/wiki/Haswell-ThinkPad-problemsto tell other people how to fix this right away.
>
> More to my story:
> I found /sys/class/sound/hwC1D0, which is a Realtek ALC292 device.
> The NID (what does it stand for?) of interest for the jack's output is
> indeed 0x16.
>
> When headphones plugged into docking station jack:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x80000000
>
> When not plugged:
> $ sudo hda-verb /dev/snd/hwC1D0 0x16 GET_PIN_SENSE 0
> nid = 0x16, verb = 0xf09, param = 0x0
> value = 0x0
>
> GET_PIN_SENSE for 0x19 is 0x80000000 when headset with mic is plugged into
> dock.
> Pin sense of 0x19 does not change to 0x80000000 when only plugging 3pole
> speaker cable.
> Therefore, I assumed that 0x19 is the dock mic input (turned out later to
> be true).
>
> I installed alsa-tools-gui and used hdajackretast to override the pin
> config.
> It took a while to find out that not all changes are immediate (early
> patching and restart required).
>
> Using the early patching values from above, the sound is being redirected
> from the internal speakers to the dock jack, when headphones are connected.
> [When connecting an additional speaker to the left jack on the notebook,
> the sound is output to both dock and notebook jack.]
>


https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/hda_generic.c?id=a07a949be6eb1c9aab06adaadce72dbd27b7d9cb

multiout.max_channels is changed to 4 but you cannot get 4 channels
playback on headphone and dock headphone

+ if (cfg->line_out_type != AUTO_PIN_HP_OUT)
+ spec->const_channel_count = max(spec->const_channel_count,
+ cfg->hp_outs * 2);
+ spec->multiout.max_channels = max(spec->ext_channel_count,
+ spec->const_channel_count);






> When connecting a mic to dock, the dock mic shows up as input and is used
> as such.
> When only connecting a headset without mic, the internal mic stays
> functional.
>


> I created the output you requested (Lenovo ThinkPad T440p in UltraDock, no
>
> sound when docked via dock jack but notebook speakers are also mute).
>>
>> not docked: http://pastebin.com/MFQT3R9S
>> docked, no headphones: http://pastebin.com/8UN1sHSM
>> docked, headphones plugged in dock: http://pastebin.com/7XauZLZz
>> docked, headphones plugged in notebook: http://pastebin.com/xfL5qkge
>>
>> Based on that, can you help us getting sound to work on the dock?
>>
>>
>
>
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel

^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2014-02-22  9:03 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-12-19 10:05 No sound from Headphone Jack over Lenovo Docking Station with T440p Laptop Nicolas Kalkhof
2013-12-22 12:47 ` Raymond Yau
2013-12-22 13:41   ` Nicolas Kalkhof
2013-12-22 13:50   ` Nicolas Kalkhof
2014-02-12 21:01   ` Bernhard
2014-02-13  2:15     ` Raymond Yau
2014-02-20 11:34       ` Bernhard Kirchen
2014-02-21  0:26         ` Raymond Yau
2014-02-22  3:07         ` Raymond Yau
2014-02-22  9:03         ` Raymond Yau

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.