linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
@ 2012-05-04  7:21 Konstantin Khlebnikov
  2012-05-06  8:32 ` Konstantin Khlebnikov
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-04  7:21 UTC (permalink / raw)
  To: Takashi Iwai, alsa-devel; +Cc: linux-kernel

Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
("ALSA: hda - Set codec to D3 forcibly even if not used")
breaks sound for my notebook (thinkpad x220),
looks like codec cannot wake from power-save state after resume.
After reverting looks like all works fine.

how to reproduce:
* unplug the power cord (to enable hda power safe mode)
* play something and stop
* wait until the background noise disappears (codec went into power-save mode)
* suspend
* resume
* play something again and hear the silence

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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-04  7:21 [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel Konstantin Khlebnikov
@ 2012-05-06  8:32 ` Konstantin Khlebnikov
  2012-05-06 10:37   ` Takashi Iwai
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-06  8:32 UTC (permalink / raw)
  To: Takashi Iwai, alsa-devel; +Cc: linux-kernel, Jaroslav Kysela, David Henningsson

Konstantin Khlebnikov wrote:
> Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
> ("ALSA: hda - Set codec to D3 forcibly even if not used")
> breaks sound for my notebook (thinkpad x220),
> looks like codec cannot wake from power-save state after resume.
> After reverting looks like all works fine.
>
> how to reproduce:
> * unplug the power cord (to enable hda power safe mode)
> * play something and stop
> * wait until the background noise disappears (codec went into power-save mode)
> * suspend
> * resume
> * play something again and hear the silence
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/

Bump

BTW, I don't see any locks around hda power-save code, for example  hda_power_work() reads
codec->power_on and codec->power_count without any locks. This seems racy.

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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-06  8:32 ` Konstantin Khlebnikov
@ 2012-05-06 10:37   ` Takashi Iwai
  2012-05-08  7:13     ` Konstantin Khlebnikov
  0 siblings, 1 reply; 11+ messages in thread
From: Takashi Iwai @ 2012-05-06 10:37 UTC (permalink / raw)
  To: Konstantin Khlebnikov
  Cc: alsa-devel, linux-kernel, Jaroslav Kysela, David Henningsson

At Sun, 06 May 2012 12:32:14 +0400,
Konstantin Khlebnikov wrote:
> 
> Konstantin Khlebnikov wrote:
> > Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
> > ("ALSA: hda - Set codec to D3 forcibly even if not used")
> > breaks sound for my notebook (thinkpad x220),
> > looks like codec cannot wake from power-save state after resume.
> > After reverting looks like all works fine.
> >
> > how to reproduce:
> > * unplug the power cord (to enable hda power safe mode)
> > * play something and stop
> > * wait until the background noise disappears (codec went into power-save mode)
> > * suspend
> > * resume
> > * play something again and hear the silence
> > --
> > To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> > the body of a message to majordomo@vger.kernel.org
> > More majordomo info at  http://vger.kernel.org/majordomo-info.html
> > Please read the FAQ at  http://www.tux.org/lkml/
> 
> Bump

It's a weekend, so don't expect quick responces from any normal person
:)

Which 3.4-rc did you try?  There was a known problem with this codec
regarding the power-up sequence, but this should have been fixed in
the very recent version.

If the latest Linus tree still shows the problem, try sound git tree
master or for-next branch.
   git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git

Then attach alsa-info.sh output (run with --no-upload option) before
and after S3 (i.e. working and non-working states).


> BTW, I don't see any locks around hda power-save code, for example  hda_power_work() reads
> codec->power_on and codec->power_count without any locks. This seems racy.

Yeah, we may add an extra spinlock.  But it's not too critical for the
whole operation, so I didn't care much so far.  At most, you'll miss one
power-save cycle.  Maybe a good time to fix it now for 3.5.


thanks,

Takashi

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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-06 10:37   ` Takashi Iwai
@ 2012-05-08  7:13     ` Konstantin Khlebnikov
  2012-05-08  8:11       ` Takashi Iwai
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-08  7:13 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, linux-kernel, Jaroslav Kysela, David Henningsson

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

Takashi Iwai wrote:
> At Sun, 06 May 2012 12:32:14 +0400,
> Konstantin Khlebnikov wrote:
>>
>> Konstantin Khlebnikov wrote:
>>> Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
>>> ("ALSA: hda - Set codec to D3 forcibly even if not used")
>>> breaks sound for my notebook (thinkpad x220),
>>> looks like codec cannot wake from power-save state after resume.
>>> After reverting looks like all works fine.
>>>
>>> how to reproduce:
>>> * unplug the power cord (to enable hda power safe mode)
>>> * play something and stop
>>> * wait until the background noise disappears (codec went into power-save mode)
>>> * suspend
>>> * resume
>>> * play something again and hear the silence
>>> --
>>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>>> the body of a message to majordomo@vger.kernel.org
>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>> Please read the FAQ at  http://www.tux.org/lkml/
>>
>> Bump
>
> It's a weekend, so don't expect quick responces from any normal person
> :)

Yeah, sorry. In this country a mess with holidays and weekends.

>
> Which 3.4-rc did you try?  There was a known problem with this codec
> regarding the power-up sequence, but this should have been fixed in
> the very recent version.

Bug still in latest v3.4-rc6.
This is serious degradation since v3.3, so I hope it will be fixed before release.

>
> If the latest Linus tree still shows the problem, try sound git tree
> master or for-next branch.
>     git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git

I don't see there anything related to this problem. Bug is still there.
It's 100% reproductible and disappears after reverting that commit.
Looks like driver missed one power-up cycle after system-resume,
after second power-save down/up cycle all work fine.

>
> Then attach g output (run with --no-upload option) before
> and after S3 (i.e. working and non-working states).

see attachments (kernel is v3.4-rc6 with changes from your branch)

start mplayer (work fine)
alsa-info.sh -> alsa-info.before
stop mplayer
suspend
resume
start mplayer (doesn't work)
alsa-info.sh -> alsa-info.after
stop mplayer
wait a second
start mplayer (work fine)

>
>
>> BTW, I don't see any locks around hda power-save code, for example  hda_power_work() reads
>> codec->power_on and codec->power_count without any locks. This seems racy.
>
> Yeah, we may add an extra spinlock.  But it's not too critical for the
> whole operation, so I didn't care much so far.  At most, you'll miss one
> power-save cycle.  Maybe a good time to fix it now for 3.5.

I'm afraid this code can easily miss one power-up cycle and stays in power-save mode.
This can be unrelated to my problem, but from my point of view this is very careless.
For example snd_hda_power_up() can easily race with hda_power_work().

>
>
> thanks,
>
> Takashi

[-- Attachment #2: alsa-info.txt.after --]
[-- Type: text/plain, Size: 28306 bytes --]

upload=true&script=true&cardinfo=
!!################################
!!ALSA Information Script v 0.4.60
!!################################

!!Script ran on: Tue May  8 07:03:32 UTC 2012


!!Linux Distribution
!!------------------

Debian GNU/Linux wheezy/sid \n \l


!!DMI Information
!!---------------

Manufacturer:      LENOVO
Product Name:      4291QY6
Product Version:   ThinkPad X220


!!Kernel Information
!!------------------

Kernel release:    3.4.0-rc6-zurg-00001-gfebb72a-dirty
Operating System:  GNU/Linux
Architecture:      x86_64
Processor:         unknown
SMP Enabled:       Yes


!!ALSA Version
!!------------

Driver version:     1.0.25
Library version:    1.0.25
Utilities version:  1.0.25


!!Loaded ALSA modules
!!-------------------

snd_hda_intel
thinkpad_acpi


!!Sound Servers on this system
!!----------------------------

Jack:
      Installed - Yes (/usr/bin/jackd)
      Running - No


!!Soundcards recognised by ALSA
!!-----------------------------

 0 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf2620000 irq 50
29 [ThinkPadEC     ]: ThinkPad EC - ThinkPad Console Audio Control
                      ThinkPad Console Audio Control at EC reg 0x30, fw unknown


!!PCI Soundcards installed in the system
!!--------------------------------------

00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller (rev 04)


!!Advanced information - PCI Vendor/Device/Subsystem ID's
!!--------------------------------------------------------

00:1b.0 0403: 8086:1c20 (rev 04)
	Subsystem: 17aa:21da


!!Loaded sound module options
!!--------------------------

!!Module: snd_hda_intel
	align_buffer_size : -1
	bdl_pos_adj : 1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	enable : Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y
	enable_msi : -1
	id : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	index : -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	model : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	patch : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	position_fix : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
	power_save : 1
	power_save_controller : N
	probe_mask : -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	probe_only : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
	single_cmd : N
	snoop : Y

!!Module: thinkpad_acpi
	brightness_enable : 2
	brightness_mode : 4
	dbg_bluetoothemul : 0
	dbg_uwbemul : 0
	dbg_wlswemul : 0
	dbg_wwanemul : 0
	enable : Y
	experimental : 0
	fan_control : N
	force_load : N
	hotkey_report_mode : 0
	id : ThinkPadEC
	index : -536870912
	volume_capabilities : 0
	volume_control : N
	volume_mode : 3


!!HDA-Intel Codec information
!!---------------------------
--startcollapse--

Codec: Conexant CX20590
Address: 0
AFG Function Id: 0x1 (unsol 1)
Vendor Id: 0x14f1506e
Subsystem Id: 0x17aa21da
Revision Id: 0x100000
No Modem Function Group found
Default PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
Default Amp-In caps: N/A
Default Amp-Out caps: N/A
GPIO: io=4, o=0, i=0, unsolicited=1, wake=0
  IO[0]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[1]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[2]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[3]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
Node 0x10 [Audio Output] wcaps 0xc1d: Stereo Amp-Out R/L
  Control: name="Master Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Device: name="CONEXANT Analog", type="Audio", device=0
  Amp-Out caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-Out vals:  [0x3c 0x3c]
  Converter: stream=0, channel=0
  PCM:
    rates [0x560]: 44100 48000 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x11 [Audio Output] wcaps 0xc1d: Stereo Amp-Out R/L
  Amp-Out caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-Out vals:  [0x3c 0x3c]
  Converter: stream=0, channel=0
  PCM:
    rates [0x560]: 44100 48000 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x12 [Audio Output] wcaps 0x611: Stereo Digital
  Converter: stream=0, channel=0
  Digital:
  Digital category: 0x0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x5]: PCM AC3
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x13 [Beep Generator Widget] wcaps 0x70000c: Mono Amp-Out
  Amp-Out caps: ofs=0x07, nsteps=0x07, stepsize=0x0f, mute=0
  Amp-Out vals:  [0x00]
Node 0x14 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Device: name="CONEXANT Analog", type="Audio", device=0
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 4
     0x17* 0x18 0x23 0x24
Node 0x15 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 4
     0x17* 0x18 0x23 0x24
Node 0x16 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 4
     0x17* 0x18 0x23 0x24
Node 0x17 [Audio Selector] wcaps 0x30050d: Stereo Amp-Out
  Amp-Out caps: ofs=0x00, nsteps=0x04, stepsize=0x27, mute=0
  Amp-Out vals:  [0x00 0x00]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 4
     0x1a* 0x1b 0x1d 0x1e
Node 0x18 [Audio Selector] wcaps 0x30050d: Stereo Amp-Out
  Amp-Out caps: ofs=0x00, nsteps=0x04, stepsize=0x27, mute=0
  Amp-Out vals:  [0x00 0x00]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 4
     0x1a* 0x1b 0x1d 0x1e
Node 0x19 [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x0000001c: OUT HP Detect
  Pin Default 0x04211040: [Jack] HP Out at Ext Right
    Conn = 1/8, Color = Black
    DefAssociation = 0x4, Sequence = 0x0
  Pin-ctls: 0xc0: OUT HP
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10* 0x11
Node 0x1a [Pin Complex] wcaps 0x400481: Stereo
  Pincap 0x00001324: IN Detect
    Vref caps: HIZ 50 80
  Pin Default 0x61a19050: [N/A] Mic at Sep Rear
    Conn = 1/8, Color = Pink
    DefAssociation = 0x5, Sequence = 0x0
  Pin-ctls: 0x00: VREF_HIZ
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x1b [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00011334: IN OUT EAPD Detect
    Vref caps: HIZ 50 80
  EAPD 0x0:
  Pin Default 0x04a11060: [Jack] Mic at Ext Right
    Conn = 1/8, Color = Black
    DefAssociation = 0x6, Sequence = 0x0
  Pin-ctls: 0x00: VREF_HIZ
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10* 0x11
Node 0x1c [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00000014: OUT Detect
  Pin Default 0x6121401f: [N/A] HP Out at Sep Rear
    Conn = 1/8, Color = Green
    DefAssociation = 0x1, Sequence = 0xf
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10* 0x11
Node 0x1d [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00010034: IN OUT EAPD Detect
  EAPD 0x0:
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10* 0x11
Node 0x1e [Pin Complex] wcaps 0x400481: Stereo
  Pincap 0x00000024: IN Detect
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x00:
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x1f [Pin Complex] wcaps 0x400501: Stereo
  Pincap 0x00000010: OUT
  Pin Default 0x90170110: [Fixed] Speaker at Int N/A
    Conn = Analog, Color = Unknown
    DefAssociation = 0x1, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10* 0x11
Node 0x20 [Pin Complex] wcaps 0x400781: Stereo Digital
  Pincap 0x00000010: OUT
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x00:
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 1
     0x12
Node 0x21 [Audio Output] wcaps 0x611: Stereo Digital
  Converter: stream=0, channel=0
  Digital:
  Digital category: 0x0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x5]: PCM AC3
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x22 [Pin Complex] wcaps 0x400781: Stereo Digital
  Pincap 0x00000010: OUT
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x00:
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 1
     0x21
Node 0x23 [Pin Complex] wcaps 0x40040b: Stereo Amp-In
  Amp-In caps: ofs=0x00, nsteps=0x04, stepsize=0x2f, mute=0
  Amp-In vals:  [0x00 0x00]
  Pincap 0x00000020: IN
  Pin Default 0x90a60170: [Fixed] Mic at Int N/A
    Conn = Digital, Color = Unknown
    DefAssociation = 0x7, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x00:
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
Node 0x24 [Audio Mixer] wcaps 0x20050b: Stereo Amp-In
  Amp-In caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-In vals:  [0x00 0x00] [0x00 0x00]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D3, actual=D3
  Connection: 2
     0x10 0x11
Node 0x25 [Vendor Defined Widget] wcaps 0xf00000: Mono
Codec: Intel CougarPoint HDMI
Address: 3
AFG Function Id: 0x1 (unsol 0)
Vendor Id: 0x80862805
Subsystem Id: 0x80860101
Revision Id: 0x100000
No Modem Function Group found
Default PCM:
    rates [0x0]:
    bits [0x0]:
    formats [0x0]:
Default Amp-In caps: N/A
Default Amp-Out caps: N/A
GPIO: io=0, o=0, i=0, unsolicited=0, wake=0
Node 0x02 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x03 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x04 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x05 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=3 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=0, device=0
  Control: name="IEC958 Playback Pro Mask", index=0, device=0
  Control: name="IEC958 Playback Default", index=0, device=0
  Control: name="IEC958 Playback Switch", index=0, device=0
  Control: name="ELD", index=0, device=3
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560010: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x1, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=01, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x02
Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=7 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=1, device=0
  Control: name="IEC958 Playback Pro Mask", index=1, device=0
  Control: name="IEC958 Playback Default", index=1, device=0
  Control: name="IEC958 Playback Switch", index=1, device=0
  Control: name="ELD", index=0, device=7
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560020: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x2, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=02, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x03
Node 0x07 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=8 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=2, device=0
  Control: name="IEC958 Playback Pro Mask", index=2, device=0
  Control: name="IEC958 Playback Default", index=2, device=0
  Control: name="IEC958 Playback Switch", index=2, device=0
  Control: name="ELD", index=0, device=8
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560030: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x3, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=03, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x04
Node 0x08 [Vendor Defined Widget] wcaps 0xf00000: Mono
--endcollapse--


!!ALSA Device nodes
!!-----------------

crw-rw---T+ 1 root audio 116, 10 May  8 10:59 /dev/snd/controlC0
crw-rw---T+ 1 root audio 116,  2 May  8 10:59 /dev/snd/controlC29
crw-rw---T+ 1 root audio 116,  9 May  8 10:59 /dev/snd/hwC0D0
crw-rw---T+ 1 root audio 116,  8 May  8 10:59 /dev/snd/hwC0D3
crw-rw---T+ 1 root audio 116,  7 May  8 10:59 /dev/snd/pcmC0D0c
crw-rw---T+ 1 root audio 116,  6 May  8 11:03 /dev/snd/pcmC0D0p
crw-rw---T+ 1 root audio 116,  5 May  8 10:59 /dev/snd/pcmC0D3p
crw-rw---T+ 1 root audio 116,  4 May  8 10:59 /dev/snd/pcmC0D7p
crw-rw---T+ 1 root audio 116,  3 May  8 10:59 /dev/snd/pcmC0D8p
crw-rw---T+ 1 root audio 116,  1 May  8  2012 /dev/snd/seq
crw-rw---T+ 1 root audio 116, 33 May  8  2012 /dev/snd/timer

/dev/snd/by-path:
total 0
drwxr-xr-x 2 root root  80 May  8 10:59 .
drwxr-xr-x 3 root root 280 May  8 10:59 ..
lrwxrwxrwx 1 root root  12 May  8 10:59 pci-0000:00:1b.0 -> ../controlC0
lrwxrwxrwx 1 root root  13 May  8 10:59 platform-thinkpad_acpi -> ../controlC29


!!ALSA configuration files
!!------------------------

!!User specific config file (~/.asoundrc)

pcm.!default_ {
	type plug
	slave { pcm "jack" }
}

pcm.jack {
	type jack
	playback_ports {
		0 system:playback_1
		1 system:playback_2
	}
}


!!Aplay/Arecord output
!!------------

APLAY

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

ARECORD

**** List of CAPTURE Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

!!Amixer output
!!-------------

!!-------Mixer controls for card 0 [PCH]

Card hw:0 'PCH'/'HDA Intel PCH at 0xf2620000 irq 50'
  Mixer name	: 'Intel CougarPoint HDMI'
  Components	: 'HDA:14f1506e,17aa21da,00100000 HDA:80862805,80860101,00100000'
  Controls      : 24
  Simple ctrls  : 7
Simple mixer control 'Master',0
  Capabilities: pvolume pswitch pswitch-joined penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 74
  Mono:
  Front Left: Playback 73 [99%] [-1.00dB] [on]
  Front Right: Playback 73 [99%] [-1.00dB] [on]
Simple mixer control 'PCM',0
  Capabilities: pvolume penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 255
  Mono:
  Front Left: Playback 255 [100%] [0.00dB]
  Front Right: Playback 255 [100%] [0.00dB]
Simple mixer control 'IEC958',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'IEC958',1
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'IEC958',2
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'Capture',0
  Capabilities: cvolume cswitch penum
  Capture channels: Front Left - Front Right
  Limits: Capture 0 - 80
  Front Left: Capture 80 [100%] [6.00dB] [on]
  Front Right: Capture 80 [100%] [6.00dB] [on]
Simple mixer control 'Analog Mic Boost',0
  Capabilities: cenum
  Items: '0dB' '10dB' '20dB' '30dB' '40dB'
  Item0: '20dB'

!!-------Mixer controls for card 29 [ThinkPadEC]

Card hw:29 'ThinkPadEC'/'ThinkPad Console Audio Control at EC reg 0x30, fw unknown'
  Mixer name	: 'ThinkPad EC (unknown)'
  Components	: ''
  Controls      : 1
  Simple ctrls  : 1
Simple mixer control 'Console',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]


!!Alsactl output
!!-------------

--startcollapse--
state.PCH {
	control.1 {
		iface MIXER
		name 'Master Playback Volume'
		value.0 73
		value.1 73
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 74'
			dbmin -7400
			dbmax 0
			dbvalue.0 -100
			dbvalue.1 -100
		}
	}
	control.2 {
		iface MIXER
		name 'Master Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'Analog Mic Boost Capture Enum'
		value '20dB'
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 '0dB'
			item.1 '10dB'
			item.2 '20dB'
			item.3 '30dB'
			item.4 '40dB'
		}
	}
	control.4 {
		iface MIXER
		name 'Capture Volume'
		value.0 80
		value.1 80
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 80'
			dbmin -7400
			dbmax 600
			dbvalue.0 600
			dbvalue.1 600
		}
	}
	control.5 {
		iface MIXER
		name 'Capture Switch'
		value.0 true
		value.1 true
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.6 {
		iface CARD
		name 'HDMI/DP,pcm=3 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.7 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.8 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.9 {
		iface MIXER
		name 'IEC958 Playback Default'
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.10 {
		iface MIXER
		name 'IEC958 Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.11 {
		iface PCM
		device 3
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.12 {
		iface CARD
		name 'HDMI/DP,pcm=7 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.13 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		index 1
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.14 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		index 1
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.15 {
		iface MIXER
		name 'IEC958 Playback Default'
		index 1
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.16 {
		iface MIXER
		name 'IEC958 Playback Switch'
		index 1
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.17 {
		iface PCM
		device 7
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.18 {
		iface CARD
		name 'HDMI/DP,pcm=8 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.19 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		index 2
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.20 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		index 2
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.21 {
		iface MIXER
		name 'IEC958 Playback Default'
		index 2
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.22 {
		iface MIXER
		name 'IEC958 Playback Switch'
		index 2
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.23 {
		iface PCM
		device 8
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.24 {
		iface MIXER
		name 'PCM Playback Volume'
		value.0 255
		value.1 255
		comment {
			access 'read write user'
			type INTEGER
			count 2
			range '0 - 255'
			tlv '0000000100000008ffffec1400000014'
			dbmin -5100
			dbmax 0
			dbvalue.0 0
			dbvalue.1 0
		}
	}
}
state.ThinkPadEC {
	control.1 {
		iface MIXER
		name 'Console Playback Switch'
		value true
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
}
--endcollapse--


!!All Loaded Modules
!!------------------

Module
fuse
nfsd
bridge
stp
llc
tun
kvm_intel
kvm
snd_hda_codec_hdmi
snd_hda_codec_conexant
thinkpad_acpi
snd_seq_dummy
cdc_ncm
snd_hda_intel
cdc_wdm
snd_seq_oss
cdc_acm
usbnet
mii
snd_hda_codec
snd_seq_midi
uvcvideo
snd_hwdep
videobuf2_vmalloc
snd_pcm_oss
snd_mixer_oss
videobuf2_memops
videobuf2_core
videodev
snd_rawmidi
snd_pcm
coretemp
snd_seq_midi_event
rtl8192ce
iTCO_wdt
snd_seq
rtlwifi
i915
rtl8192c_common
snd_page_alloc
drm_kms_helper
snd_seq_device
snd_timer
wmi
snd
soundcore
hid_logitech_dj
sdhci_pci
sdhci
e1000e


!!Sysfs Files
!!-----------

/sys/class/sound/hwC0D0/init_pin_configs:
0x19 0x04211040
0x1a 0x61a19050
0x1b 0x04a11060
0x1c 0x6121401f
0x1d 0x40f001f0
0x1e 0x40f001f0
0x1f 0x90170110
0x20 0x40f001f0
0x22 0x40f001f0
0x23 0x90a60170

/sys/class/sound/hwC0D0/driver_pin_configs:

/sys/class/sound/hwC0D0/user_pin_configs:

/sys/class/sound/hwC0D0/init_verbs:

/sys/class/sound/hwC0D3/init_pin_configs:
0x05 0x18560010
0x06 0x18560020
0x07 0x18560030

/sys/class/sound/hwC0D3/driver_pin_configs:

/sys/class/sound/hwC0D3/user_pin_configs:

/sys/class/sound/hwC0D3/init_verbs:


!!ALSA/HDA dmesg
!!------------------

[  128.256359] e1000e 0000:00:19.0: irq 48 for MSI/MSI-X
[  128.256390] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  128.256395] ehci_hcd 0000:00:1d.0: power state changed by ACPI to D0
--
[  148.383983] rtlwifi: wireless switch is on
[  148.384005] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  148.384192] usb usb3: root hub lost power or was reset
--
[  201.413406] i915 0000:00:02.0: setting latency timer to 64
[  201.414444] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  201.414553] ahci 0000:00:1f.2: setting latency timer to 64
--
[  216.049402] e1000e 0000:00:19.0: irq 48 for MSI/MSI-X
[  216.049415] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  216.049433] ehci_hcd 0000:00:1d.0: power state changed by ACPI to D0



[-- Attachment #3: alsa-info.txt.before --]
[-- Type: text/plain, Size: 28719 bytes --]

upload=true&script=true&cardinfo=
!!################################
!!ALSA Information Script v 0.4.60
!!################################

!!Script ran on: Tue May  8 07:02:56 UTC 2012


!!Linux Distribution
!!------------------

Debian GNU/Linux wheezy/sid \n \l


!!DMI Information
!!---------------

Manufacturer:      LENOVO
Product Name:      4291QY6
Product Version:   ThinkPad X220


!!Kernel Information
!!------------------

Kernel release:    3.4.0-rc6-zurg-00001-gfebb72a-dirty
Operating System:  GNU/Linux
Architecture:      x86_64
Processor:         unknown
SMP Enabled:       Yes


!!ALSA Version
!!------------

Driver version:     1.0.25
Library version:    1.0.25
Utilities version:  1.0.25


!!Loaded ALSA modules
!!-------------------

snd_hda_intel
thinkpad_acpi


!!Sound Servers on this system
!!----------------------------

Jack:
      Installed - Yes (/usr/bin/jackd)
      Running - No


!!Soundcards recognised by ALSA
!!-----------------------------

 0 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf2620000 irq 50
29 [ThinkPadEC     ]: ThinkPad EC - ThinkPad Console Audio Control
                      ThinkPad Console Audio Control at EC reg 0x30, fw unknown


!!PCI Soundcards installed in the system
!!--------------------------------------

00:1b.0 Audio device: Intel Corporation 6 Series/C200 Series Chipset Family High Definition Audio Controller (rev 04)


!!Advanced information - PCI Vendor/Device/Subsystem ID's
!!--------------------------------------------------------

00:1b.0 0403: 8086:1c20 (rev 04)
	Subsystem: 17aa:21da


!!Loaded sound module options
!!--------------------------

!!Module: snd_hda_intel
	align_buffer_size : -1
	bdl_pos_adj : 1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	enable : Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y,Y
	enable_msi : -1
	id : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	index : -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	model : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	patch : (null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null),(null)
	position_fix : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
	power_save : 1
	power_save_controller : N
	probe_mask : -1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1,-1
	probe_only : 0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0,0
	single_cmd : N
	snoop : Y

!!Module: thinkpad_acpi
	brightness_enable : 2
	brightness_mode : 4
	dbg_bluetoothemul : 0
	dbg_uwbemul : 0
	dbg_wlswemul : 0
	dbg_wwanemul : 0
	enable : Y
	experimental : 0
	fan_control : N
	force_load : N
	hotkey_report_mode : 0
	id : ThinkPadEC
	index : -536870912
	volume_capabilities : 0
	volume_control : N
	volume_mode : 3


!!HDA-Intel Codec information
!!---------------------------
--startcollapse--

Codec: Conexant CX20590
Address: 0
AFG Function Id: 0x1 (unsol 1)
Vendor Id: 0x14f1506e
Subsystem Id: 0x17aa21da
Revision Id: 0x100000
No Modem Function Group found
Default PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
Default Amp-In caps: N/A
Default Amp-Out caps: N/A
GPIO: io=4, o=0, i=0, unsolicited=1, wake=0
  IO[0]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[1]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[2]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
  IO[3]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
Node 0x10 [Audio Output] wcaps 0xc1d: Stereo Amp-Out R/L
  Control: name="Master Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Device: name="CONEXANT Analog", type="Audio", device=0
  Amp-Out caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-Out vals:  [0x49 0x49]
  Converter: stream=0, channel=0
  PCM:
    rates [0x560]: 44100 48000 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x11 [Audio Output] wcaps 0xc1d: Stereo Amp-Out R/L
  Amp-Out caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-Out vals:  [0x3c 0x3c]
  Converter: stream=0, channel=0
  PCM:
    rates [0x560]: 44100 48000 96000 192000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x12 [Audio Output] wcaps 0x611: Stereo Digital
  Converter: stream=0, channel=0
  Digital:
  Digital category: 0x0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x5]: PCM AC3
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x13 [Beep Generator Widget] wcaps 0x70000c: Mono Amp-Out
  Amp-Out caps: ofs=0x07, nsteps=0x07, stepsize=0x0f, mute=0
  Amp-Out vals:  [0x00]
Node 0x14 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Device: name="CONEXANT Analog", type="Audio", device=0
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x50 0x50] [0x80 0x80] [0x50 0x50] [0x80 0x80]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 4
     0x17 0x18 0x23* 0x24
Node 0x15 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 4
     0x17* 0x18 0x23 0x24
Node 0x16 [Audio Input] wcaps 0x100d1b: Stereo Amp-In R/L
  Amp-In caps: ofs=0x4a, nsteps=0x50, stepsize=0x03, mute=1
  Amp-In vals:  [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a] [0x4a 0x4a]
  Converter: stream=0, channel=0
  SDI-Select: 0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x1]: PCM
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 4
     0x17* 0x18 0x23 0x24
Node 0x17 [Audio Selector] wcaps 0x30050d: Stereo Amp-Out
  Amp-Out caps: ofs=0x00, nsteps=0x04, stepsize=0x27, mute=0
  Amp-Out vals:  [0x02 0x02]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 4
     0x1a 0x1b* 0x1d 0x1e
Node 0x18 [Audio Selector] wcaps 0x30050d: Stereo Amp-Out
  Amp-Out caps: ofs=0x00, nsteps=0x04, stepsize=0x27, mute=0
  Amp-Out vals:  [0x00 0x00]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 4
     0x1a* 0x1b 0x1d 0x1e
Node 0x19 [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x0000001c: OUT HP Detect
  Pin Default 0x04211040: [Jack] HP Out at Ext Right
    Conn = 1/8, Color = Black
    DefAssociation = 0x4, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=37, enabled=1
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10* 0x11
Node 0x1a [Pin Complex] wcaps 0x400481: Stereo
  Pincap 0x00001324: IN Detect
    Vref caps: HIZ 50 80
  Pin Default 0x61a19050: [N/A] Mic at Sep Rear
    Conn = 1/8, Color = Pink
    DefAssociation = 0x5, Sequence = 0x0
  Pin-ctls: 0x00: VREF_HIZ
  Unsolicited: tag=38, enabled=1
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x1b [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00011334: IN OUT EAPD Detect
    Vref caps: HIZ 50 80
  EAPD 0x2: EAPD
  Pin Default 0x04a11060: [Jack] Mic at Ext Right
    Conn = 1/8, Color = Black
    DefAssociation = 0x6, Sequence = 0x0
  Pin-ctls: 0x00: VREF_HIZ
  Unsolicited: tag=38, enabled=1
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10* 0x11
Node 0x1c [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00000014: OUT Detect
  Pin Default 0x6121401f: [N/A] HP Out at Sep Rear
    Conn = 1/8, Color = Green
    DefAssociation = 0x1, Sequence = 0xf
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=37, enabled=1
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10* 0x11
Node 0x1d [Pin Complex] wcaps 0x400581: Stereo
  Pincap 0x00010034: IN OUT EAPD Detect
  EAPD 0x2: EAPD
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x20: IN
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10* 0x11
Node 0x1e [Pin Complex] wcaps 0x400481: Stereo
  Pincap 0x00000024: IN Detect
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x20: IN
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x1f [Pin Complex] wcaps 0x400501: Stereo
  Pincap 0x00000010: OUT
  Pin Default 0x90170110: [Fixed] Speaker at Int N/A
    Conn = Analog, Color = Unknown
    DefAssociation = 0x1, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10* 0x11
Node 0x20 [Pin Complex] wcaps 0x400781: Stereo Digital
  Pincap 0x00000010: OUT
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x12
Node 0x21 [Audio Output] wcaps 0x611: Stereo Digital
  Converter: stream=0, channel=0
  Digital:
  Digital category: 0x0
  PCM:
    rates [0x160]: 44100 48000 96000
    bits [0xe]: 16 20 24
    formats [0x5]: PCM AC3
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x22 [Pin Complex] wcaps 0x400781: Stereo Digital
  Pincap 0x00000010: OUT
  Pin Default 0x40f001f0: [N/A] Other at Ext N/A
    Conn = Unknown, Color = Unknown
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Unsolicited: tag=00, enabled=0
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x21
Node 0x23 [Pin Complex] wcaps 0x40040b: Stereo Amp-In
  Amp-In caps: ofs=0x00, nsteps=0x04, stepsize=0x2f, mute=0
  Amp-In vals:  [0x02 0x02]
  Pincap 0x00000020: IN
  Pin Default 0x90a60170: [Fixed] Mic at Int N/A
    Conn = Digital, Color = Unknown
    DefAssociation = 0x7, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x20: IN
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
Node 0x24 [Audio Mixer] wcaps 0x20050b: Stereo Amp-In
  Amp-In caps: ofs=0x4a, nsteps=0x4a, stepsize=0x03, mute=1
  Amp-In vals:  [0x00 0x00] [0x00 0x00]
  Power states:  D0 D1 D2 D3 D3cold EPSS
  Power: setting=D0, actual=D0
  Connection: 2
     0x10 0x11
Node 0x25 [Vendor Defined Widget] wcaps 0xf00000: Mono
Codec: Intel CougarPoint HDMI
Address: 3
AFG Function Id: 0x1 (unsol 0)
Vendor Id: 0x80862805
Subsystem Id: 0x80860101
Revision Id: 0x100000
No Modem Function Group found
Default PCM:
    rates [0x0]:
    bits [0x0]:
    formats [0x0]:
Default Amp-In caps: N/A
Default Amp-Out caps: N/A
GPIO: io=0, o=0, i=0, unsolicited=0, wake=0
Node 0x02 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x03 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x04 [Audio Output] wcaps 0x6611: 8-Channels Digital
  Converter: stream=0, channel=0
  Digital: Enabled
  Digital category: 0x0
  PCM:
    rates [0x7f0]: 32000 44100 48000 88200 96000 176400 192000
    bits [0x1e]: 16 20 24 32
    formats [0x5]: PCM AC3
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
Node 0x05 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=3 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=0, device=0
  Control: name="IEC958 Playback Pro Mask", index=0, device=0
  Control: name="IEC958 Playback Default", index=0, device=0
  Control: name="IEC958 Playback Switch", index=0, device=0
  Control: name="ELD", index=0, device=3
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560010: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x1, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=01, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x02
Node 0x06 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=7 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=1, device=0
  Control: name="IEC958 Playback Pro Mask", index=1, device=0
  Control: name="IEC958 Playback Default", index=1, device=0
  Control: name="IEC958 Playback Switch", index=1, device=0
  Control: name="ELD", index=0, device=7
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560020: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x2, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=02, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x03
Node 0x07 [Pin Complex] wcaps 0x40778d: 8-Channels Digital Amp-Out CP
  Control: name="HDMI/DP,pcm=8 Jack", index=0, device=0
  Control: name="IEC958 Playback Con Mask", index=2, device=0
  Control: name="IEC958 Playback Pro Mask", index=2, device=0
  Control: name="IEC958 Playback Default", index=2, device=0
  Control: name="IEC958 Playback Switch", index=2, device=0
  Control: name="ELD", index=0, device=8
  Amp-Out caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
  Amp-Out vals:  [0x00 0x00]
  Pincap 0x09000094: OUT Detect HBR HDMI DP
  Pin Default 0x18560030: [Jack] Digital Out at Int HDMI
    Conn = Digital, Color = Unknown
    DefAssociation = 0x3, Sequence = 0x0
  Pin-ctls: 0x00:
  Unsolicited: tag=03, enabled=1
  Power states:  D0 D3 EPSS
  Power: setting=D0, actual=D0
  Connection: 1
     0x04
Node 0x08 [Vendor Defined Widget] wcaps 0xf00000: Mono
--endcollapse--


!!ALSA Device nodes
!!-----------------

crw-rw---T+ 1 root audio 116, 10 May  8 10:59 /dev/snd/controlC0
crw-rw---T+ 1 root audio 116,  2 May  8 10:59 /dev/snd/controlC29
crw-rw---T+ 1 root audio 116,  9 May  8 10:59 /dev/snd/hwC0D0
crw-rw---T+ 1 root audio 116,  8 May  8 10:59 /dev/snd/hwC0D3
crw-rw---T+ 1 root audio 116,  7 May  8 10:59 /dev/snd/pcmC0D0c
crw-rw---T+ 1 root audio 116,  6 May  8 11:02 /dev/snd/pcmC0D0p
crw-rw---T+ 1 root audio 116,  5 May  8 10:59 /dev/snd/pcmC0D3p
crw-rw---T+ 1 root audio 116,  4 May  8 10:59 /dev/snd/pcmC0D7p
crw-rw---T+ 1 root audio 116,  3 May  8 10:59 /dev/snd/pcmC0D8p
crw-rw---T+ 1 root audio 116,  1 May  8  2012 /dev/snd/seq
crw-rw---T+ 1 root audio 116, 33 May  8  2012 /dev/snd/timer

/dev/snd/by-path:
total 0
drwxr-xr-x 2 root root  80 May  8 10:59 .
drwxr-xr-x 3 root root 280 May  8 10:59 ..
lrwxrwxrwx 1 root root  12 May  8 10:59 pci-0000:00:1b.0 -> ../controlC0
lrwxrwxrwx 1 root root  13 May  8 10:59 platform-thinkpad_acpi -> ../controlC29


!!ALSA configuration files
!!------------------------

!!User specific config file (~/.asoundrc)

pcm.!default_ {
	type plug
	slave { pcm "jack" }
}

pcm.jack {
	type jack
	playback_ports {
		0 system:playback_1
		1 system:playback_2
	}
}


!!Aplay/Arecord output
!!------------

APLAY

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

ARECORD

**** List of CAPTURE Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: CONEXANT Analog [CONEXANT Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

!!Amixer output
!!-------------

!!-------Mixer controls for card 0 [PCH]

Card hw:0 'PCH'/'HDA Intel PCH at 0xf2620000 irq 50'
  Mixer name	: 'Intel CougarPoint HDMI'
  Components	: 'HDA:14f1506e,17aa21da,00100000 HDA:80862805,80860101,00100000'
  Controls      : 24
  Simple ctrls  : 7
Simple mixer control 'Master',0
  Capabilities: pvolume pswitch pswitch-joined penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 74
  Mono:
  Front Left: Playback 73 [99%] [-1.00dB] [on]
  Front Right: Playback 73 [99%] [-1.00dB] [on]
Simple mixer control 'PCM',0
  Capabilities: pvolume penum
  Playback channels: Front Left - Front Right
  Limits: Playback 0 - 255
  Mono:
  Front Left: Playback 255 [100%] [0.00dB]
  Front Right: Playback 255 [100%] [0.00dB]
Simple mixer control 'IEC958',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'IEC958',1
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'IEC958',2
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]
Simple mixer control 'Capture',0
  Capabilities: cvolume cswitch penum
  Capture channels: Front Left - Front Right
  Limits: Capture 0 - 80
  Front Left: Capture 80 [100%] [6.00dB] [on]
  Front Right: Capture 80 [100%] [6.00dB] [on]
Simple mixer control 'Analog Mic Boost',0
  Capabilities: cenum
  Items: '0dB' '10dB' '20dB' '30dB' '40dB'
  Item0: '20dB'

!!-------Mixer controls for card 29 [ThinkPadEC]

Card hw:29 'ThinkPadEC'/'ThinkPad Console Audio Control at EC reg 0x30, fw unknown'
  Mixer name	: 'ThinkPad EC (unknown)'
  Components	: ''
  Controls      : 1
  Simple ctrls  : 1
Simple mixer control 'Console',0
  Capabilities: pswitch pswitch-joined penum
  Playback channels: Mono
  Mono: Playback [on]


!!Alsactl output
!!-------------

--startcollapse--
state.PCH {
	control.1 {
		iface MIXER
		name 'Master Playback Volume'
		value.0 73
		value.1 73
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 74'
			dbmin -7400
			dbmax 0
			dbvalue.0 -100
			dbvalue.1 -100
		}
	}
	control.2 {
		iface MIXER
		name 'Master Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.3 {
		iface MIXER
		name 'Analog Mic Boost Capture Enum'
		value '20dB'
		comment {
			access 'read write'
			type ENUMERATED
			count 1
			item.0 '0dB'
			item.1 '10dB'
			item.2 '20dB'
			item.3 '30dB'
			item.4 '40dB'
		}
	}
	control.4 {
		iface MIXER
		name 'Capture Volume'
		value.0 80
		value.1 80
		comment {
			access 'read write'
			type INTEGER
			count 2
			range '0 - 80'
			dbmin -7400
			dbmax 600
			dbvalue.0 600
			dbvalue.1 600
		}
	}
	control.5 {
		iface MIXER
		name 'Capture Switch'
		value.0 true
		value.1 true
		comment {
			access 'read write'
			type BOOLEAN
			count 2
		}
	}
	control.6 {
		iface CARD
		name 'HDMI/DP,pcm=3 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.7 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.8 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.9 {
		iface MIXER
		name 'IEC958 Playback Default'
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.10 {
		iface MIXER
		name 'IEC958 Playback Switch'
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.11 {
		iface PCM
		device 3
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.12 {
		iface CARD
		name 'HDMI/DP,pcm=7 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.13 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		index 1
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.14 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		index 1
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.15 {
		iface MIXER
		name 'IEC958 Playback Default'
		index 1
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.16 {
		iface MIXER
		name 'IEC958 Playback Switch'
		index 1
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.17 {
		iface PCM
		device 7
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.18 {
		iface CARD
		name 'HDMI/DP,pcm=8 Jack'
		value false
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
	control.19 {
		iface MIXER
		name 'IEC958 Playback Con Mask'
		index 2
		value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.20 {
		iface MIXER
		name 'IEC958 Playback Pro Mask'
		index 2
		value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access read
			type IEC958
			count 1
		}
	}
	control.21 {
		iface MIXER
		name 'IEC958 Playback Default'
		index 2
		value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
		comment {
			access 'read write'
			type IEC958
			count 1
		}
	}
	control.22 {
		iface MIXER
		name 'IEC958 Playback Switch'
		index 2
		value true
		comment {
			access 'read write'
			type BOOLEAN
			count 1
		}
	}
	control.23 {
		iface PCM
		device 8
		name ELD
		value ''
		comment {
			access read
			type BYTES
			count 0
		}
	}
	control.24 {
		iface MIXER
		name 'PCM Playback Volume'
		value.0 255
		value.1 255
		comment {
			access 'read write user'
			type INTEGER
			count 2
			range '0 - 255'
			tlv '0000000100000008ffffec1400000014'
			dbmin -5100
			dbmax 0
			dbvalue.0 0
			dbvalue.1 0
		}
	}
}
state.ThinkPadEC {
	control.1 {
		iface MIXER
		name 'Console Playback Switch'
		value true
		comment {
			access read
			type BOOLEAN
			count 1
		}
	}
}
--endcollapse--


!!All Loaded Modules
!!------------------

Module
fuse
nfsd
bridge
stp
llc
tun
kvm_intel
kvm
snd_hda_codec_hdmi
snd_hda_codec_conexant
thinkpad_acpi
snd_seq_dummy
cdc_ncm
snd_hda_intel
cdc_wdm
snd_seq_oss
cdc_acm
usbnet
mii
snd_hda_codec
snd_seq_midi
uvcvideo
snd_hwdep
videobuf2_vmalloc
snd_pcm_oss
snd_mixer_oss
videobuf2_memops
videobuf2_core
videodev
snd_rawmidi
snd_pcm
coretemp
snd_seq_midi_event
rtl8192ce
iTCO_wdt
snd_seq
rtlwifi
i915
rtl8192c_common
snd_page_alloc
drm_kms_helper
snd_seq_device
snd_timer
wmi
snd
soundcore
hid_logitech_dj
sdhci_pci
sdhci
e1000e


!!Sysfs Files
!!-----------

/sys/class/sound/hwC0D0/init_pin_configs:
0x19 0x04211040
0x1a 0x61a19050
0x1b 0x04a11060
0x1c 0x6121401f
0x1d 0x40f001f0
0x1e 0x40f001f0
0x1f 0x90170110
0x20 0x40f001f0
0x22 0x40f001f0
0x23 0x90a60170

/sys/class/sound/hwC0D0/driver_pin_configs:

/sys/class/sound/hwC0D0/user_pin_configs:

/sys/class/sound/hwC0D0/init_verbs:

/sys/class/sound/hwC0D3/init_pin_configs:
0x05 0x18560010
0x06 0x18560020
0x07 0x18560030

/sys/class/sound/hwC0D3/driver_pin_configs:

/sys/class/sound/hwC0D3/user_pin_configs:

/sys/class/sound/hwC0D3/init_verbs:


!!ALSA/HDA dmesg
!!------------------

[    9.967497] [drm] Initialized i915 1.6.0 20080730 for 0000:00:02.0 on minor 0
[    9.967857] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[    9.968000] modprobe used greatest stack depth: 3216 bytes left
[   10.491393] input: HDA Intel PCH HDMI/DP,pcm=8 as /devices/pci0000:00/0000:00:1b.0/sound/card0/input10
[   10.491646] input: HDA Intel PCH HDMI/DP,pcm=7 as /devices/pci0000:00/0000:00:1b.0/sound/card0/input11
[   10.491865] input: HDA Intel PCH HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:1b.0/sound/card0/input12
[   10.788902] EXT4-fs (sda2): re-mounted. Opts: (null)
--
[   79.045557] ehci_hcd 0000:00:1d.0: setting latency timer to 64
[   79.045580] snd_hda_intel 0000:00:1b.0: irq 48 for MSI/MSI-X
[   79.045582] ahci 0000:00:1f.2: setting latency timer to 64
--
[  128.256359] e1000e 0000:00:19.0: irq 48 for MSI/MSI-X
[  128.256390] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  128.256395] ehci_hcd 0000:00:1d.0: power state changed by ACPI to D0
--
[  148.383983] rtlwifi: wireless switch is on
[  148.384005] snd_hda_intel 0000:00:1b.0: irq 50 for MSI/MSI-X
[  148.384192] usb usb3: root hub lost power or was reset



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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-08  7:13     ` Konstantin Khlebnikov
@ 2012-05-08  8:11       ` Takashi Iwai
  2012-05-08  8:49         ` Takashi Iwai
  0 siblings, 1 reply; 11+ messages in thread
From: Takashi Iwai @ 2012-05-08  8:11 UTC (permalink / raw)
  To: Konstantin Khlebnikov
  Cc: alsa-devel, linux-kernel, Jaroslav Kysela, David Henningsson

At Tue, 08 May 2012 11:13:23 +0400,
Konstantin Khlebnikov wrote:
> 
> Takashi Iwai wrote:
> > At Sun, 06 May 2012 12:32:14 +0400,
> > Konstantin Khlebnikov wrote:
> >>
> >> Konstantin Khlebnikov wrote:
> >>> Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
> >>> ("ALSA: hda - Set codec to D3 forcibly even if not used")
> >>> breaks sound for my notebook (thinkpad x220),
> >>> looks like codec cannot wake from power-save state after resume.
> >>> After reverting looks like all works fine.
> >>>
> >>> how to reproduce:
> >>> * unplug the power cord (to enable hda power safe mode)
> >>> * play something and stop
> >>> * wait until the background noise disappears (codec went into power-save mode)
> >>> * suspend
> >>> * resume
> >>> * play something again and hear the silence
> >>> --
> >>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> >>> the body of a message to majordomo@vger.kernel.org
> >>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> >>> Please read the FAQ at  http://www.tux.org/lkml/
> >>
> >> Bump
> >
> > It's a weekend, so don't expect quick responces from any normal person
> > :)
> 
> Yeah, sorry. In this country a mess with holidays and weekends.
> 
> >
> > Which 3.4-rc did you try?  There was a known problem with this codec
> > regarding the power-up sequence, but this should have been fixed in
> > the very recent version.
> 
> Bug still in latest v3.4-rc6.
> This is serious degradation since v3.3, so I hope it will be fixed before release.
> 
> >
> > If the latest Linus tree still shows the problem, try sound git tree
> > master or for-next branch.
> >     git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git
> 
> I don't see there anything related to this problem. Bug is still there.
> It's 100% reproductible and disappears after reverting that commit.
> Looks like driver missed one power-up cycle after system-resume,
> after second power-save down/up cycle all work fine.

OK.  Could you try to pass model=auto and see whether it changes
the behavior?  I've checked only the auto-parser mode recently.
It might be just the static quirk that got broken.

Note that the mixer elements will be renamed by this, so make sure
that you adjust the mixer before testing S3.


Takashi

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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-08  8:11       ` Takashi Iwai
@ 2012-05-08  8:49         ` Takashi Iwai
  2012-05-08 13:05           ` Konstantin Khlebnikov
  0 siblings, 1 reply; 11+ messages in thread
From: Takashi Iwai @ 2012-05-08  8:49 UTC (permalink / raw)
  To: Konstantin Khlebnikov
  Cc: alsa-devel, linux-kernel, Jaroslav Kysela, David Henningsson

At Tue, 08 May 2012 10:11:06 +0200,
Takashi Iwai wrote:
> 
> At Tue, 08 May 2012 11:13:23 +0400,
> Konstantin Khlebnikov wrote:
> > 
> > Takashi Iwai wrote:
> > > At Sun, 06 May 2012 12:32:14 +0400,
> > > Konstantin Khlebnikov wrote:
> > >>
> > >> Konstantin Khlebnikov wrote:
> > >>> Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
> > >>> ("ALSA: hda - Set codec to D3 forcibly even if not used")
> > >>> breaks sound for my notebook (thinkpad x220),
> > >>> looks like codec cannot wake from power-save state after resume.
> > >>> After reverting looks like all works fine.
> > >>>
> > >>> how to reproduce:
> > >>> * unplug the power cord (to enable hda power safe mode)
> > >>> * play something and stop
> > >>> * wait until the background noise disappears (codec went into power-save mode)
> > >>> * suspend
> > >>> * resume
> > >>> * play something again and hear the silence
> > >>> --
> > >>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> > >>> the body of a message to majordomo@vger.kernel.org
> > >>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> > >>> Please read the FAQ at  http://www.tux.org/lkml/
> > >>
> > >> Bump
> > >
> > > It's a weekend, so don't expect quick responces from any normal person
> > > :)
> > 
> > Yeah, sorry. In this country a mess with holidays and weekends.
> > 
> > >
> > > Which 3.4-rc did you try?  There was a known problem with this codec
> > > regarding the power-up sequence, but this should have been fixed in
> > > the very recent version.
> > 
> > Bug still in latest v3.4-rc6.
> > This is serious degradation since v3.3, so I hope it will be fixed before release.
> > 
> > >
> > > If the latest Linus tree still shows the problem, try sound git tree
> > > master or for-next branch.
> > >     git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git
> > 
> > I don't see there anything related to this problem. Bug is still there.
> > It's 100% reproductible and disappears after reverting that commit.
> > Looks like driver missed one power-up cycle after system-resume,
> > after second power-save down/up cycle all work fine.
> 
> OK.  Could you try to pass model=auto and see whether it changes
> the behavior?  I've checked only the auto-parser mode recently.
> It might be just the static quirk that got broken.
> 
> Note that the mixer elements will be renamed by this, so make sure
> that you adjust the mixer before testing S3.

FWIW, the below is an ad hoc fix.  If this works for you, I'll queue
it up for 3.4 kernel.


thanks,

Takashi

---
From: Takashi Iwai <tiwai@suse.de>
Subject: [PATCH] ALSA: hda - Fix S3 regression on Thinkpad X220

The commit [785f857d: ALSA: hda - Set codec to D3 forcibly even if not
used] caused an S3 regression on Lenovo Thinkpad X220.  The codec
stays in D3 even after the resume by some reason.

As a simple workaround, just avoid the new behavior by that commit,
i.e. going to D3 forcibly, for these Conexant codec chips.

Reported-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
 sound/pci/hda/hda_codec.c      |    3 ++-
 sound/pci/hda/hda_codec.h      |    1 +
 sound/pci/hda/patch_conexant.c |    1 +
 3 files changed, 4 insertions(+), 1 deletion(-)

diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 7a8fcc4..f38c4a8 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -5444,7 +5444,8 @@ int snd_hda_suspend(struct hda_bus *bus)
 	list_for_each_entry(codec, &bus->codec_list, list) {
 		if (hda_codec_is_power_on(codec))
 			hda_call_codec_suspend(codec);
-		else /* forcibly change the power to D3 even if not used */
+		else if (!codec->no_force_to_d3)
+			/* forcibly change the power to D3 even if not used */
 			hda_set_power_state(codec,
 					    codec->afg ? codec->afg : codec->mfg,
 					    AC_PWRST_D3);
diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h
index 56b4f74..2b3f646 100644
--- a/sound/pci/hda/hda_codec.h
+++ b/sound/pci/hda/hda_codec.h
@@ -854,6 +854,7 @@ struct hda_codec {
 	unsigned int single_adc_amp:1; /* adc in-amp takes no index
 					* (e.g. CX20549 codec)
 					*/
+	unsigned int no_force_to_d3:1;	/* don't go to D3 forcibly at sleep */
 	unsigned int no_sticky_stream:1; /* no sticky-PCM stream assignment */
 	unsigned int pins_shutup:1;	/* pins are shut up */
 	unsigned int no_trigger_sense:1; /* don't trigger at pin-sensing */
diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c
index d906c5b..6b680c2 100644
--- a/sound/pci/hda/patch_conexant.c
+++ b/sound/pci/hda/patch_conexant.c
@@ -3018,6 +3018,7 @@ static int patch_cxt5066(struct hda_codec *codec)
 	if (!spec)
 		return -ENOMEM;
 	codec->spec = spec;
+	codec->no_force_to_d3 = 1;
 
 	codec->patch_ops = conexant_patch_ops;
 	codec->patch_ops.init = conexant_init;
-- 
1.7.9.2


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

* Re: [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel
  2012-05-08  8:49         ` Takashi Iwai
@ 2012-05-08 13:05           ` Konstantin Khlebnikov
  2012-05-08 13:08             ` [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression Konstantin Khlebnikov
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-08 13:05 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, linux-kernel, Jaroslav Kysela, David Henningsson

Takashi Iwai wrote:
> At Tue, 08 May 2012 10:11:06 +0200,
> Takashi Iwai wrote:
>>
>> At Tue, 08 May 2012 11:13:23 +0400,
>> Konstantin Khlebnikov wrote:
>>>
>>> Takashi Iwai wrote:
>>>> At Sun, 06 May 2012 12:32:14 +0400,
>>>> Konstantin Khlebnikov wrote:
>>>>>
>>>>> Konstantin Khlebnikov wrote:
>>>>>> Mainline commit 785f857d1cb0856b612b46a0545b74aa2596e44a
>>>>>> ("ALSA: hda - Set codec to D3 forcibly even if not used")
>>>>>> breaks sound for my notebook (thinkpad x220),
>>>>>> looks like codec cannot wake from power-save state after resume.
>>>>>> After reverting looks like all works fine.
>>>>>>
>>>>>> how to reproduce:
>>>>>> * unplug the power cord (to enable hda power safe mode)
>>>>>> * play something and stop
>>>>>> * wait until the background noise disappears (codec went into power-save mode)
>>>>>> * suspend
>>>>>> * resume
>>>>>> * play something again and hear the silence
>>>>>> --
>>>>>> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
>>>>>> the body of a message to majordomo@vger.kernel.org
>>>>>> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>>>>>> Please read the FAQ at  http://www.tux.org/lkml/
>>>>>
>>>>> Bump
>>>>
>>>> It's a weekend, so don't expect quick responces from any normal person
>>>> :)
>>>
>>> Yeah, sorry. In this country a mess with holidays and weekends.
>>>
>>>>
>>>> Which 3.4-rc did you try?  There was a known problem with this codec
>>>> regarding the power-up sequence, but this should have been fixed in
>>>> the very recent version.
>>>
>>> Bug still in latest v3.4-rc6.
>>> This is serious degradation since v3.3, so I hope it will be fixed before release.
>>>
>>>>
>>>> If the latest Linus tree still shows the problem, try sound git tree
>>>> master or for-next branch.
>>>>      git://git.kernel.org/pub/scm/linux/kernel/git/tiwai/sound.git
>>>
>>> I don't see there anything related to this problem. Bug is still there.
>>> It's 100% reproductible and disappears after reverting that commit.
>>> Looks like driver missed one power-up cycle after system-resume,
>>> after second power-save down/up cycle all work fine.
>>
>> OK.  Could you try to pass model=auto and see whether it changes
>> the behavior?  I've checked only the auto-parser mode recently.
>> It might be just the static quirk that got broken.
>>
>> Note that the mixer elements will be renamed by this, so make sure
>> that you adjust the mixer before testing S3.
>
> FWIW, the below is an ad hoc fix.  If this works for you, I'll queue
> it up for 3.4 kernel.

Of course it helps, but this isn't "fix" at all!
Right fix follows...

>
>
> thanks,
>
> Takashi
>
> ---
> From: Takashi Iwai<tiwai@suse.de>
> Subject: [PATCH] ALSA: hda - Fix S3 regression on Thinkpad X220
>
> The commit [785f857d: ALSA: hda - Set codec to D3 forcibly even if not
> used] caused an S3 regression on Lenovo Thinkpad X220.  The codec
> stays in D3 even after the resume by some reason.
>
> As a simple workaround, just avoid the new behavior by that commit,
> i.e. going to D3 forcibly, for these Conexant codec chips.
>
> Reported-by: Konstantin Khlebnikov<khlebnikov@openvz.org>
> Signed-off-by: Takashi Iwai<tiwai@suse.de>
> ---
>   sound/pci/hda/hda_codec.c      |    3 ++-
>   sound/pci/hda/hda_codec.h      |    1 +
>   sound/pci/hda/patch_conexant.c |    1 +
>   3 files changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
> index 7a8fcc4..f38c4a8 100644
> --- a/sound/pci/hda/hda_codec.c
> +++ b/sound/pci/hda/hda_codec.c
> @@ -5444,7 +5444,8 @@ int snd_hda_suspend(struct hda_bus *bus)
>   	list_for_each_entry(codec,&bus->codec_list, list) {
>   		if (hda_codec_is_power_on(codec))
>   			hda_call_codec_suspend(codec);
> -		else /* forcibly change the power to D3 even if not used */
> +		else if (!codec->no_force_to_d3)
> +			/* forcibly change the power to D3 even if not used */
>   			hda_set_power_state(codec,
>   					    codec->afg ? codec->afg : codec->mfg,
>   					    AC_PWRST_D3);
> diff --git a/sound/pci/hda/hda_codec.h b/sound/pci/hda/hda_codec.h
> index 56b4f74..2b3f646 100644
> --- a/sound/pci/hda/hda_codec.h
> +++ b/sound/pci/hda/hda_codec.h
> @@ -854,6 +854,7 @@ struct hda_codec {
>   	unsigned int single_adc_amp:1; /* adc in-amp takes no index
>   					* (e.g. CX20549 codec)
>   					*/
> +	unsigned int no_force_to_d3:1;	/* don't go to D3 forcibly at sleep */
>   	unsigned int no_sticky_stream:1; /* no sticky-PCM stream assignment */
>   	unsigned int pins_shutup:1;	/* pins are shut up */
>   	unsigned int no_trigger_sense:1; /* don't trigger at pin-sensing */
> diff --git a/sound/pci/hda/patch_conexant.c b/sound/pci/hda/patch_conexant.c
> index d906c5b..6b680c2 100644
> --- a/sound/pci/hda/patch_conexant.c
> +++ b/sound/pci/hda/patch_conexant.c
> @@ -3018,6 +3018,7 @@ static int patch_cxt5066(struct hda_codec *codec)
>   	if (!spec)
>   		return -ENOMEM;
>   	codec->spec = spec;
> +	codec->no_force_to_d3 = 1;
>
>   	codec->patch_ops = conexant_patch_ops;
>   	codec->patch_ops.init = conexant_init;


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

* [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression
  2012-05-08 13:05           ` Konstantin Khlebnikov
@ 2012-05-08 13:08             ` Konstantin Khlebnikov
  2012-05-08 13:25               ` Takashi Iwai
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-08 13:08 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, linux-kernel, David Henningsson, Jaroslav Kysela

This fixes regression in shd-hda-codec after 785f857d1cb0856b612b46a0545b74aa2
("ALSA: hda - Set codec to D3 forcibly even if not used")

hda_set_power_state() call must be explicitly protected against recursive
snd_hda_power_up/down() calls, otherwise it accidentally switches device into
D0 right before suspend. As result after resume sound device stays in D3 state
and does not works because driver believes that the device is on already.

Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>
---
 sound/pci/hda/hda_codec.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
index 7a8fcc4..a0ea9d6 100644
--- a/sound/pci/hda/hda_codec.c
+++ b/sound/pci/hda/hda_codec.c
@@ -5444,10 +5444,14 @@ int snd_hda_suspend(struct hda_bus *bus)
 	list_for_each_entry(codec, &bus->codec_list, list) {
 		if (hda_codec_is_power_on(codec))
 			hda_call_codec_suspend(codec);
-		else /* forcibly change the power to D3 even if not used */
+		else {
+			/* forcibly change the power to D3 even if not used */
+			codec->power_transition = 1;
 			hda_set_power_state(codec,
 					    codec->afg ? codec->afg : codec->mfg,
 					    AC_PWRST_D3);
+			codec->power_transition = 0;
+		}
 		if (codec->patch_ops.post_suspend)
 			codec->patch_ops.post_suspend(codec);
 	}


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

* Re: [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression
  2012-05-08 13:08             ` [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression Konstantin Khlebnikov
@ 2012-05-08 13:25               ` Takashi Iwai
  2012-05-08 13:38                 ` Konstantin Khlebnikov
  0 siblings, 1 reply; 11+ messages in thread
From: Takashi Iwai @ 2012-05-08 13:25 UTC (permalink / raw)
  To: Konstantin Khlebnikov
  Cc: alsa-devel, linux-kernel, David Henningsson, Jaroslav Kysela

At Tue, 08 May 2012 17:08:10 +0400,
Konstantin Khlebnikov wrote:
> 
> This fixes regression in shd-hda-codec after 785f857d1cb0856b612b46a0545b74aa2
> ("ALSA: hda - Set codec to D3 forcibly even if not used")
> 
> hda_set_power_state() call must be explicitly protected against recursive
> snd_hda_power_up/down() calls, otherwise it accidentally switches device into
> D0 right before suspend. As result after resume sound device stays in D3 state
> and does not works because driver believes that the device is on already.
> 
> Signed-off-by: Konstantin Khlebnikov <khlebnikov@openvz.org>

Hrm, does this really fix your problem?  The path is called only
during the suspend.  Then, in the resume path, the codec is all
powered up anyway.

If the race between the leftover power-save work is really a culprit,
the fix would be just calling cancel_delayed_work_sync() before
that point...


thanks,

Takashi

> ---
>  sound/pci/hda/hda_codec.c |    6 +++++-
>  1 file changed, 5 insertions(+), 1 deletion(-)
> 
> diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
> index 7a8fcc4..a0ea9d6 100644
> --- a/sound/pci/hda/hda_codec.c
> +++ b/sound/pci/hda/hda_codec.c
> @@ -5444,10 +5444,14 @@ int snd_hda_suspend(struct hda_bus *bus)
>  	list_for_each_entry(codec, &bus->codec_list, list) {
>  		if (hda_codec_is_power_on(codec))
>  			hda_call_codec_suspend(codec);
> -		else /* forcibly change the power to D3 even if not used */
> +		else {
> +			/* forcibly change the power to D3 even if not used */
> +			codec->power_transition = 1;
>  			hda_set_power_state(codec,
>  					    codec->afg ? codec->afg : codec->mfg,
>  					    AC_PWRST_D3);
> +			codec->power_transition = 0;
> +		}
>  		if (codec->patch_ops.post_suspend)
>  			codec->patch_ops.post_suspend(codec);
>  	}
> 

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

* Re: [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression
  2012-05-08 13:25               ` Takashi Iwai
@ 2012-05-08 13:38                 ` Konstantin Khlebnikov
  2012-05-08 14:29                   ` Takashi Iwai
  0 siblings, 1 reply; 11+ messages in thread
From: Konstantin Khlebnikov @ 2012-05-08 13:38 UTC (permalink / raw)
  To: Takashi Iwai; +Cc: alsa-devel, linux-kernel, David Henningsson, Jaroslav Kysela

Takashi Iwai wrote:
> At Tue, 08 May 2012 17:08:10 +0400,
> Konstantin Khlebnikov wrote:
>>
>> This fixes regression in shd-hda-codec after 785f857d1cb0856b612b46a0545b74aa2
>> ("ALSA: hda - Set codec to D3 forcibly even if not used")
>>
>> hda_set_power_state() call must be explicitly protected against recursive
>> snd_hda_power_up/down() calls, otherwise it accidentally switches device into
>> D0 right before suspend. As result after resume sound device stays in D3 state
>> and does not works because driver believes that the device is on already.
>>
>> Signed-off-by: Konstantin Khlebnikov<khlebnikov@openvz.org>
>
> Hrm, does this really fix your problem?  The path is called only
> during the suspend.  Then, in the resume path, the codec is all
> powered up anyway.

This fixes my problem: during suspend hda_set_power_state() calls snd_hda_power_up()
it set codec->power_on = 1 and switches device into D0. At S3 resume codec->power_on == 1
but all devices actually in D3 state. As result on resume path device stays in D3,
but after one power-save cycle all works again.

>
> If the race between the leftover power-save work is really a culprit,
> the fix would be just calling cancel_delayed_work_sync() before
> that point...

Race was always there, my problem was caused by commit which mentioned above.

Whole this code is very racy, someone needs to fix it.

>
>
> thanks,
>
> Takashi
>
>> ---
>>   sound/pci/hda/hda_codec.c |    6 +++++-
>>   1 file changed, 5 insertions(+), 1 deletion(-)
>>
>> diff --git a/sound/pci/hda/hda_codec.c b/sound/pci/hda/hda_codec.c
>> index 7a8fcc4..a0ea9d6 100644
>> --- a/sound/pci/hda/hda_codec.c
>> +++ b/sound/pci/hda/hda_codec.c
>> @@ -5444,10 +5444,14 @@ int snd_hda_suspend(struct hda_bus *bus)
>>   	list_for_each_entry(codec,&bus->codec_list, list) {
>>   		if (hda_codec_is_power_on(codec))
>>   			hda_call_codec_suspend(codec);
>> -		else /* forcibly change the power to D3 even if not used */
>> +		else {
>> +			/* forcibly change the power to D3 even if not used */
>> +			codec->power_transition = 1;
>>   			hda_set_power_state(codec,
>>   					    codec->afg ? codec->afg : codec->mfg,
>>   					    AC_PWRST_D3);
>> +			codec->power_transition = 0;
>> +		}
>>   		if (codec->patch_ops.post_suspend)
>>   			codec->patch_ops.post_suspend(codec);
>>   	}
>>
> --
> To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
> Please read the FAQ at  http://www.tux.org/lkml/


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

* Re: [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression
  2012-05-08 13:38                 ` Konstantin Khlebnikov
@ 2012-05-08 14:29                   ` Takashi Iwai
  0 siblings, 0 replies; 11+ messages in thread
From: Takashi Iwai @ 2012-05-08 14:29 UTC (permalink / raw)
  To: Konstantin Khlebnikov
  Cc: alsa-devel, linux-kernel, David Henningsson, Jaroslav Kysela

At Tue, 08 May 2012 17:38:45 +0400,
Konstantin Khlebnikov wrote:
> 
> Takashi Iwai wrote:
> > At Tue, 08 May 2012 17:08:10 +0400,
> > Konstantin Khlebnikov wrote:
> >>
> >> This fixes regression in shd-hda-codec after 785f857d1cb0856b612b46a0545b74aa2
> >> ("ALSA: hda - Set codec to D3 forcibly even if not used")
> >>
> >> hda_set_power_state() call must be explicitly protected against recursive
> >> snd_hda_power_up/down() calls, otherwise it accidentally switches device into
> >> D0 right before suspend. As result after resume sound device stays in D3 state
> >> and does not works because driver believes that the device is on already.
> >>
> >> Signed-off-by: Konstantin Khlebnikov<khlebnikov@openvz.org>
> >
> > Hrm, does this really fix your problem?  The path is called only
> > during the suspend.  Then, in the resume path, the codec is all
> > powered up anyway.
> 
> This fixes my problem: during suspend hda_set_power_state() calls snd_hda_power_up()
> it set codec->power_on = 1 and switches device into D0. At S3 resume codec->power_on == 1
> but all devices actually in D3 state. As result on resume path device stays in D3,
> but after one power-save cycle all works again.

Ah, thanks, that explains a lot.

Then it'd be actually better to revert the commit instead of another
hack to paper over the nasty reincarnation.

The power-state change there shouldn't be involved with the whole
power-up sequence.  It should have been a simple "go-to-D3" sequence.
But this would need the assurance that the controller side is ready,
etc, and not too trivial to write with the current code base.

So, the right fix would be either implementing a straight
hda_set_power_state() code without any power-up sequence but only the
sanity check of the controller side, or fixing the original problem of
ALC269 differently, e.g. by always resuming immediately at the resume 
callback but immediately performing the power-saving work.

In either way, it's too late for 3.4 kernel.  And the original problem
is no critical issue in comparison with this regression.  So, a revert
would be the best thing we can do for now, IMO.


> > If the race between the leftover power-save work is really a culprit,
> > the fix would be just calling cancel_delayed_work_sync() before
> > that point...
> 
> Race was always there, my problem was caused by commit which mentioned above.
> 
> Whole this code is very racy, someone needs to fix it.

Yeah, I know.  I'll cook it up for 3.5 kernel.


thanks,

Takashi

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

end of thread, other threads:[~2012-05-08 14:29 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2012-05-04  7:21 [ALSA hda 3.4-rc] suspend2ram regression in snd_hda_intel Konstantin Khlebnikov
2012-05-06  8:32 ` Konstantin Khlebnikov
2012-05-06 10:37   ` Takashi Iwai
2012-05-08  7:13     ` Konstantin Khlebnikov
2012-05-08  8:11       ` Takashi Iwai
2012-05-08  8:49         ` Takashi Iwai
2012-05-08 13:05           ` Konstantin Khlebnikov
2012-05-08 13:08             ` [PATCH bugfix v3.4] ALSA: hda - fix "silence after S3" regression Konstantin Khlebnikov
2012-05-08 13:25               ` Takashi Iwai
2012-05-08 13:38                 ` Konstantin Khlebnikov
2012-05-08 14:29                   ` Takashi Iwai

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).