* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
[not found] <4983FE7A.1040201@wanadoo.fr>
@ 2009-01-31 7:52 ` Jean-Pierre André
2009-01-31 9:20 ` Takashi Iwai
` (2 more replies)
0 siblings, 3 replies; 36+ messages in thread
From: Jean-Pierre André @ 2009-01-31 7:52 UTC (permalink / raw)
Cc: alsa-devel
Hi,
> Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> through the speakers, although it does work through the headhpones. I ran
> alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> luck.
>
I have the same IDT codec 92HD71B7X on another
HP DV4 model, and I have tracked the problem to be
the kernel configuring IRQ 22 through the APIC, but
interrupts triggerring IRQ 20 (on kernel 2.6.27 and
alsa 1.0.19). It would be interesting if you could
confirm this by analyzing /proc/interrupts.
The workarounds I know of are :
- adding irqpoll to the boot options,
- or adding noapic to the boot options,
- using mplayer to play music.
There are with option "snd-hda-intel model=hp-m4"
(this option is for HP DV5/DV7, but HP DV4
is probably different)
I have not enough knowledge to tell where the problem
lies : kernel, apic, alsa.
Regards
Jean-Pierre
> I ran alsa-info, output here:
> http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
>
> I filed a bug, here:
> https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
>
> Any ideas?
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-01-31 7:52 ` [Fwd: HP DV4 1155 SE - No Sound through speakers...] Jean-Pierre André
@ 2009-01-31 9:20 ` Takashi Iwai
2009-02-01 22:34 ` Tim Barnette
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2 siblings, 0 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-01-31 9:20 UTC (permalink / raw)
To: Jean-Pierre André; +Cc: alsa-devel
At Sat, 31 Jan 2009 08:52:19 +0100,
Jean-Pierre André wrote:
>
>
> Hi,
>
> > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > through the speakers, although it does work through the headhpones. I ran
> > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> > luck.
> >
>
> I have the same IDT codec 92HD71B7X on another
> HP DV4 model, and I have tracked the problem to be
> the kernel configuring IRQ 22 through the APIC, but
> interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> alsa 1.0.19). It would be interesting if you could
> confirm this by analyzing /proc/interrupts.
>
> The workarounds I know of are :
> - adding irqpoll to the boot options,
> - or adding noapic to the boot options,
> - using mplayer to play music.
>
> There are with option "snd-hda-intel model=hp-m4"
> (this option is for HP DV5/DV7, but HP DV4
> is probably different)
For the latest driver, it might be better to use model=hp-dv5.
It's totally irrelevant with the IRQ issue, though.
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-01-31 7:52 ` [Fwd: HP DV4 1155 SE - No Sound through speakers...] Jean-Pierre André
2009-01-31 9:20 ` Takashi Iwai
@ 2009-02-01 22:34 ` Tim Barnette
2009-02-02 6:45 ` Takashi Iwai
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-01 22:34 UTC (permalink / raw)
To: Jean-Pierre André; +Cc: alsa-devel
Jean-Pierre, thank you for the suggestions.
Unfortunately, I have tried the boot options irqpoll, noapic with no luck.
Additionally, I installed mplayer and it produced no sound through the
speakers. Finally, I added option snd-hda-intel model=hp-m4 and hp-m5 in
alsa-base with no luck.
The whole time, if I plugged my headphones in, they would continue to work.
I did just notice one more thing. Although Linux shows my sounds as volume
all the way up, and not muted. The speaker mute button on the laptop
appears in red with the mute symbol (meaning it's muted). Any idea why that
is? Possible that it's the wrong driver? This is bizarre as the headhpones
work fine.
Any ideas?
On Sat, Jan 31, 2009 at 2:52 AM, Jean-Pierre André <
jean-pierre.andre@wanadoo.fr> wrote:
>
> Hi,
>
> > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > through the speakers, although it does work through the headhpones. I ran
> > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> > luck.
> >
>
> I have the same IDT codec 92HD71B7X on another
> HP DV4 model, and I have tracked the problem to be
> the kernel configuring IRQ 22 through the APIC, but
> interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> alsa 1.0.19). It would be interesting if you could
> confirm this by analyzing /proc/interrupts.
>
> The workarounds I know of are :
> - adding irqpoll to the boot options,
> - or adding noapic to the boot options,
> - using mplayer to play music.
>
> There are with option "snd-hda-intel model=hp-m4"
> (this option is for HP DV5/DV7, but HP DV4
> is probably different)
>
> I have not enough knowledge to tell where the problem
> lies : kernel, apic, alsa.
>
> Regards
>
> Jean-Pierre
>
>
> > I ran alsa-info, output here:
> >
> http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> >
> > I filed a bug, here:
> > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> >
> > Any ideas?
> >
>
>
>
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-01 22:34 ` Tim Barnette
@ 2009-02-02 6:45 ` Takashi Iwai
2009-02-02 15:17 ` Tim Barnette
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-02 6:45 UTC (permalink / raw)
To: Tim Barnette; +Cc: alsa-devel, Jean-Pierre André
At Sun, 1 Feb 2009 17:34:41 -0500,
Tim Barnette wrote:
>
> Jean-Pierre, thank you for the suggestions.
>
> Unfortunately, I have tried the boot options irqpoll, noapic with no luck.
> Additionally, I installed mplayer and it produced no sound through the
> speakers. Finally, I added option snd-hda-intel model=hp-m4 and hp-m5 in
> alsa-base with no luck.
Try "model=hp-dv5". After changing the model parameter, reboot once,
and check whether the module parameters are really set properly via
/sys/modules/snd_hda_intel/parameters/model.
Double-check the mixer elements all adjusted and unmuted. If it still
doesn't work, post with the attachment of alsa-info.sh (with
--no-upload option) output with model=hp-dv5.
Takashi
> The whole time, if I plugged my headphones in, they would continue to work.
>
> I did just notice one more thing. Although Linux shows my sounds as volume
> all the way up, and not muted. The speaker mute button on the laptop
> appears in red with the mute symbol (meaning it's muted). Any idea why that
> is? Possible that it's the wrong driver? This is bizarre as the headhpones
> work fine.
>
> Any ideas?
>
> On Sat, Jan 31, 2009 at 2:52 AM, Jean-Pierre André <
> jean-pierre.andre@wanadoo.fr> wrote:
>
> >
> > Hi,
> >
> > > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > > through the speakers, although it does work through the headhpones. I ran
> > > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> > > luck.
> > >
> >
> > I have the same IDT codec 92HD71B7X on another
> > HP DV4 model, and I have tracked the problem to be
> > the kernel configuring IRQ 22 through the APIC, but
> > interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> > alsa 1.0.19). It would be interesting if you could
> > confirm this by analyzing /proc/interrupts.
> >
> > The workarounds I know of are :
> > - adding irqpoll to the boot options,
> > - or adding noapic to the boot options,
> > - using mplayer to play music.
> >
> > There are with option "snd-hda-intel model=hp-m4"
> > (this option is for HP DV5/DV7, but HP DV4
> > is probably different)
> >
> > I have not enough knowledge to tell where the problem
> > lies : kernel, apic, alsa.
> >
> > Regards
> >
> > Jean-Pierre
> >
> >
> > > I ran alsa-info, output here:
> > >
> > http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> > >
> > > I filed a bug, here:
> > > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> > >
> > > Any ideas?
> > >
> >
> >
> >
> > _______________________________________________
> > Alsa-devel mailing list
> > Alsa-devel@alsa-project.org
> > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> >
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 6:45 ` Takashi Iwai
@ 2009-02-02 15:17 ` Tim Barnette
2009-02-02 15:25 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-02 15:17 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Jean-Pierre André
[-- Attachment #1: Type: text/plain, Size: 3575 bytes --]
Thanks, Takashi. I made this change and rebooted.
I noticed right away the mute light is no longer on... but still no sound
through speakers, only headphones..
/sys/module/snd_hda_intel/parameters/model
contains
hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
attached is the alsa-info.txt you requested..
On Mon, Feb 2, 2009 at 1:45 AM, Takashi Iwai <tiwai@suse.de> wrote:
> At Sun, 1 Feb 2009 17:34:41 -0500,
> Tim Barnette wrote:
> >
> > Jean-Pierre, thank you for the suggestions.
> >
> > Unfortunately, I have tried the boot options irqpoll, noapic with no
> luck.
> > Additionally, I installed mplayer and it produced no sound through the
> > speakers. Finally, I added option snd-hda-intel model=hp-m4 and hp-m5 in
> > alsa-base with no luck.
>
> Try "model=hp-dv5". After changing the model parameter, reboot once,
> and check whether the module parameters are really set properly via
> /sys/modules/snd_hda_intel/parameters/model.
>
> Double-check the mixer elements all adjusted and unmuted. If it still
> doesn't work, post with the attachment of alsa-info.sh (with
> --no-upload option) output with model=hp-dv5.
>
>
> Takashi
>
> > The whole time, if I plugged my headphones in, they would continue to
> work.
> >
> > I did just notice one more thing. Although Linux shows my sounds as
> volume
> > all the way up, and not muted. The speaker mute button on the laptop
> > appears in red with the mute symbol (meaning it's muted). Any idea why
> that
> > is? Possible that it's the wrong driver? This is bizarre as the
> headhpones
> > work fine.
> >
> > Any ideas?
> >
> > On Sat, Jan 31, 2009 at 2:52 AM, Jean-Pierre André <
> > jean-pierre.andre@wanadoo.fr> wrote:
> >
> > >
> > > Hi,
> > >
> > > > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound
> working
> > > > through the speakers, although it does work through the headhpones. I
> ran
> > > > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still
> no
> > > > luck.
> > > >
> > >
> > > I have the same IDT codec 92HD71B7X on another
> > > HP DV4 model, and I have tracked the problem to be
> > > the kernel configuring IRQ 22 through the APIC, but
> > > interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> > > alsa 1.0.19). It would be interesting if you could
> > > confirm this by analyzing /proc/interrupts.
> > >
> > > The workarounds I know of are :
> > > - adding irqpoll to the boot options,
> > > - or adding noapic to the boot options,
> > > - using mplayer to play music.
> > >
> > > There are with option "snd-hda-intel model=hp-m4"
> > > (this option is for HP DV5/DV7, but HP DV4
> > > is probably different)
> > >
> > > I have not enough knowledge to tell where the problem
> > > lies : kernel, apic, alsa.
> > >
> > > Regards
> > >
> > > Jean-Pierre
> > >
> > >
> > > > I ran alsa-info, output here:
> > > >
> > >
> http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> > > >
> > > > I filed a bug, here:
> > > > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> > > >
> > > > Any ideas?
> > > >
> > >
> > >
> > >
> > > _______________________________________________
> > > Alsa-devel mailing list
> > > Alsa-devel@alsa-project.org
> > > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> > >
> > _______________________________________________
> > Alsa-devel mailing list
> > Alsa-devel@alsa-project.org
> > http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
> >
>
[-- Attachment #2: alsa-info.txt --]
[-- Type: text/plain, Size: 25431 bytes --]
upload=true&script=true&cardinfo=
!!################################
!!ALSA Information Script v 0.4.53
!!################################
!!Script ran on: Mon Feb 2 15:11:38 UTC 2009
!!Linux Distribution
!!------------------
Ubuntu 8.10 \n \l DISTRIB_ID=Ubuntu DISTRIB_DESCRIPTION="Ubuntu 8.10"
!!Kernel Information
!!------------------
Kernel release: 2.6.27-11-generic
Operating System: GNU/Linux
Architecture: x86_64
Processor: unknown
SMP Enabled: Yes
!!ALSA Version
!!------------
Driver version: 1.0.19
Library version: 1.0.19
Utilities version: 1.0.19
!!Loaded ALSA modules
!!-------------------
snd_hda_intel
snd_hda_intel
!!Sound Servers on this system
!!----------------------------
Pulseaudio:
Installed - Yes (/usr/bin/pulseaudio)
Running - No
ESound Daemon:
Installed - Yes (/usr/bin/esd)
Running - No
!!Soundcards recognised by ALSA
!!-----------------------------
0 [SB ]: HDA-Intel - HDA ATI SB
HDA ATI SB at 0xd2500000 irq 16
1 [HDMI ]: HDA-Intel - HDA ATI HDMI
HDA ATI HDMI at 0xd2410000 irq 19
!!PCI Soundcards installed in the system
!!--------------------------------------
00:14.2 Audio device: ATI Technologies Inc SBx00 Azalia (Intel HDA)
01:05.1 Audio device: ATI Technologies Inc RS780 Azalia controller
!!Advanced information - PCI Vendor/Device/Susbsystem ID's
!!--------------------------------------------------------
00:14.2 0403: 1002:4383
Subsystem: 103c:30fb
--
01:05.1 0403: 1002:960f
Subsystem: 1002:960f
!!Modprobe options (Sound related)
!!--------------------------------
snd-atiixp-modem: index=-2
snd-intel8x0m: index=-2
snd-via82xx-modem: index=-2
snd-usb-audio: index=-2
snd-usb-usx2y: index=-2
snd-usb-caiaq: index=-2
snd-cmipci: mpu_port=0x330 fm_port=0x388
snd-pcsp: index=-2
snd-hda-intel: model=hp-dv5
!!Loaded sound module options
!!--------------------------
!!Module: snd_hda_intel
bdl_pos_adj : 32,32,-1,-1,-1,-1,-1,-1
enable : Y,Y,Y,Y,Y,Y,Y,Y
enable_msi : 0
id : <NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
index : -1,-1,-1,-1,-1,-1,-1,-1
model : hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
position_fix : 0,0,0,0,0,0,0,0
power_save : 0
power_save_controller : Y
probe_mask : -1,-1,-1,-1,-1,-1,-1,-1
probe_only : N,N,N,N,N,N,N,N
single_cmd : N
!!Module: snd_hda_intel
bdl_pos_adj : 32,32,-1,-1,-1,-1,-1,-1
enable : Y,Y,Y,Y,Y,Y,Y,Y
enable_msi : 0
id : <NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
index : -1,-1,-1,-1,-1,-1,-1,-1
model : hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
position_fix : 0,0,0,0,0,0,0,0
power_save : 0
power_save_controller : Y
probe_mask : -1,-1,-1,-1,-1,-1,-1,-1
probe_only : N,N,N,N,N,N,N,N
single_cmd : N
!!HDA-Intel Codec information
!!---------------------------
--startcollapse--
Codec: IDT 92HD71B7X
Address: 0
Vendor Id: 0x111d76b2
Subsystem Id: 0x103c30fb
Revision Id: 0x100302
No Modem Function Group found
Default PCM:
rates [0x7e0]: 44100 48000 88200 96000 176400 192000
bits [0xe]: 16 20 24
formats [0x1]: PCM
Default Amp-In caps: ofs=0x00, nsteps=0x00, stepsize=0x00, mute=1
Default Amp-Out caps: ofs=0x7f, nsteps=0x7f, stepsize=0x02, mute=1
GPIO: io=8, o=0, i=0, unsolicited=1, wake=1
IO[0]: enable=1, dir=1, wake=0, sticky=0, data=1, 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
IO[4]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
IO[5]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
IO[6]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
IO[7]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
Power-Map: 0x00
Analog Loopback: 0x00
Node 0x0a [Pin Complex] wcaps 0x400181: Stereo
Pincap 0x0000001c: OUT HP Detect
Pin Default 0x02214010: [Jack] HP Out at Ext Front
Conn = 1/8, Color = Green
DefAssociation = 0x1, Sequence = 0x0
Pin-ctls: 0x40: OUT
Unsolicited: tag=00, enabled=0
Connection: 3
0x10* 0x11 0x17
Node 0x0b [Pin Complex] wcaps 0x400081: Stereo
Pincap 0x00001724: IN Detect
Vref caps: HIZ 50 GRD 80
Pin Default 0x02a19020: [Jack] Mic at Ext Front
Conn = 1/8, Color = Pink
DefAssociation = 0x2, Sequence = 0x0
Pin-ctls: 0x24: IN VREF_80
Unsolicited: tag=01, enabled=1
Node 0x0c [Pin Complex] wcaps 0x400081: Stereo
Pincap 0x00001724: IN Detect
Vref caps: HIZ 50 GRD 80
Pin Default 0x40f100f0: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x0
Pin-ctls: 0x00: VREF_HIZ
Unsolicited: tag=00, enabled=0
Node 0x0d [Pin Complex] wcaps 0x400181: Stereo
Pincap 0x00000014: OUT Detect
Pin Default 0x40f100f1: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x1
Pin-ctls: 0x00:
Unsolicited: tag=00, enabled=0
Connection: 3
0x10* 0x11 0x17
Node 0x0e [Pin Complex] wcaps 0x400081: Stereo
Pincap 0x00001724: IN Detect
Vref caps: HIZ 50 GRD 80
Pin Default 0x40f100f2: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x2
Pin-ctls: 0x00: VREF_HIZ
Unsolicited: tag=00, enabled=0
Node 0x0f [Pin Complex] wcaps 0x400181: Stereo
Pincap 0x00000014: OUT Detect
Pin Default 0x40f100f3: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x3
Pin-ctls: 0x00:
Unsolicited: tag=00, enabled=0
Connection: 3
0x10 0x11 0x17*
Node 0x10 [Audio Output] wcaps 0xd0c05: Stereo Amp-Out R/L
Amp-Out caps: N/A
Amp-Out vals: [0x7f 0x7f]
Converter: stream=0, channel=0
Power: setting=D0, actual=D0
Delay: 13 samples
Node 0x11 [Audio Output] wcaps 0xd0c05: Stereo Amp-Out R/L
Amp-Out caps: N/A
Amp-Out vals: [0xff 0xff]
Converter: stream=0, channel=0
Power: setting=D0, actual=D0
Delay: 13 samples
Node 0x12 [Audio Input] wcaps 0x1d0541: Stereo
Converter: stream=0, channel=0
SDI-Select: 0
Power: setting=D3, actual=D3
Delay: 13 samples
Connection: 1
0x1c
Processing caps: benign=0, ncoeff=0
Node 0x13 [Audio Input] wcaps 0x1d0541: Stereo
Converter: stream=0, channel=0
SDI-Select: 0
Power: setting=D3, actual=D3
Delay: 13 samples
Connection: 1
0x1d
Processing caps: benign=0, ncoeff=0
Node 0x14 [Pin Complex] wcaps 0x400100: Mono
Pincap 0x00000010: OUT
Pin Default 0x40f100f4: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x4
Pin-ctls: 0x00:
Connection: 1
0x16
Node 0x15 [Audio Selector] wcaps 0x300101: Stereo
Connection: 3
0x10* 0x11 0x17
Node 0x16 [Audio Mixer] wcaps 0x200100: Mono
Connection: 1
0x15
Node 0x17 [Audio Mixer] wcaps 0x20010b: Stereo Amp-In
Amp-In caps: ofs=0x17, nsteps=0x1f, stepsize=0x05, mute=1
Amp-In vals: [0x97 0x97] [0x97 0x97] [0x97 0x97] [0x97 0x97] [0x97 0x97]
Connection: 5
0x10 0x11 0x27 0x1a 0x1b
Node 0x18 [Pin Complex] wcaps 0x40000d: Stereo Amp-Out
Amp-Out caps: ofs=0x00, nsteps=0x03, stepsize=0x27, mute=0
Amp-Out vals: [0x00 0x00]
Pincap 0x00000020: IN
Pin Default 0x40f100f5: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x5
Pin-ctls: 0x20: IN
Node 0x19 [Pin Complex] wcaps 0x40000d: Stereo Amp-Out
Amp-Out caps: ofs=0x00, nsteps=0x03, stepsize=0x27, mute=0
Amp-Out vals: [0x00 0x00]
Pincap 0x00000020: IN
Pin Default 0x40f100f6: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x6
Pin-ctls: 0x20: IN
Node 0x1a [Audio Selector] wcaps 0x30010d: Stereo Amp-Out
Amp-Out caps: ofs=0x00, nsteps=0x03, stepsize=0x27, mute=0
Amp-Out vals: [0x00 0x00]
Connection: 3
0x0b* 0x0c 0x0e
Node 0x1b [Audio Selector] wcaps 0x30010d: Stereo Amp-Out
Amp-Out caps: ofs=0x00, nsteps=0x03, stepsize=0x27, mute=0
Amp-Out vals: [0x00 0x00]
Connection: 3
0x0b* 0x0c 0x0e
Node 0x1c [Audio Selector] wcaps 0x30090d: Stereo Amp-Out R/L
Amp-Out caps: ofs=0x00, nsteps=0x0f, stepsize=0x05, mute=1
Amp-Out vals: [0x0d 0x0d]
Connection: 4
0x1a* 0x17 0x18 0x19
Node 0x1d [Audio Selector] wcaps 0x30090d: Stereo Amp-Out R/L
Amp-Out caps: ofs=0x00, nsteps=0x0f, stepsize=0x05, mute=1
Amp-Out vals: [0x80 0x80]
Connection: 4
0x1b* 0x17 0x18 0x19
Node 0x1e [Pin Complex] wcaps 0x400301: Stereo Digital
Pincap 0x00000010: OUT
Pin Default 0x40f100f7: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x7
Pin-ctls: 0x00:
Connection: 1
0x24
Node 0x1f [Pin Complex] wcaps 0x400701: Stereo Digital
Pincap 0x00010010: OUT EAPD
EAPD 0x0:
Pin Default 0x40f100f8: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x8
Pin-ctls: 0x00:
Power: setting=D0, actual=D0
Connection: 2
0x24* 0x25
Node 0x20 [Pin Complex] wcaps 0x400301: Stereo Digital
Pincap 0x00000010: OUT
Pin Default 0x40f100f9: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0x9
Pin-ctls: 0x00:
Connection: 1
0x25
Node 0x21 [Audio Output] wcaps 0x40211: Stereo Digital
Converter: stream=0, channel=0
Digital:
Digital category: 0x0
PCM:
rates [0x7e0]: 44100 48000 88200 96000 176400 192000
bits [0xe]: 16 20 24
formats [0x5]: PCM AC3
Delay: 4 samples
Node 0x22 [Audio Output] wcaps 0x40211: Stereo Digital
Converter: stream=0, channel=0
Digital:
Digital category: 0x0
PCM:
rates [0x7e0]: 44100 48000 88200 96000 176400 192000
bits [0xe]: 16 20 24
formats [0x5]: PCM AC3
Delay: 4 samples
Node 0x23 [Vendor Defined Widget] wcaps 0xf00000: Mono
Node 0x24 [Audio Selector] wcaps 0x300101: Stereo
Connection: 3
0x21* 0x1c 0x1d
Node 0x25 [Audio Selector] wcaps 0x300101: Stereo
Connection: 3
0x22* 0x1c 0x1d
Node 0x26 [Beep Generator Widget] wcaps 0x70000c: Mono Amp-Out
Amp-Out caps: ofs=0x03, nsteps=0x03, stepsize=0x17, mute=1
Amp-Out vals: [0x00]
Node 0x27 [Pin Complex] wcaps 0x400000: Mono
Pincap 0x00000020: IN
Pin Default 0x40f100fa: [N/A] Other at Ext N/A
Conn = 1/8, Color = Unknown
DefAssociation = 0xf, Sequence = 0xa
Pin-ctls: 0x00:
Node 0x28 [Volume Knob Widget] wcaps 0x600000: Mono
Volume-Knob: delta=1, steps=127, direct=1, val=127
Connection: 2
0x10* 0x11
Codec: LSI ID 1040
Address: 1
Vendor Id: 0x11c11040
Subsystem Id: 0x103c137e
Revision Id: 0x100200
Modem Function Group: 0x1
Codec: ATI RS690/780 HDMI
Address: 0
Vendor Id: 0x1002791a
Subsystem Id: 0x791a00
Revision Id: 0x100000
No Modem Function Group found
Default PCM:
rates [0x40]: 48000
bits [0x2]: 16
formats [0x1]: PCM
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 0x201: Stereo Digital
Converter: stream=0, channel=0
Digital:
Digital category: 0x0
Node 0x03 [Pin Complex] wcaps 0x400381: Stereo Digital
Pincap 0x00000094: OUT Detect HDMI
Pin Default 0x18560010: [Jack] Digital Out at Int HDMI
Conn = Digital, Color = Unknown
DefAssociation = 0x1, Sequence = 0x0
Pin-ctls: 0x40: OUT
Unsolicited: tag=00, enabled=0
Connection: 1
0x02
--endcollapse--
!!ALSA Device nodes
!!-----------------
crw-rw----+ 1 root audio 116, 0 Feb 2 10:04 /dev/snd/controlC0
crw-rw----+ 1 root audio 116, 32 Feb 2 10:04 /dev/snd/controlC1
crw-rw----+ 1 root audio 116, 4 Feb 2 10:04 /dev/snd/hwC0D0
crw-rw----+ 1 root audio 116, 5 Feb 2 10:04 /dev/snd/hwC0D1
crw-rw----+ 1 root audio 116, 36 Feb 2 10:04 /dev/snd/hwC1D0
crw-rw----+ 1 root audio 116, 24 Feb 2 10:05 /dev/snd/pcmC0D0c
crw-rw----+ 1 root audio 116, 16 Feb 2 10:07 /dev/snd/pcmC0D0p
crw-rw----+ 1 root audio 116, 51 Feb 2 10:04 /dev/snd/pcmC1D3p
crw-rw----+ 1 root audio 116, 1 Feb 2 10:04 /dev/snd/seq
crw-rw----+ 1 root audio 116, 33 Feb 2 10:04 /dev/snd/timer
!!Aplay/Arecord output
!!------------
APLAY
**** List of PLAYBACK Hardware Devices ****
card 0: SB [HDA ATI SB], device 0: STAC92xx Analog [STAC92xx Analog]
Subdevices: 1/1
Subdevice #0: subdevice #0
card 1: HDMI [HDA ATI HDMI], device 3: ATI HDMI [ATI HDMI]
Subdevices: 1/1
Subdevice #0: subdevice #0
ARECORD
**** List of CAPTURE Hardware Devices ****
card 0: SB [HDA ATI SB], device 0: STAC92xx Analog [STAC92xx Analog]
Subdevices: 2/2
Subdevice #0: subdevice #0
Subdevice #1: subdevice #1
!!Amixer output
!!-------------
!!-------Mixer controls for card 0 [SB]
Card hw:0 'SB'/'HDA ATI SB at 0xd2500000 irq 16'
Mixer name : 'IDT 92HD71B7X'
Components : 'HDA:111d76b2,103c30fb,00100302 HDA:11c11040,103c137e,00100200'
Controls : 29
Simple ctrls : 20
Simple mixer control 'Master',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined
Playback channels: Mono
Limits: Playback 0 - 127
Mono: Playback 127 [100%] [0.00dB] [on]
Simple mixer control 'Headphone',0
Capabilities: pvolume pswitch
Playback channels: Front Left - Front Right
Limits: Playback 0 - 127
Mono:
Front Left: Playback 127 [100%] [0.00dB] [on]
Front Right: Playback 127 [100%] [0.00dB] [on]
Simple mixer control 'PCM',0
Capabilities: pvolume
Playback channels: Front Left - Front Right
Limits: Playback 0 - 255
Mono:
Front Left: Playback 155 [61%] [-20.00dB]
Front Right: Playback 155 [61%] [-20.00dB]
Simple mixer control 'IEC958 Playback Source',0
Capabilities: enum
Items: 'Digital Playback' 'Analog Mux 1' 'Analog Mux 2'
Item0: 'Digital Playback'
Simple mixer control 'IEC958 Playback Source',1
Capabilities: enum
Items: 'Digital Playback' 'Analog Mux 1' 'Analog Mux 2'
Item0: 'Digital Playback'
Simple mixer control 'Capture',0
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 15
Front Left: Capture 13 [87%] [19.50dB] [on]
Front Right: Capture 13 [87%] [19.50dB] [on]
Simple mixer control 'Capture',1
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 15
Front Left: Capture 0 [0%] [0.00dB] [off]
Front Right: Capture 0 [0%] [0.00dB] [off]
Simple mixer control 'Analog Loopback',0
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'Analog Loopback',1
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [off]
Simple mixer control 'DAC0',0
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 31
Front Left: Capture 23 [74%] [0.00dB] [off]
Front Right: Capture 23 [74%] [0.00dB] [off]
Simple mixer control 'DAC1',0
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 31
Front Left: Capture 23 [74%] [0.00dB] [off]
Front Right: Capture 23 [74%] [0.00dB] [off]
Simple mixer control 'Digital Input Source',0
Capabilities: enum
Items: 'Analog Inputs' 'Mixer' 'Digital Mic 1' 'Digital Mic 2'
Item0: 'Analog Inputs'
Simple mixer control 'Digital Input Source',1
Capabilities: enum
Items: 'Analog Inputs' 'Mixer' 'Digital Mic 1' 'Digital Mic 2'
Item0: 'Analog Inputs'
Simple mixer control 'Import0 Mux',0
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 31
Front Left: Capture 23 [74%] [0.00dB] [off]
Front Right: Capture 23 [74%] [0.00dB] [off]
Simple mixer control 'Import1 Mux',0
Capabilities: cvolume cswitch
Capture channels: Front Left - Front Right
Limits: Capture 0 - 31
Front Left: Capture 23 [74%] [0.00dB] [off]
Front Right: Capture 23 [74%] [0.00dB] [off]
Simple mixer control 'Input Source',0
Capabilities: cenum
Items: 'Mic'
Item0: 'Mic'
Simple mixer control 'Input Source',1
Capabilities: cenum
Items: 'Mic'
Item0: 'Mic'
Simple mixer control 'Mux',0
Capabilities: cvolume
Capture channels: Front Left - Front Right
Limits: Capture 0 - 3
Front Left: Capture 0 [0%] [0.00dB]
Front Right: Capture 0 [0%] [0.00dB]
Simple mixer control 'Mux',1
Capabilities: cvolume
Capture channels: Front Left - Front Right
Limits: Capture 0 - 3
Front Left: Capture 0 [0%] [0.00dB]
Front Right: Capture 0 [0%] [0.00dB]
Simple mixer control 'PC Beep',0
Capabilities: pvolume pvolume-joined pswitch pswitch-joined
Playback channels: Mono
Limits: Playback 0 - 3
Mono: Playback 0 [0%] [-18.00dB] [on]
!!-------Mixer controls for card 1 [HDMI]
Card hw:1 'HDMI'/'HDA ATI HDMI at 0xd2410000 irq 19'
Mixer name : 'ATI RS690/780 HDMI'
Components : 'HDA:1002791a,00791a00,00100000'
Controls : 4
Simple ctrls : 1
Simple mixer control 'IEC958',0
Capabilities: pswitch pswitch-joined
Playback channels: Mono
Mono: Playback [off]
!!Alsactl output
!!-------------
--startcollapse--
state.SB {
control.1 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Mic
iface MIXER
name 'Input Source'
value Mic
}
control.2 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 Mic
iface MIXER
name 'Input Source'
index 1
value Mic
}
control.3 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Loopback'
value false
}
control.4 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Analog Loopback'
index 1
value false
}
control.5 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 15'
comment.dbmin 0
comment.dbmax 2250
iface MIXER
name 'Capture Volume'
value.0 13
value.1 13
}
control.6 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Capture Switch'
value.0 true
value.1 true
}
control.7 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 15'
comment.dbmin 0
comment.dbmax 2250
iface MIXER
name 'Capture Volume'
index 1
value.0 0
value.1 0
}
control.8 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Capture Switch'
index 1
value.0 false
value.1 false
}
control.9 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Import0 Mux Capture Switch'
value.0 false
value.1 false
}
control.10 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin -3450
comment.dbmax 1200
iface MIXER
name 'Import0 Mux Capture Volume'
value.0 23
value.1 23
}
control.11 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Import1 Mux Capture Switch'
value.0 false
value.1 false
}
control.12 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin -3450
comment.dbmax 1200
iface MIXER
name 'Import1 Mux Capture Volume'
value.0 23
value.1 23
}
control.13 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'DAC0 Capture Switch'
value.0 false
value.1 false
}
control.14 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin -3450
comment.dbmax 1200
iface MIXER
name 'DAC0 Capture Volume'
value.0 23
value.1 23
}
control.15 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'DAC1 Capture Switch'
value.0 false
value.1 false
}
control.16 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 31'
comment.dbmin -3450
comment.dbmax 1200
iface MIXER
name 'DAC1 Capture Volume'
value.0 23
value.1 23
}
control.17 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 127'
comment.dbmin -9525
comment.dbmax 0
iface MIXER
name 'Headphone Playback Volume'
value.0 127
value.1 127
}
control.18 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 2
iface MIXER
name 'Headphone Playback Switch'
value.0 true
value.1 true
}
control.19 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'PC Beep Playback Switch'
value true
}
control.20 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 3'
comment.dbmin -1800
comment.dbmax 0
iface MIXER
name 'PC Beep Playback Volume'
value 0
}
control.21 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 3'
comment.dbmin 0
comment.dbmax 3000
iface MIXER
name 'Mux Capture Volume'
value.0 0
value.1 0
}
control.22 {
comment.access 'read write'
comment.type INTEGER
comment.count 2
comment.range '0 - 3'
comment.dbmin 0
comment.dbmax 3000
iface MIXER
name 'Mux Capture Volume'
index 1
value.0 0
value.1 0
}
control.23 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Analog Inputs'
comment.item.1 Mixer
comment.item.2 'Digital Mic 1'
comment.item.3 'Digital Mic 2'
iface MIXER
name 'Digital Input Source'
value 'Analog Inputs'
}
control.24 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Analog Inputs'
comment.item.1 Mixer
comment.item.2 'Digital Mic 1'
comment.item.3 'Digital Mic 2'
iface MIXER
name 'Digital Input Source'
index 1
value 'Analog Inputs'
}
control.25 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Digital Playback'
comment.item.1 'Analog Mux 1'
comment.item.2 'Analog Mux 2'
iface MIXER
name 'IEC958 Playback Source'
value 'Digital Playback'
}
control.26 {
comment.access 'read write'
comment.type ENUMERATED
comment.count 1
comment.item.0 'Digital Playback'
comment.item.1 'Analog Mux 1'
comment.item.2 'Analog Mux 2'
iface MIXER
name 'IEC958 Playback Source'
index 1
value 'Digital Playback'
}
control.27 {
comment.access 'read write'
comment.type INTEGER
comment.count 1
comment.range '0 - 127'
comment.dbmin -9525
comment.dbmax 0
iface MIXER
name 'Master Playback Volume'
value 127
}
control.28 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'Master Playback Switch'
value true
}
control.29 {
comment.access 'read write user'
comment.type INTEGER
comment.count 2
comment.range '0 - 255'
comment.tlv '0000000100000008ffffec1400000014'
comment.dbmin -5100
comment.dbmax 0
iface MIXER
name 'PCM Playback Volume'
value.0 155
value.1 155
}
}
state.HDMI {
control.1 {
comment.access read
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Con Mask'
value '0fff000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.2 {
comment.access read
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Pro Mask'
value '0f00000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.3 {
comment.access 'read write'
comment.type IEC958
comment.count 1
iface MIXER
name 'IEC958 Playback Default'
value '0400000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000000'
}
control.4 {
comment.access 'read write'
comment.type BOOLEAN
comment.count 1
iface MIXER
name 'IEC958 Playback Switch'
value false
}
}
--endcollapse--
!!All Loaded Modules
!!------------------
Module
ipv6
af_packet
binfmt_misc
rfcomm
sco
bridge
stp
bnep
l2cap
ppdev
vmnet
vmblock
vmci
vmmon
powernow_k8
cpufreq_ondemand
cpufreq_userspace
cpufreq_conservative
cpufreq_powersave
cpufreq_stats
freq_table
container
pci_slot
sbs
sbshc
iptable_filter
ip_tables
x_tables
parport_pc
lp
parport
joydev
snd_hda_codec_atihdmi
snd_hda_codec_idt
snd_hda_intel
snd_hda_codec
snd_hwdep
snd_pcm_oss
snd_mixer_oss
snd_pcm
snd_seq_dummy
snd_seq_oss
snd_seq_midi
snd_rawmidi
snd_seq_midi_event
snd_seq
snd_timer
uvcvideo
snd_seq_device
compat_ioctl32
snd
evdev
videodev
i2c_piix4
serio_raw
pcspkr
btusb
sdhci_pci
psmouse
ieee80211_crypt_tkip
sdhci
soundcore
v4l1_compat
wl
ieee80211_crypt
i2c_core
bluetooth
mmc_core
snd_page_alloc
fglrx
battery
video
output
wmi
button
ac
shpchp
pci_hotplug
ext3
jbd
mbcache
usbhid
hid
sr_mod
sd_mod
crc_t10dif
cdrom
sg
ata_generic
pata_acpi
pata_atiixp
ahci
r8169
mii
ehci_hcd
ohci_hcd
libata
scsi_mod
dock
usbcore
thermal
processor
fan
fbcon
tileblit
font
bitblit
softcursor
fuse
[-- Attachment #3: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 15:17 ` Tim Barnette
@ 2009-02-02 15:25 ` Takashi Iwai
2009-02-02 16:26 ` Tim Barnette
2009-02-13 19:16 ` Tim Barnette
0 siblings, 2 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-02 15:25 UTC (permalink / raw)
To: Tim Barnette; +Cc: alsa-devel, Jean-Pierre André
At Mon, 2 Feb 2009 10:17:03 -0500,
Tim Barnette wrote:
>
> Thanks, Takashi. I made this change and rebooted.
>
> I noticed right away the mute light is no longer on... but still no sound
> through speakers, only headphones..
>
> /sys/module/snd_hda_intel/parameters/model
> contains
> hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
>
> attached is the alsa-info.txt you requested..
Did you try the latest alsa-driver snapshot?
If it still doesn't work, I guess this is a BIOS problem.
The other HP dv laptops show the widget 0x0d as the speaker while
yours is unused.
Try to run:
hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 15:25 ` Takashi Iwai
@ 2009-02-02 16:26 ` Tim Barnette
2009-02-02 16:28 ` Takashi Iwai
2009-02-13 19:16 ` Tim Barnette
1 sibling, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-02 16:26 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Jean-Pierre André
Thanks, Takashi. I tried installing the latest snapshot but wound up
recompiling a bunch of stuff (which my box is not configured for)... Is
there an easy way to download and install the latest snapshot?
Is there a way to fix the 0x0d widget? BIOS flash? laptop seems kind of
new for that...
On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> At Mon, 2 Feb 2009 10:17:03 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I made this change and rebooted.
> >
> > I noticed right away the mute light is no longer on... but still no sound
> > through speakers, only headphones..
> >
> > /sys/module/snd_hda_intel/parameters/model
> > contains
> > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> >
> > attached is the alsa-info.txt you requested..
>
> Did you try the latest alsa-driver snapshot?
>
> If it still doesn't work, I guess this is a BIOS problem.
> The other HP dv laptops show the widget 0x0d as the speaker while
> yours is unused.
>
> Try to run:
> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>
>
> Takashi
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 16:26 ` Tim Barnette
@ 2009-02-02 16:28 ` Takashi Iwai
2009-02-02 17:01 ` Tim Barnette
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-02 16:28 UTC (permalink / raw)
To: Tim Barnette; +Cc: alsa-devel, Jean-Pierre André
At Mon, 2 Feb 2009 11:26:25 -0500,
Tim Barnette wrote:
>
> Thanks, Takashi. I tried installing the latest snapshot but wound up
> recompiling a bunch of stuff (which my box is not configured for)... Is there
> an easy way to download and install the latest snapshot?
ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/alsa-driver-snapshot.tar.gz
> Is there a way to fix the 0x0d widget? BIOS flash? laptop seems kind of new
> for that...
Try the hda-verb command first to check whether it's really an issue
of 0x0d.
Takashi
>
> On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
>
> At Mon, 2 Feb 2009 10:17:03 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I made this change and rebooted.
> >
> > I noticed right away the mute light is no longer on... but still no
> sound
> > through speakers, only headphones..
> >
> > /sys/module/snd_hda_intel/parameters/model
> > contains
> > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> >
> > attached is the alsa-info.txt you requested..
>
> Did you try the latest alsa-driver snapshot?
>
> If it still doesn't work, I guess this is a BIOS problem.
> The other HP dv laptops show the widget 0x0d as the speaker while
> yours is unused.
>
> Try to run:
> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>
> Takashi
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 16:28 ` Takashi Iwai
@ 2009-02-02 17:01 ` Tim Barnette
2009-02-02 17:10 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-02 17:01 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Jean-Pierre André
Thanks, a few more questions.. sorry I don't understand most of this..
1) hda-verb - I can't find this.. what is it? Where do I run it?
2) Inside of the snapshot, there are three steps (6, 7,8 below) that I need
help with..
6 - i already have /dev/snd with some stuff in it... so, I won't run this
step..
7 - edit it to do what?
8 - I dont know the name of my card..
6) Run the './snddevices' script to create new sound devices in /dev
directory.
Skip this step, if you have already /dev/snd/* files, or if you're
using a DEVFS or udev.
7) Edit your kernel module config (either /etc/modprobe.conf or
/etc/modules.conf, depending on the kernel version). If you are not
sure, what to do, you may try the alsaconf script available in
the alsa-utils package.
8) Run 'modprobe snd-xxxx' where xxxx is the name of your card.
Note: All ALSA ISA drivers support ISA PnP natively, so you don't need
isapnptools any more. Don't use both together. It will
conflict. For disabling the ALSA ISA PnP support, specify
--with-isapnp=no configure switch.
On Mon, Feb 2, 2009 at 11:28 AM, Takashi Iwai <tiwai@suse.de> wrote:
> At Mon, 2 Feb 2009 11:26:25 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I tried installing the latest snapshot but wound up
> > recompiling a bunch of stuff (which my box is not configured for)... Is
> there
> > an easy way to download and install the latest snapshot?
>
>
> ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/alsa-driver-snapshot.tar.gz
>
> > Is there a way to fix the 0x0d widget? BIOS flash? laptop seems kind of
> new
> > for that...
>
> Try the hda-verb command first to check whether it's really an issue
> of 0x0d.
>
>
> Takashi
>
> >
> > On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> >
> > At Mon, 2 Feb 2009 10:17:03 -0500,
> > Tim Barnette wrote:
> > >
> > > Thanks, Takashi. I made this change and rebooted.
> > >
> > > I noticed right away the mute light is no longer on... but still no
> > sound
> > > through speakers, only headphones..
> > >
> > > /sys/module/snd_hda_intel/parameters/model
> > > contains
> > > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> > >
> > > attached is the alsa-info.txt you requested..
> >
> > Did you try the latest alsa-driver snapshot?
> >
> > If it still doesn't work, I guess this is a BIOS problem.
> > The other HP dv laptops show the widget 0x0d as the speaker while
> > yours is unused.
> >
> > Try to run:
> > hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
> >
> > Takashi
> >
> >
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 17:01 ` Tim Barnette
@ 2009-02-02 17:10 ` Takashi Iwai
0 siblings, 0 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-02 17:10 UTC (permalink / raw)
To: Tim Barnette; +Cc: alsa-devel, Jean-Pierre André
At Mon, 2 Feb 2009 12:01:08 -0500,
Tim Barnette wrote:
>
> [1 <text/plain; ISO-8859-1 (7bit)>]
>
> [2 <text/html; ISO-8859-1 (quoted-printable)>]
> Thanks, a few more questions.. sorry I don't understand most of this..
> 1) hda-verb - I can't find this.. what is it? Where do I run it?
See Documentation/sound/alsa/HD-Audio.txt in the recent linux tree, or
ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/docs/HD-Audio.pdf
> 2) Inside of the snapshot, there are three steps (6, 7,8 below) that I need
> help with..
The installation step for the snapshot tarball is identical with the
released version. If you installed already alsa-driver tarball, do it
just in the same way.
If you haven't done it yet, just do the following four steps:
% ./configure --with-debug=full --enable-dynamic-minors
% make
% su
# make install-modules
Takashi
> 6 - i already have /dev/snd with some stuff in it... so, I won't run this
> step..
> 7 - edit it to do what?
> 8 - I dont know the name of my card..
>
> 6) Run the './snddevices' script to create new sound devices in /dev
> directory.
> Skip this step, if you have already /dev/snd/* files, or if you're
> using a DEVFS or udev.
>
> 7) Edit your kernel module config (either /etc/modprobe.conf or
> /etc/modules.conf, depending on the kernel version). If you are not
> sure, what to do, you may try the alsaconf script available in
> the alsa-utils package.
>
> 8) Run 'modprobe snd-xxxx' where xxxx is the name of your card.
> Note: All ALSA ISA drivers support ISA PnP natively, so you don't need
> isapnptools any more. Don't use both together. It will
> conflict. For disabling the ALSA ISA PnP support, specify
> --with-isapnp=no configure switch.
>
> On Mon, Feb 2, 2009 at 11:28 AM, Takashi Iwai <tiwai@suse.de> wrote:
>
> At Mon, 2 Feb 2009 11:26:25 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I tried installing the latest snapshot but wound up
> > recompiling a bunch of stuff (which my box is not configured for)... Is
> there
> > an easy way to download and install the latest snapshot?
>
> ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/
> alsa-driver-snapshot.tar.gz
>
> > Is there a way to fix the 0x0d widget? BIOS flash? laptop seems kind
> of new
> > for that...
>
> Try the hda-verb command first to check whether it's really an issue
> of 0x0d.
>
> Takashi
>
> >
> > On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> >
> > At Mon, 2 Feb 2009 10:17:03 -0500,
> > Tim Barnette wrote:
> > >
> > > Thanks, Takashi. I made this change and rebooted.
> > >
> > > I noticed right away the mute light is no longer on... but still
> no
> > sound
> > > through speakers, only headphones..
> > >
> > > /sys/module/snd_hda_intel/parameters/model
> > > contains
> > > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> > >
> > > attached is the alsa-info.txt you requested..
> >
> > Did you try the latest alsa-driver snapshot?
> >
> > If it still doesn't work, I guess this is a BIOS problem.
> > The other HP dv laptops show the widget 0x0d as the speaker while
> > yours is unused.
> >
> > Try to run:
> > hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
> >
> > Takashi
> >
> >
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-01-31 7:52 ` [Fwd: HP DV4 1155 SE - No Sound through speakers...] Jean-Pierre André
2009-01-31 9:20 ` Takashi Iwai
2009-02-01 22:34 ` Tim Barnette
@ 2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2009-02-02 18:52 ` Takashi Iwai
` (2 more replies)
2 siblings, 3 replies; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-02 18:20 UTC (permalink / raw)
To: alsa-devel; +Cc: Jean-Pierre André
[-- Attachment #1: Type: text/plain, Size: 3843 bytes --]
Em Sábado 31 Janeiro 2009, às 05:52:19, Jean-Pierre André escreveu:
>
> Hi,
>
> > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > through the speakers, although it does work through the headhpones. I ran
> > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> > luck.
> >
>
> I have the same IDT codec 92HD71B7X on another
> HP DV4 model, and I have tracked the problem to be
> the kernel configuring IRQ 22 through the APIC, but
> interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> alsa 1.0.19). It would be interesting if you could
> confirm this by analyzing /proc/interrupts.
>
> The workarounds I know of are :
> - adding irqpoll to the boot options,
> - or adding noapic to the boot options,
> - using mplayer to play music.
>
> There are with option "snd-hda-intel model=hp-m4"
> (this option is for HP DV5/DV7, but HP DV4
> is probably different)
>
> I have not enough knowledge to tell where the problem
> lies : kernel, apic, alsa.
It looks like some of these HP laptops have some sort of IRQ issue indeed, to
me it was reported that enabling pci MSI (both system wide and with
enable_msi=1 given to snd-hda-intel) cured issues in some cases, along with
some changes to sigmatel codec handling code in snd-hda-intel
I have a ticked opened where people started to complain about sound issues
with hda-intel+sigmatel codec starting with alsa 1.0.18rc3 (sorry, it's a
great mess, type of the ticket everyone says sound doesn't work and report in,
but where I tried to filter some things out):
https://qa.mandriva.com/show_bug.cgi?id=44855
Also some reports are hard to understand sometimes.
With alsa 1.0.18 final in 2.6.27 (or 2.6.28) many issues related on the ticket
were fixed, but issues with HP laptops remained.
I don't have any of affected HP laptops for test, but based on sigmatel
datasheets, reports of users and pin cfgs used in .ini files of sigmatel
windows drivers I made some changes to sigmatel code, plus added patch to set
enable_msi. The only issue I have with the changes, and that's why I didn't
submit yet, is that I should have split them, don't know if everything is
really required, and ask here to clarify some things below; also the changes
are outdated compared to current sound git tree.
I'm attaching here the changes, they were made against kernel 2.6.28.2
- One patch deals with the sigmatel codec code, some things to note (others
are cited on the patch):
* despite being almost the same, only with some models missing widgets/pins, I
splitted support from patch_stac92hd71bxx for idt 92HD71B5X (4 port),
92HD75B1/2 (5 port). Mostly because of different number of pins between them,
may be could have still hacked more stac92xx_set_config_regs to avoid this.
* Many people complained about the Analog Loopback, causing problems when it's
enabled; I really don't know what exactly this is supposed to do (is it just a
mute of outputs or something like is described here?:
http://people.atrpms.net/~pcavalcanti/alsa-1.0.15rc2_snd-hda-intel.html) and
all sigmatel datasheets I look don't mention it, in the patch I removed it.
* power management on pins (stac92hd71bxx_pwr_nids) are not listed on sigmatel
datasheets I dowloaded from idt site (for STAC92HD71Bx and STAC92HD75Bx), so I
removed its setting (or I'm missing something here...).
- The other patch adds a quirk list to force enable_msi=1. PCI_MSI must be
enabled to give results.
>
> Regards
>
> Jean-Pierre
>
>
> > I ran alsa-info, output here:
> > http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> >
> > I filed a bug, here:
> > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> >
> > Any ideas?
> >
--
[]'s
Herton
[-- Attachment #2: sound-alsa-hda-enhance_fix_stac92hd71bx_stac92hd75bx.patch --]
[-- Type: text/x-patch, Size: 28997 bytes --]
Enhance/fix some aspects related to STAC92HD71Bx and STAC92HD75Bx support:
* Split STAC92HD71B* support from one model to three models (4 port, 5 port,
6 port), because of different number of default pins. May be trying to change
stac92xx_set_config_regs to check for pin_nids set to 0 for example would be
better (and requiring to check anything else that uses pin_nids array),
instead of splitting models just because of different number of pins
supported.
* Add additional init verbs for all STAC92HD71Bx and STAC92HD75Bx models to
ensure widgets are properly connected and configured, and also remove invalid
reference to 0xf pin for model without analog mixer (don't have the pin).
* Removed analog loopback mixer items, not mentioned in sigmatel datasheets and
reported to break sound support.
* Add support to stac92xx_set_config_regs to skip write to pin cfg if pin cfg
array item is zero.
* Add new stac92hd71bxx hp-m* models, with pci quirks for known machines, pin
cfgs sources comes from *.ini files from sigmatel windows drivers provided by
HP.
* Detect dynamically looking at pin configs the number of connected ports and
number of smuxes using new introduced functions stac92hd71bxx_connected_ports
and stac92hd71bxx_connected_smuxes.
* Use proper input mux configuration for 4port and 5port models.
* Set eapd_mask and eapd_switch, looks to be required.
* Remove pwr_nids/num_pwrs>0 etc. setting for all STAC92HD71Bx and STAC92HD75Bx
models, datasheets shows no power management support on any pins. Also
stac92xx_parse_auto_config was using uneeded/wrong third parameter = 0x23.
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
Documentation/sound/alsa/ALSA-Configuration.txt | 14
sound/pci/hda/patch_sigmatel.c | 620 +++++++++++++++++++-----
2 files changed, 516 insertions(+), 118 deletions(-)
diff -p -up linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt.orig linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt
--- linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt.orig 2009-01-28 07:38:38.000000000 -0500
+++ linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt 2009-01-28 07:40:30.000000000 -0500
@@ -1070,11 +1070,23 @@ Prior to version 0.9.0rc4 options had a
dell-3stack Dell Dimension E520
dell-bios Fixes with Dell BIOS setup
- STAC92HD71B*
+ STAC92HD71B5 (4 port)
+ ref Reference board
+
+ STAC92HD75B[12] (5 port)
+ ref Reference board
+ hp-m4 HP laptops
+
+ STAC92HD71B[678]/STAC92HD75B[34] (6 port)
ref Reference board
dell-m4-1 Dell desktops
dell-m4-2 Dell desktops
dell-m4-3 Dell desktops
+ hp-m4-1 HP laptops
+ hp-m4-2 HP laptops
+ hp-m4-3 HP laptops
+ hp-m4-4 HP laptops
+ hp-m4-5 HP laptops
STAC92HD73*
ref Reference board
diff -p -up linux-2.6.28/sound/pci/hda/patch_sigmatel.c.orig linux-2.6.28/sound/pci/hda/patch_sigmatel.c
--- linux-2.6.28/sound/pci/hda/patch_sigmatel.c.orig 2009-01-28 07:39:54.000000000 -0500
+++ linux-2.6.28/sound/pci/hda/patch_sigmatel.c 2009-01-28 07:40:30.000000000 -0500
@@ -84,12 +84,26 @@ enum {
};
enum {
+ STAC_92HD71B5_REF,
+ STAC_92HD71B5_MODELS
+};
+
+enum {
+ STAC_92HD75B_5PORT_REF,
+ STAC_HP_M4,
+ STAC_92HD75B_5PORT_MODELS
+};
+
+enum {
STAC_92HD71BXX_REF,
STAC_DELL_M4_1,
STAC_DELL_M4_2,
STAC_DELL_M4_3,
- STAC_HP_M4,
- STAC_HP_DV5,
+ STAC_HP_M4_1,
+ STAC_HP_M4_2,
+ STAC_HP_M4_3,
+ STAC_HP_M4_4,
+ STAC_HP_M4_5,
STAC_92HD71BXX_MODELS
};
@@ -320,10 +334,6 @@ static unsigned int stac92hd83xxx_pwr_ma
0x03, 0x0c, 0x10, 0x40,
};
-static hda_nid_t stac92hd71bxx_pwr_nids[3] = {
- 0x0a, 0x0d, 0x0f
-};
-
static hda_nid_t stac92hd71bxx_adc_nids[2] = {
0x12, 0x13,
};
@@ -344,6 +354,11 @@ static hda_nid_t stac92hd71bxx_dac_nids[
0x10, /*0x11, */
};
+#define STAC92HD75B_5PORT_NUM_DMICS 1
+static hda_nid_t stac92hd75b_5port_dmic_nids[STAC92HD75B_5PORT_NUM_DMICS + 1] = {
+ 0x18, 0
+};
+
#define STAC92HD71BXX_NUM_DMICS 2
static hda_nid_t stac92hd71bxx_dmic_nids[STAC92HD71BXX_NUM_DMICS + 1] = {
0x18, 0x19, 0
@@ -459,10 +474,22 @@ static hda_nid_t stac92hd83xxx_pin_nids[
0x0f, 0x10, 0x11, 0x12, 0x13,
0x1d, 0x1e, 0x1f, 0x20
};
-static hda_nid_t stac92hd71bxx_pin_nids[11] = {
+
+static hda_nid_t stac92hd71b5_pin_nids[11] = {
+ 0x0a, 0x0b, 0x0c, 0x0d, 0x14,
+ 0x18, 0x19, 0x1e, 0x1f, 0x20,
+ 0x27
+};
+
+static hda_nid_t stac92hd75b_5port_pin_nids[10] = {
+ 0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
+ 0x14, 0x18, 0x1e, 0x1f, 0x20
+};
+
+static hda_nid_t stac92hd71bxx_pin_nids[13] = {
0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
0x0f, 0x14, 0x18, 0x19, 0x1e,
- 0x1f,
+ 0x1f, 0x20, 0x27
};
static hda_nid_t stac927x_pin_nids[14] = {
@@ -868,10 +895,15 @@ static struct hda_verb stac92hd71bxx_cor
{ 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
/* connect headphone jack to dac1 */
{ 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
- /* unmute right and left channels for nodes 0x0a, 0xd, 0x0f */
+ /* connect port D/mono out to dac0 */
+ { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* make sure dmuxes are initially connected to analog muxes */
+ { 0x1c, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x1d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* unmute right and left channels for nodes 0x0a, 0xd */
{ 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{ 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
- { 0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{}
};
@@ -889,6 +921,12 @@ static struct hda_verb stac92hd71bxx_ana
{ 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
/* connect headphone jack to dac1 */
{ 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
+ /* connect port D/mono out to dac0 */
+ { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* unmute and max step for dac0/dac1 inputs in mixer */
+ { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x701f},
+ { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x711f},
/* unmute right and left channels for nodes 0x0a, 0xd */
{ 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{ 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
@@ -1109,7 +1147,6 @@ static struct snd_kcontrol_new stac92hd8
static struct snd_kcontrol_new stac92hd71bxx_analog_mixer[] = {
STAC_INPUT_SOURCE(2),
- STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
@@ -1138,7 +1175,6 @@ static struct snd_kcontrol_new stac92hd7
static struct snd_kcontrol_new stac92hd71bxx_mixer[] = {
STAC_INPUT_SOURCE(2),
- STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
@@ -1673,28 +1709,107 @@ static struct snd_pci_quirk stac92hd83xx
{} /* terminator */
};
-static unsigned int ref92hd71bxx_pin_configs[11] = {
+static unsigned int ref92hd71b5_pin_configs[] = {
+ 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
+ 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
+ 0x98560060, 0x40f000f0, 0x40f000f0,
+};
+
+static unsigned int *stac92hd71b5_brd_tbl[STAC_92HD71B5_MODELS] = {
+ [STAC_92HD71B5_REF] = ref92hd71b5_pin_configs,
+};
+
+static const char *stac92hd71b5_models[STAC_92HD71B5_MODELS] = {
+ [STAC_92HD71B5_REF] = "ref",
+};
+
+static struct snd_pci_quirk stac92hd71b5_cfg_tbl[] = {
+ {} /* terminator */
+};
+
+static unsigned int ref92hd75b_5port_pin_configs[] = {
+ 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
+ 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
+ 0x98560060, 0x40f000f0,
+};
+
+static unsigned int *stac92hd75b_5port_brd_tbl[STAC_92HD75B_5PORT_MODELS] = {
+ [STAC_92HD75B_5PORT_REF] = ref92hd75b_5port_pin_configs,
+ [STAC_HP_M4] = NULL,
+};
+
+static const char *stac92hd75b_5port_models[STAC_92HD75B_5PORT_MODELS] = {
+ [STAC_92HD75B_5PORT_REF] = "ref",
+ [STAC_HP_M4] = "hp-m4",
+};
+
+static struct snd_pci_quirk stac92hd75b_5port_cfg_tbl[] = {
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
+ "unknown HP", STAC_HP_M4),
+ {} /* terminator */
+};
+
+static unsigned int ref92hd71bxx_pin_configs[13] = {
0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
0x0181302e, 0x01014010, 0x01019020, 0x90a000f0,
- 0x90a000f0, 0x01452050, 0x01452050,
+ 0x90a000f0, 0x01452050, 0x01452050, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_1_pin_configs[11] = {
+static unsigned int dell_m4_1_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x40f000f0, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x4f0000f0, 0x4f0000f0,
+ 0x40f000f0, 0x4f0000f0, 0x4f0000f0, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_2_pin_configs[11] = {
+static unsigned int dell_m4_2_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x40f000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_3_pin_configs[11] = {
+static unsigned int dell_m4_3_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x40f000f0, 0x40f000f0, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000,
+};
+
+static unsigned int hp_m4_1_pin_configs[13] = {
+ 0x0221201f, 0x02a12050, 0x40f000f0, 0x90170010,
+ 0x40f000f1, 0x0221201f, 0x40f000f2, 0x90a60040,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x00000000,
+ 0x90300041,
+};
+
+static unsigned int hp_m4_2_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x50f000f4, 0x50f000f5, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_3_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x40f000f0,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_4_pin_configs[13] = {
+ 0x0221201f, 0x02a12050, 0x90a70040, 0x90170010,
+ 0x40f000f1, 0x40f000f5, 0x40f000f2, 0x50f000f6,
+ 0x50f000f3, 0x50f000f7, 0x50f000f4, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_5_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x90a70070, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x50f000f1,
+ 0x50f000f3, 0x50f000f6, 0x50f000f4, 0x28466060,
+ 0x9030005a,
};
static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
@@ -1702,8 +1817,11 @@ static unsigned int *stac92hd71bxx_brd_t
[STAC_DELL_M4_1] = dell_m4_1_pin_configs,
[STAC_DELL_M4_2] = dell_m4_2_pin_configs,
[STAC_DELL_M4_3] = dell_m4_3_pin_configs,
- [STAC_HP_M4] = NULL,
- [STAC_HP_DV5] = NULL,
+ [STAC_HP_M4_1] = hp_m4_1_pin_configs,
+ [STAC_HP_M4_2] = hp_m4_2_pin_configs,
+ [STAC_HP_M4_3] = hp_m4_3_pin_configs,
+ [STAC_HP_M4_4] = hp_m4_4_pin_configs,
+ [STAC_HP_M4_5] = hp_m4_5_pin_configs,
};
static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
@@ -1711,24 +1829,59 @@ static const char *stac92hd71bxx_models[
[STAC_DELL_M4_1] = "dell-m4-1",
[STAC_DELL_M4_2] = "dell-m4-2",
[STAC_DELL_M4_3] = "dell-m4-3",
- [STAC_HP_M4] = "hp-m4",
- [STAC_HP_DV5] = "hp-dv5",
+ [STAC_HP_M4_1] = "hp-m4-1",
+ [STAC_HP_M4_2] = "hp-m4-2",
+ [STAC_HP_M4_3] = "hp-m4-3",
+ [STAC_HP_M4_4] = "hp-m4-4",
+ [STAC_HP_M4_5] = "hp-m4-5",
};
static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
/* SigmaTel reference board */
SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668,
"DFI LanParty", STAC_92HD71BXX_REF),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
- "HP dv5", STAC_HP_M4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30de,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(0x30de, 0x103c,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x1505,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(0x1505, 0x103c,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f3,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
- "HP dv7", STAC_HP_M4),
+ "HP dv7", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
- "HP dv7", STAC_HP_M4),
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd,
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
+ "HP dv5", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3602,
+ "unknown HP", STAC_HP_M4_3),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
- "HP dv5", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
- "unknown HP", STAC_HP_M4),
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x360f,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3610,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30ff,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3601,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3607,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f8,
+ "unknown HP", STAC_HP_M4_5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fe,
+ "unknown HP", STAC_HP_M4_5),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
"unknown Dell", STAC_DELL_M4_1),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0234,
@@ -2262,9 +2415,11 @@ static void stac92xx_set_config_regs(str
if (!spec->pin_configs)
return;
- for (i = 0; i < spec->num_pins; i++)
- stac92xx_set_config_reg(codec, spec->pin_nids[i],
- spec->pin_configs[i]);
+ for (i = 0; i < spec->num_pins; i++) {
+ if (spec->pin_configs[i])
+ stac92xx_set_config_reg(codec, spec->pin_nids[i],
+ spec->pin_configs[i]);
+ }
}
/*
@@ -4527,6 +4682,282 @@ static struct hda_codec_ops stac92hd71bx
#endif
};
+static int stac92hd71bxx_connected_ports(struct hda_codec *codec,
+ hda_nid_t *nids, int num_nids)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx, num;
+ unsigned int def_conf;
+
+ for (num = 0; num < num_nids; num++) {
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == nids[num])
+ break;
+ if (idx >= spec->num_pins)
+ break;
+ def_conf = get_defcfg_connect(spec->pin_configs[idx]);
+ if (def_conf == AC_JACK_PORT_NONE)
+ break;
+ }
+ return num;
+}
+
+static int stac92hd71bxx_connected_smuxes(struct hda_codec *codec,
+ hda_nid_t dig0pin)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx;
+
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == dig0pin)
+ break;
+ if ((idx + 2) >= spec->num_pins)
+ return 0;
+
+ /* dig1pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+1]) != AC_JACK_PORT_NONE)
+ return 2;
+
+ /* dig0pin + dig2pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+2]) != AC_JACK_PORT_NONE)
+ return 2;
+ if (get_defcfg_connect(spec->pin_configs[idx]) != AC_JACK_PORT_NONE)
+ return 1;
+ else
+ return 0;
+}
+
+static struct hda_input_mux stac92hd71b5_dmux = {
+ .num_items = 3,
+ .items = {
+ { "Analog Inputs", 0x00 },
+ { "Digital Mic 1", 0x02 },
+ { "Digital Mic 2", 0x03 },
+ }
+};
+
+static int patch_stac92hd71b5(struct hda_codec *codec)
+{
+ struct sigmatel_spec *spec;
+ int err = 0;
+
+ spec = kzalloc(sizeof(*spec), GFP_KERNEL);
+ if (spec == NULL)
+ return -ENOMEM;
+
+ codec->spec = spec;
+ codec->patch_ops = stac92xx_patch_ops;
+ spec->num_pins = ARRAY_SIZE(stac92hd71b5_pin_nids);
+ spec->pin_nids = stac92hd71b5_pin_nids;
+
+ memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
+ sizeof(stac92hd71b5_dmux));
+ spec->board_config = snd_hda_check_board_config(codec,
+ STAC_92HD71B5_MODELS,
+ stac92hd71b5_models,
+ stac92hd71b5_cfg_tbl);
+again:
+ if (spec->board_config < 0) {
+ snd_printdd(KERN_INFO "hda_codec: Unknown model for"
+ " STAC92HD71B5, using BIOS defaults\n");
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else {
+ spec->pin_configs = stac92hd71b5_brd_tbl[spec->board_config];
+ stac92xx_set_config_regs(codec);
+ }
+
+ if (spec->board_config > STAC_92HD71B5_REF) {
+ /* GPIO0 = EAPD */
+ spec->gpio_mask = 0x01;
+ spec->gpio_dir = 0x01;
+ spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
+ }
+
+ spec->mixer = stac92hd71bxx_mixer;
+ spec->init = stac92hd71bxx_core_init;
+ codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+
+ spec->num_pwrs = 0;
+ spec->powerdown_adcs = 1;
+ spec->digbeep_nid = 0x26;
+
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd71bxx_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ if (spec->num_dmics) {
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->dinput_mux = &spec->private_dimux;
+ spec->private_dimux.num_items += spec->num_dmics -
+ (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
+ }
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
+ spec->multiout.num_dacs = 1;
+ spec->multiout.hp_nid = 0x11;
+ spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
+
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
+ if (!err) {
+ if (spec->board_config < 0) {
+ printk(KERN_WARNING "hda_codec: No auto-config is "
+ "available, default to model=ref\n");
+ spec->board_config = STAC_92HD71B5_REF;
+ goto again;
+ }
+ err = -EINVAL;
+ }
+
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+
+ return 0;
+}
+
+static struct hda_input_mux stac92hd75b_5port_dmux = {
+ .num_items = 3,
+ .items = {
+ { "Analog Inputs", 0x00 },
+ { "Mixer", 0x01 },
+ { "Digital Mic 1", 0x02 },
+ }
+};
+
+static int patch_stac92hd75b_5port(struct hda_codec *codec)
+{
+ struct sigmatel_spec *spec;
+ int err = 0;
+
+ spec = kzalloc(sizeof(*spec), GFP_KERNEL);
+ if (spec == NULL)
+ return -ENOMEM;
+
+ codec->spec = spec;
+ codec->patch_ops = stac92xx_patch_ops;
+ spec->num_pins = ARRAY_SIZE(stac92hd75b_5port_pin_nids);
+ spec->pin_nids = stac92hd75b_5port_pin_nids;
+
+ memcpy(&spec->private_dimux, &stac92hd75b_5port_dmux,
+ sizeof(stac92hd75b_5port_dmux));
+ spec->board_config = snd_hda_check_board_config(codec,
+ STAC_92HD75B_5PORT_MODELS,
+ stac92hd75b_5port_models,
+ stac92hd75b_5port_cfg_tbl);
+again:
+ if (spec->board_config < 0) {
+ snd_printdd(KERN_INFO "hda_codec: Unknown model for"
+ " STAC92HD75B_5PORT, using BIOS defaults\n");
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else {
+ spec->pin_configs = stac92hd75b_5port_brd_tbl[spec->board_config];
+ if (!spec->pin_configs) {
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else
+ stac92xx_set_config_regs(codec);
+ }
+
+ if (spec->board_config > STAC_92HD75B_5PORT_REF) {
+ /* GPIO0 = EAPD */
+ spec->gpio_mask = 0x01;
+ spec->gpio_dir = 0x01;
+ spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
+ }
+
+ if (spec->board_config == STAC_HP_M4) {
+ /* Enable VREF power saving on GPIO1 detect */
+ snd_hda_codec_write_cache(codec, codec->afg, 0,
+ AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
+ snd_hda_codec_write_cache(codec, codec->afg, 0,
+ AC_VERB_SET_UNSOLICITED_ENABLE,
+ (AC_USRSP_EN | STAC_VREF_EVENT | 0x01));
+ spec->gpio_mask |= 0x02;
+ stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
+ stac92xx_auto_set_pinctl(codec, 0x0e,
+ AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
+ spec->pin_configs[4] = 0x01813040;
+ }
+ if ((codec->revision_id & 0xf) == 0 ||
+ (codec->revision_id & 0xf) == 1) {
+#ifdef SND_HDA_NEEDS_RESUME
+ codec->patch_ops = stac92hd71bxx_patch_ops;
+#endif
+ spec->stream_delay = 40; /* 40 milliseconds */
+ }
+
+ spec->mixer = stac92hd71bxx_analog_mixer;
+ spec->dinput_mux = &spec->private_dimux;
+ spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
+ codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+
+ spec->num_pwrs = 0;
+ spec->powerdown_adcs = 1;
+ spec->digbeep_nid = 0x26;
+
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd75b_5port_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd75b_5port_dmic_nids,
+ STAC92HD75B_5PORT_NUM_DMICS);
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
+ spec->multiout.num_dacs = 1;
+ spec->multiout.hp_nid = 0x11;
+ spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
+ spec->private_dimux.num_items += spec->num_dmics -
+ (ARRAY_SIZE(stac92hd75b_5port_dmic_nids) - 1);
+
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
+ if (!err) {
+ if (spec->board_config < 0) {
+ printk(KERN_WARNING "hda_codec: No auto-config is "
+ "available, default to model=ref\n");
+ spec->board_config = STAC_92HD75B_5PORT_REF;
+ goto again;
+ }
+ err = -EINVAL;
+ }
+
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+
+ return 0;
+}
+
static struct hda_input_mux stac92hd71bxx_dmux = {
.num_items = 4,
.items = {
@@ -4549,10 +4980,12 @@ static int patch_stac92hd71bxx(struct hd
codec->spec = spec;
codec->patch_ops = stac92xx_patch_ops;
spec->num_pins = ARRAY_SIZE(stac92hd71bxx_pin_nids);
- spec->num_pwrs = ARRAY_SIZE(stac92hd71bxx_pwr_nids);
spec->pin_nids = stac92hd71bxx_pin_nids;
- memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
- sizeof(stac92hd71bxx_dmux));
+
+ /* On 92HD75B3/92HD75B4 0x27 isn't a pin nid */
+ if (codec->vendor_id == 0x111d7603)
+ spec->num_pins--;
+
spec->board_config = snd_hda_check_board_config(codec,
STAC_92HD71BXX_MODELS,
stac92hd71bxx_models,
@@ -4577,46 +5010,35 @@ again:
spec->gpio_mask = 0x01;
spec->gpio_dir = 0x01;
spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
}
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd71bxx_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
switch (codec->vendor_id) {
- case 0x111d76b6: /* 4 Port without Analog Mixer */
- case 0x111d76b7:
case 0x111d76b4: /* 6 Port without Analog Mixer */
case 0x111d76b5:
+ memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
+ sizeof(stac92hd71b5_dmux));
+ if (spec->num_dmics) {
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->dinput_mux = &spec->private_dimux;
+ }
spec->mixer = stac92hd71bxx_mixer;
spec->init = stac92hd71bxx_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
break;
- case 0x111d7608: /* 5 Port with Analog Mixer */
- switch (spec->board_config) {
- case STAC_HP_M4:
- /* Enable VREF power saving on GPIO1 detect */
- snd_hda_codec_write_cache(codec, codec->afg, 0,
- AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
- snd_hda_codec_write_cache(codec, codec->afg, 0,
- AC_VERB_SET_UNSOLICITED_ENABLE,
- (AC_USRSP_EN | STAC_VREF_EVENT | 0x01));
- spec->gpio_mask |= 0x02;
- break;
- }
- if ((codec->revision_id & 0xf) == 0 ||
- (codec->revision_id & 0xf) == 1) {
-#ifdef SND_HDA_NEEDS_RESUME
- codec->patch_ops = stac92hd71bxx_patch_ops;
-#endif
- spec->stream_delay = 40; /* 40 milliseconds */
- }
-
- /* no output amps */
- spec->num_pwrs = 0;
- spec->mixer = stac92hd71bxx_analog_mixer;
- spec->dinput_mux = &spec->private_dimux;
-
- /* disable VSW */
- spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
- stac92xx_set_config_reg(codec, 0xf, 0x40f000f0);
- break;
case 0x111d7603: /* 6 Port with Analog Mixer */
if ((codec->revision_id & 0xf) == 1) {
#ifdef SND_HDA_NEEDS_RESUME
@@ -4624,65 +5046,29 @@ again:
#endif
spec->stream_delay = 40; /* 40 milliseconds */
}
-
- /* no output amps */
- spec->num_pwrs = 0;
/* fallthru */
default:
+ memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
+ sizeof(stac92hd71bxx_dmux));
spec->dinput_mux = &spec->private_dimux;
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
spec->mixer = stac92hd71bxx_analog_mixer;
spec->init = stac92hd71bxx_analog_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
}
- spec->aloopback_mask = 0x50;
- spec->aloopback_shift = 0;
-
+ spec->num_pwrs = 0;
spec->powerdown_adcs = 1;
spec->digbeep_nid = 0x26;
- spec->mux_nids = stac92hd71bxx_mux_nids;
- spec->adc_nids = stac92hd71bxx_adc_nids;
- spec->dmic_nids = stac92hd71bxx_dmic_nids;
- spec->dmux_nids = stac92hd71bxx_dmux_nids;
- spec->smux_nids = stac92hd71bxx_smux_nids;
- spec->pwr_nids = stac92hd71bxx_pwr_nids;
-
- spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
- spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
-
- switch (spec->board_config) {
- case STAC_HP_M4:
- /* enable internal microphone */
- stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
- stac92xx_auto_set_pinctl(codec, 0x0e,
- AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
- /* fallthru */
- case STAC_DELL_M4_2:
- spec->num_dmics = 0;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- case STAC_DELL_M4_1:
- case STAC_DELL_M4_3:
- spec->num_dmics = 1;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- default:
- spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
- spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
- spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
- };
spec->multiout.num_dacs = 1;
spec->multiout.hp_nid = 0x11;
spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
- if (spec->dinput_mux)
- spec->private_dimux.num_items +=
+ spec->private_dimux.num_items +=
spec->num_dmics -
(ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
- err = stac92xx_parse_auto_config(codec, 0x21, 0x23);
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
if (!err) {
if (spec->board_config < 0) {
printk(KERN_WARNING "hda_codec: No auto-config is "
@@ -4699,7 +5085,7 @@ again:
}
return 0;
-};
+}
static int patch_stac922x(struct hda_codec *codec)
{
@@ -5335,10 +5721,10 @@ struct hda_codec_preset snd_hda_preset_s
{ .id = 0x838476a5, .name = "STAC9255D", .patch = patch_stac9205 },
{ .id = 0x838476a6, .name = "STAC9254", .patch = patch_stac9205 },
{ .id = 0x838476a7, .name = "STAC9254D", .patch = patch_stac9205 },
- { .id = 0x111d7603, .name = "92HD75B3X5", .patch = patch_stac92hd71bxx},
- { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx},
- { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx},
- { .id = 0x111d7608, .name = "92HD75B2X5", .patch = patch_stac92hd71bxx},
+ { .id = 0x111d7603, .name = "92HD75B3/4", .patch = patch_stac92hd71bxx },
+ { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx },
+ { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx },
+ { .id = 0x111d7608, .name = "92HD75B1/2", .patch = patch_stac92hd75b_5port },
{ .id = 0x111d7674, .name = "92HD73D1X5", .patch = patch_stac92hd73xx },
{ .id = 0x111d7675, .name = "92HD73C1X5", .patch = patch_stac92hd73xx },
{ .id = 0x111d7676, .name = "92HD73E1X5", .patch = patch_stac92hd73xx },
@@ -5348,7 +5734,7 @@ struct hda_codec_preset snd_hda_preset_s
{ .id = 0x111d76b3, .name = "92HD71B7X", .patch = patch_stac92hd71bxx },
{ .id = 0x111d76b4, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
{ .id = 0x111d76b5, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
- { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
- { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
+ { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
+ { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
{} /* terminator */
};
[-- Attachment #3: sound-alsa-hda-add-msi-quirk-list.patch --]
[-- Type: text/x-patch, Size: 1785 bytes --]
ALSA: hda - Add MSI quirk list
It is reported that models of HP dv7 laptops needs MSI to function
properly. This adds a MSI quirk list support to snd-hda-intel to
preset enable_msi option for machines that needs MSI disabled/enabled
and set required setting for HP dv7 laptops.
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
sound/pci/hda/hda_intel.c | 25 +++++++++++++++++++++++++
1 file changed, 25 insertions(+)
diff -p -up linux-2.6.27/sound/pci/hda/hda_intel.c.orig linux-2.6.27/sound/pci/hda/hda_intel.c
--- linux-2.6.27/sound/pci/hda/hda_intel.c.orig 2009-01-22 06:52:07.000000000 -0500
+++ linux-2.6.27/sound/pci/hda/hda_intel.c 2009-01-22 06:55:20.000000000 -0500
@@ -2050,6 +2050,30 @@ static int azx_dev_free(struct snd_devic
}
/*
+ * white/black-listing for enable_msi
+ */
+static struct snd_pci_quirk msi_list[] __devinitdata = {
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4, "HP dv7", 0x01),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc, "HP dv7", 0x01),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd, "HP dv7", 0x01),
+ {}
+};
+
+static void __devinit check_msi(struct azx *chip)
+{
+ const struct snd_pci_quirk *q;
+
+ q = snd_pci_quirk_lookup(chip->pci, msi_list);
+ if (q) {
+ printk(KERN_INFO
+ "hda_intel: enable_msi set to 0x%x "
+ "for device %04x:%04x\n",
+ q->value, q->subvendor, q->subdevice);
+ enable_msi = q->value;
+ }
+}
+
+/*
* white/black-listing for position_fix
*/
static struct snd_pci_quirk position_fix_list[] __devinitdata = {
@@ -2148,6 +2172,7 @@ static int __devinit azx_create(struct s
chip->pci = pci;
chip->irq = -1;
chip->driver_type = driver_type;
+ check_msi(chip);
chip->msi = enable_msi;
chip->dev_index = dev;
INIT_WORK(&chip->irq_pending_work, azx_irq_pending_work);
[-- Attachment #4: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
@ 2009-02-02 18:52 ` Takashi Iwai
2009-02-02 19:19 ` Tim Barnette
2009-02-03 13:49 ` Jean-Pierre André
2 siblings, 0 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-02 18:52 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski; +Cc: alsa-devel, Jean-Pierre André
At Mon, 2 Feb 2009 16:20:50 -0200,
Herton Ronaldo Krzesinski wrote:
>
> Em Sábado 31 Janeiro 2009, às 05:52:19, Jean-Pierre André escreveu:
> >
> > Hi,
> >
> > > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > > through the speakers, although it does work through the headhpones. I ran
> > > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
> > > luck.
> > >
> >
> > I have the same IDT codec 92HD71B7X on another
> > HP DV4 model, and I have tracked the problem to be
> > the kernel configuring IRQ 22 through the APIC, but
> > interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> > alsa 1.0.19). It would be interesting if you could
> > confirm this by analyzing /proc/interrupts.
> >
> > The workarounds I know of are :
> > - adding irqpoll to the boot options,
> > - or adding noapic to the boot options,
> > - using mplayer to play music.
> >
> > There are with option "snd-hda-intel model=hp-m4"
> > (this option is for HP DV5/DV7, but HP DV4
> > is probably different)
> >
> > I have not enough knowledge to tell where the problem
> > lies : kernel, apic, alsa.
>
> It looks like some of these HP laptops have some sort of IRQ issue indeed, to
> me it was reported that enabling pci MSI (both system wide and with
> enable_msi=1 given to snd-hda-intel) cured issues in some cases, along with
> some changes to sigmatel codec handling code in snd-hda-intel
>
> I have a ticked opened where people started to complain about sound issues
> with hda-intel+sigmatel codec starting with alsa 1.0.18rc3 (sorry, it's a
> great mess, type of the ticket everyone says sound doesn't work and report in,
> but where I tried to filter some things out):
> https://qa.mandriva.com/show_bug.cgi?id=44855
> Also some reports are hard to understand sometimes.
> With alsa 1.0.18 final in 2.6.27 (or 2.6.28) many issues related on the ticket
> were fixed, but issues with HP laptops remained.
>
> I don't have any of affected HP laptops for test, but based on sigmatel
> datasheets, reports of users and pin cfgs used in .ini files of sigmatel
> windows drivers I made some changes to sigmatel code, plus added patch to set
> enable_msi. The only issue I have with the changes, and that's why I didn't
> submit yet, is that I should have split them, don't know if everything is
> really required, and ask here to clarify some things below; also the changes
> are outdated compared to current sound git tree.
>
> I'm attaching here the changes, they were made against kernel 2.6.28.2
> - One patch deals with the sigmatel codec code, some things to note (others
> are cited on the patch):
> * despite being almost the same, only with some models missing widgets/pins, I
> splitted support from patch_stac92hd71bxx for idt 92HD71B5X (4 port),
> 92HD75B1/2 (5 port). Mostly because of different number of pins between them,
> may be could have still hacked more stac92xx_set_config_regs to avoid this.
That'll be OK if this makes the code more readable...
> * Many people complained about the Analog Loopback, causing problems when it's
> enabled; I really don't know what exactly this is supposed to do (is it just a
> mute of outputs or something like is described here?:
> http://people.atrpms.net/~pcavalcanti/alsa-1.0.15rc2_snd-hda-intel.html) and
> all sigmatel datasheets I look don't mention it, in the patch I removed it.
The "Analog Loopback" control is supposed to switch between the PCM
and analog input loopback. If it's on, you don't hear any sounds from
PCM. So, if you know that, you'll understand why it doesn't work.
Well, I personally don't find that control so useful (and it's not
intuitive), so I'm not against the removal, but would like to hear
opinions from others.
> * power management on pins (stac92hd71bxx_pwr_nids) are not listed on sigmatel
> datasheets I dowloaded from idt site (for STAC92HD71Bx and STAC92HD75Bx), so I
> removed its setting (or I'm missing something here...).
This seems like an undocumented feature, but a similar feature is
documented in other codecs, IIRC.
I feel this a nice feature (if it really works). So, I'd like to keep
this feature.
Anyway, yes, splitting these would be really helpful, so that we can
check which is broken / annoying to remove.
> - The other patch adds a quirk list to force enable_msi=1. PCI_MSI must be
> enabled to give results.
This is a bit to consider, but from the fact that MSI itself is a good
thing, a white-list would be OK.
thanks,
Takashi
> > Regards
> >
> > Jean-Pierre
> >
> >
> > > I ran alsa-info, output here:
> > > http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> > >
> > > I filed a bug, here:
> > > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> > >
> > > Any ideas?
> > >
>
> --
> []'s
> Herton
> [2 sound-alsa-hda-enhance_fix_stac92hd71bx_stac92hd75bx.patch <text/x-patch; UTF-8 (7bit)>]
> Enhance/fix some aspects related to STAC92HD71Bx and STAC92HD75Bx support:
> * Split STAC92HD71B* support from one model to three models (4 port, 5 port,
> 6 port), because of different number of default pins. May be trying to change
> stac92xx_set_config_regs to check for pin_nids set to 0 for example would be
> better (and requiring to check anything else that uses pin_nids array),
> instead of splitting models just because of different number of pins
> supported.
> * Add additional init verbs for all STAC92HD71Bx and STAC92HD75Bx models to
> ensure widgets are properly connected and configured, and also remove invalid
> reference to 0xf pin for model without analog mixer (don't have the pin).
> * Removed analog loopback mixer items, not mentioned in sigmatel datasheets and
> reported to break sound support.
> * Add support to stac92xx_set_config_regs to skip write to pin cfg if pin cfg
> array item is zero.
> * Add new stac92hd71bxx hp-m* models, with pci quirks for known machines, pin
> cfgs sources comes from *.ini files from sigmatel windows drivers provided by
> HP.
> * Detect dynamically looking at pin configs the number of connected ports and
> number of smuxes using new introduced functions stac92hd71bxx_connected_ports
> and stac92hd71bxx_connected_smuxes.
> * Use proper input mux configuration for 4port and 5port models.
> * Set eapd_mask and eapd_switch, looks to be required.
> * Remove pwr_nids/num_pwrs>0 etc. setting for all STAC92HD71Bx and STAC92HD75Bx
> models, datasheets shows no power management support on any pins. Also
> stac92xx_parse_auto_config was using uneeded/wrong third parameter = 0x23.
>
> Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
>
> ---
> Documentation/sound/alsa/ALSA-Configuration.txt | 14
> sound/pci/hda/patch_sigmatel.c | 620 +++++++++++++++++++-----
> 2 files changed, 516 insertions(+), 118 deletions(-)
>
> diff -p -up linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt.orig linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt
> --- linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt.orig 2009-01-28 07:38:38.000000000 -0500
> +++ linux-2.6.28/Documentation/sound/alsa/ALSA-Configuration.txt 2009-01-28 07:40:30.000000000 -0500
> @@ -1070,11 +1070,23 @@ Prior to version 0.9.0rc4 options had a
> dell-3stack Dell Dimension E520
> dell-bios Fixes with Dell BIOS setup
>
> - STAC92HD71B*
> + STAC92HD71B5 (4 port)
> + ref Reference board
> +
> + STAC92HD75B[12] (5 port)
> + ref Reference board
> + hp-m4 HP laptops
> +
> + STAC92HD71B[678]/STAC92HD75B[34] (6 port)
> ref Reference board
> dell-m4-1 Dell desktops
> dell-m4-2 Dell desktops
> dell-m4-3 Dell desktops
> + hp-m4-1 HP laptops
> + hp-m4-2 HP laptops
> + hp-m4-3 HP laptops
> + hp-m4-4 HP laptops
> + hp-m4-5 HP laptops
>
> STAC92HD73*
> ref Reference board
> diff -p -up linux-2.6.28/sound/pci/hda/patch_sigmatel.c.orig linux-2.6.28/sound/pci/hda/patch_sigmatel.c
> --- linux-2.6.28/sound/pci/hda/patch_sigmatel.c.orig 2009-01-28 07:39:54.000000000 -0500
> +++ linux-2.6.28/sound/pci/hda/patch_sigmatel.c 2009-01-28 07:40:30.000000000 -0500
> @@ -84,12 +84,26 @@ enum {
> };
>
> enum {
> + STAC_92HD71B5_REF,
> + STAC_92HD71B5_MODELS
> +};
> +
> +enum {
> + STAC_92HD75B_5PORT_REF,
> + STAC_HP_M4,
> + STAC_92HD75B_5PORT_MODELS
> +};
> +
> +enum {
> STAC_92HD71BXX_REF,
> STAC_DELL_M4_1,
> STAC_DELL_M4_2,
> STAC_DELL_M4_3,
> - STAC_HP_M4,
> - STAC_HP_DV5,
> + STAC_HP_M4_1,
> + STAC_HP_M4_2,
> + STAC_HP_M4_3,
> + STAC_HP_M4_4,
> + STAC_HP_M4_5,
> STAC_92HD71BXX_MODELS
> };
>
> @@ -320,10 +334,6 @@ static unsigned int stac92hd83xxx_pwr_ma
> 0x03, 0x0c, 0x10, 0x40,
> };
>
> -static hda_nid_t stac92hd71bxx_pwr_nids[3] = {
> - 0x0a, 0x0d, 0x0f
> -};
> -
> static hda_nid_t stac92hd71bxx_adc_nids[2] = {
> 0x12, 0x13,
> };
> @@ -344,6 +354,11 @@ static hda_nid_t stac92hd71bxx_dac_nids[
> 0x10, /*0x11, */
> };
>
> +#define STAC92HD75B_5PORT_NUM_DMICS 1
> +static hda_nid_t stac92hd75b_5port_dmic_nids[STAC92HD75B_5PORT_NUM_DMICS + 1] = {
> + 0x18, 0
> +};
> +
> #define STAC92HD71BXX_NUM_DMICS 2
> static hda_nid_t stac92hd71bxx_dmic_nids[STAC92HD71BXX_NUM_DMICS + 1] = {
> 0x18, 0x19, 0
> @@ -459,10 +474,22 @@ static hda_nid_t stac92hd83xxx_pin_nids[
> 0x0f, 0x10, 0x11, 0x12, 0x13,
> 0x1d, 0x1e, 0x1f, 0x20
> };
> -static hda_nid_t stac92hd71bxx_pin_nids[11] = {
> +
> +static hda_nid_t stac92hd71b5_pin_nids[11] = {
> + 0x0a, 0x0b, 0x0c, 0x0d, 0x14,
> + 0x18, 0x19, 0x1e, 0x1f, 0x20,
> + 0x27
> +};
> +
> +static hda_nid_t stac92hd75b_5port_pin_nids[10] = {
> + 0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
> + 0x14, 0x18, 0x1e, 0x1f, 0x20
> +};
> +
> +static hda_nid_t stac92hd71bxx_pin_nids[13] = {
> 0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
> 0x0f, 0x14, 0x18, 0x19, 0x1e,
> - 0x1f,
> + 0x1f, 0x20, 0x27
> };
>
> static hda_nid_t stac927x_pin_nids[14] = {
> @@ -868,10 +895,15 @@ static struct hda_verb stac92hd71bxx_cor
> { 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
> /* connect headphone jack to dac1 */
> { 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
> - /* unmute right and left channels for nodes 0x0a, 0xd, 0x0f */
> + /* connect port D/mono out to dac0 */
> + { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
> + { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
> + /* make sure dmuxes are initially connected to analog muxes */
> + { 0x1c, AC_VERB_SET_CONNECT_SEL, 0x00},
> + { 0x1d, AC_VERB_SET_CONNECT_SEL, 0x00},
> + /* unmute right and left channels for nodes 0x0a, 0xd */
> { 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
> { 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
> - { 0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
> {}
> };
>
> @@ -889,6 +921,12 @@ static struct hda_verb stac92hd71bxx_ana
> { 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
> /* connect headphone jack to dac1 */
> { 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
> + /* connect port D/mono out to dac0 */
> + { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
> + { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
> + /* unmute and max step for dac0/dac1 inputs in mixer */
> + { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x701f},
> + { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x711f},
> /* unmute right and left channels for nodes 0x0a, 0xd */
> { 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
> { 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
> @@ -1109,7 +1147,6 @@ static struct snd_kcontrol_new stac92hd8
>
> static struct snd_kcontrol_new stac92hd71bxx_analog_mixer[] = {
> STAC_INPUT_SOURCE(2),
> - STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
>
> HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
> HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
> @@ -1138,7 +1175,6 @@ static struct snd_kcontrol_new stac92hd7
>
> static struct snd_kcontrol_new stac92hd71bxx_mixer[] = {
> STAC_INPUT_SOURCE(2),
> - STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
>
> HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
> HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
> @@ -1673,28 +1709,107 @@ static struct snd_pci_quirk stac92hd83xx
> {} /* terminator */
> };
>
> -static unsigned int ref92hd71bxx_pin_configs[11] = {
> +static unsigned int ref92hd71b5_pin_configs[] = {
> + 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
> + 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
> + 0x98560060, 0x40f000f0, 0x40f000f0,
> +};
> +
> +static unsigned int *stac92hd71b5_brd_tbl[STAC_92HD71B5_MODELS] = {
> + [STAC_92HD71B5_REF] = ref92hd71b5_pin_configs,
> +};
> +
> +static const char *stac92hd71b5_models[STAC_92HD71B5_MODELS] = {
> + [STAC_92HD71B5_REF] = "ref",
> +};
> +
> +static struct snd_pci_quirk stac92hd71b5_cfg_tbl[] = {
> + {} /* terminator */
> +};
> +
> +static unsigned int ref92hd75b_5port_pin_configs[] = {
> + 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
> + 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
> + 0x98560060, 0x40f000f0,
> +};
> +
> +static unsigned int *stac92hd75b_5port_brd_tbl[STAC_92HD75B_5PORT_MODELS] = {
> + [STAC_92HD75B_5PORT_REF] = ref92hd75b_5port_pin_configs,
> + [STAC_HP_M4] = NULL,
> +};
> +
> +static const char *stac92hd75b_5port_models[STAC_92HD75B_5PORT_MODELS] = {
> + [STAC_92HD75B_5PORT_REF] = "ref",
> + [STAC_HP_M4] = "hp-m4",
> +};
> +
> +static struct snd_pci_quirk stac92hd75b_5port_cfg_tbl[] = {
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
> + "unknown HP", STAC_HP_M4),
> + {} /* terminator */
> +};
> +
> +static unsigned int ref92hd71bxx_pin_configs[13] = {
> 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
> 0x0181302e, 0x01014010, 0x01019020, 0x90a000f0,
> - 0x90a000f0, 0x01452050, 0x01452050,
> + 0x90a000f0, 0x01452050, 0x01452050, 0x00000000,
> + 0x00000000,
> };
>
> -static unsigned int dell_m4_1_pin_configs[11] = {
> +static unsigned int dell_m4_1_pin_configs[13] = {
> 0x0421101f, 0x04a11221, 0x40f000f0, 0x90170110,
> 0x23a1902e, 0x23014250, 0x40f000f0, 0x90a000f0,
> - 0x40f000f0, 0x4f0000f0, 0x4f0000f0,
> + 0x40f000f0, 0x4f0000f0, 0x4f0000f0, 0x00000000,
> + 0x00000000,
> };
>
> -static unsigned int dell_m4_2_pin_configs[11] = {
> +static unsigned int dell_m4_2_pin_configs[13] = {
> 0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
> 0x23a1902e, 0x23014250, 0x40f000f0, 0x40f000f0,
> - 0x40f000f0, 0x044413b0, 0x044413b0,
> + 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
> + 0x00000000,
> };
>
> -static unsigned int dell_m4_3_pin_configs[11] = {
> +static unsigned int dell_m4_3_pin_configs[13] = {
> 0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
> 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x90a000f0,
> - 0x40f000f0, 0x044413b0, 0x044413b0,
> + 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
> + 0x00000000,
> +};
> +
> +static unsigned int hp_m4_1_pin_configs[13] = {
> + 0x0221201f, 0x02a12050, 0x40f000f0, 0x90170010,
> + 0x40f000f1, 0x0221201f, 0x40f000f2, 0x90a60040,
> + 0x50f000f3, 0x28466060, 0x50f000f4, 0x00000000,
> + 0x90300041,
> +};
> +
> +static unsigned int hp_m4_2_pin_configs[13] = {
> + 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
> + 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
> + 0x50f000f3, 0x50f000f4, 0x50f000f5, 0x28466060,
> + 0x9030005a,
> +};
> +
> +static unsigned int hp_m4_3_pin_configs[13] = {
> + 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
> + 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
> + 0x50f000f3, 0x28466060, 0x50f000f4, 0x40f000f0,
> + 0x9030005a,
> +};
> +
> +static unsigned int hp_m4_4_pin_configs[13] = {
> + 0x0221201f, 0x02a12050, 0x90a70040, 0x90170010,
> + 0x40f000f1, 0x40f000f5, 0x40f000f2, 0x50f000f6,
> + 0x50f000f3, 0x50f000f7, 0x50f000f4, 0x28466060,
> + 0x9030005a,
> +};
> +
> +static unsigned int hp_m4_5_pin_configs[13] = {
> + 0x0221201f, 0x02a1205e, 0x90a70070, 0x90170010,
> + 0x4080005f, 0x40f000f5, 0x40f000f2, 0x50f000f1,
> + 0x50f000f3, 0x50f000f6, 0x50f000f4, 0x28466060,
> + 0x9030005a,
> };
>
> static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
> @@ -1702,8 +1817,11 @@ static unsigned int *stac92hd71bxx_brd_t
> [STAC_DELL_M4_1] = dell_m4_1_pin_configs,
> [STAC_DELL_M4_2] = dell_m4_2_pin_configs,
> [STAC_DELL_M4_3] = dell_m4_3_pin_configs,
> - [STAC_HP_M4] = NULL,
> - [STAC_HP_DV5] = NULL,
> + [STAC_HP_M4_1] = hp_m4_1_pin_configs,
> + [STAC_HP_M4_2] = hp_m4_2_pin_configs,
> + [STAC_HP_M4_3] = hp_m4_3_pin_configs,
> + [STAC_HP_M4_4] = hp_m4_4_pin_configs,
> + [STAC_HP_M4_5] = hp_m4_5_pin_configs,
> };
>
> static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
> @@ -1711,24 +1829,59 @@ static const char *stac92hd71bxx_models[
> [STAC_DELL_M4_1] = "dell-m4-1",
> [STAC_DELL_M4_2] = "dell-m4-2",
> [STAC_DELL_M4_3] = "dell-m4-3",
> - [STAC_HP_M4] = "hp-m4",
> - [STAC_HP_DV5] = "hp-dv5",
> + [STAC_HP_M4_1] = "hp-m4-1",
> + [STAC_HP_M4_2] = "hp-m4-2",
> + [STAC_HP_M4_3] = "hp-m4-3",
> + [STAC_HP_M4_4] = "hp-m4-4",
> + [STAC_HP_M4_5] = "hp-m4-5",
> };
>
> static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
> /* SigmaTel reference board */
> SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668,
> "DFI LanParty", STAC_92HD71BXX_REF),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
> - "HP dv5", STAC_HP_M4),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30de,
> + "unknown HP", STAC_HP_M4_1),
> + SND_PCI_QUIRK(0x30de, 0x103c,
> + "unknown HP", STAC_HP_M4_1),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x1505,
> + "unknown HP", STAC_HP_M4_1),
> + SND_PCI_QUIRK(0x1505, 0x103c,
> + "unknown HP", STAC_HP_M4_1),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f3,
> + "unknown HP", STAC_HP_M4_2),
> SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
> - "HP dv7", STAC_HP_M4),
> + "HP dv7", STAC_HP_M4_2),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
> + "unknown HP", STAC_HP_M4_2),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
> + "unknown HP", STAC_HP_M4_2),
> SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
> - "HP dv7", STAC_HP_M4),
> + "unknown HP", STAC_HP_M4_2),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd,
> + "unknown HP", STAC_HP_M4_2),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
> + "HP dv5", STAC_HP_M4_3),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
> + "unknown HP", STAC_HP_M4_3),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3602,
> + "unknown HP", STAC_HP_M4_3),
> SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
> - "HP dv5", STAC_HP_DV5),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
> - "unknown HP", STAC_HP_M4),
> + "unknown HP", STAC_HP_M4_3),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x360f,
> + "unknown HP", STAC_HP_M4_3),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3610,
> + "unknown HP", STAC_HP_M4_3),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30ff,
> + "unknown HP", STAC_HP_M4_4),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3601,
> + "unknown HP", STAC_HP_M4_4),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3607,
> + "unknown HP", STAC_HP_M4_4),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f8,
> + "unknown HP", STAC_HP_M4_5),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fe,
> + "unknown HP", STAC_HP_M4_5),
> SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
> "unknown Dell", STAC_DELL_M4_1),
> SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0234,
> @@ -2262,9 +2415,11 @@ static void stac92xx_set_config_regs(str
> if (!spec->pin_configs)
> return;
>
> - for (i = 0; i < spec->num_pins; i++)
> - stac92xx_set_config_reg(codec, spec->pin_nids[i],
> - spec->pin_configs[i]);
> + for (i = 0; i < spec->num_pins; i++) {
> + if (spec->pin_configs[i])
> + stac92xx_set_config_reg(codec, spec->pin_nids[i],
> + spec->pin_configs[i]);
> + }
> }
>
> /*
> @@ -4527,6 +4682,282 @@ static struct hda_codec_ops stac92hd71bx
> #endif
> };
>
> +static int stac92hd71bxx_connected_ports(struct hda_codec *codec,
> + hda_nid_t *nids, int num_nids)
> +{
> + struct sigmatel_spec *spec = codec->spec;
> + int idx, num;
> + unsigned int def_conf;
> +
> + for (num = 0; num < num_nids; num++) {
> + for (idx = 0; idx < spec->num_pins; idx++)
> + if (spec->pin_nids[idx] == nids[num])
> + break;
> + if (idx >= spec->num_pins)
> + break;
> + def_conf = get_defcfg_connect(spec->pin_configs[idx]);
> + if (def_conf == AC_JACK_PORT_NONE)
> + break;
> + }
> + return num;
> +}
> +
> +static int stac92hd71bxx_connected_smuxes(struct hda_codec *codec,
> + hda_nid_t dig0pin)
> +{
> + struct sigmatel_spec *spec = codec->spec;
> + int idx;
> +
> + for (idx = 0; idx < spec->num_pins; idx++)
> + if (spec->pin_nids[idx] == dig0pin)
> + break;
> + if ((idx + 2) >= spec->num_pins)
> + return 0;
> +
> + /* dig1pin case */
> + if (get_defcfg_connect(spec->pin_configs[idx+1]) != AC_JACK_PORT_NONE)
> + return 2;
> +
> + /* dig0pin + dig2pin case */
> + if (get_defcfg_connect(spec->pin_configs[idx+2]) != AC_JACK_PORT_NONE)
> + return 2;
> + if (get_defcfg_connect(spec->pin_configs[idx]) != AC_JACK_PORT_NONE)
> + return 1;
> + else
> + return 0;
> +}
> +
> +static struct hda_input_mux stac92hd71b5_dmux = {
> + .num_items = 3,
> + .items = {
> + { "Analog Inputs", 0x00 },
> + { "Digital Mic 1", 0x02 },
> + { "Digital Mic 2", 0x03 },
> + }
> +};
> +
> +static int patch_stac92hd71b5(struct hda_codec *codec)
> +{
> + struct sigmatel_spec *spec;
> + int err = 0;
> +
> + spec = kzalloc(sizeof(*spec), GFP_KERNEL);
> + if (spec == NULL)
> + return -ENOMEM;
> +
> + codec->spec = spec;
> + codec->patch_ops = stac92xx_patch_ops;
> + spec->num_pins = ARRAY_SIZE(stac92hd71b5_pin_nids);
> + spec->pin_nids = stac92hd71b5_pin_nids;
> +
> + memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
> + sizeof(stac92hd71b5_dmux));
> + spec->board_config = snd_hda_check_board_config(codec,
> + STAC_92HD71B5_MODELS,
> + stac92hd71b5_models,
> + stac92hd71b5_cfg_tbl);
> +again:
> + if (spec->board_config < 0) {
> + snd_printdd(KERN_INFO "hda_codec: Unknown model for"
> + " STAC92HD71B5, using BIOS defaults\n");
> + err = stac92xx_save_bios_config_regs(codec);
> + if (err < 0) {
> + stac92xx_free(codec);
> + return err;
> + }
> + spec->pin_configs = spec->bios_pin_configs;
> + } else {
> + spec->pin_configs = stac92hd71b5_brd_tbl[spec->board_config];
> + stac92xx_set_config_regs(codec);
> + }
> +
> + if (spec->board_config > STAC_92HD71B5_REF) {
> + /* GPIO0 = EAPD */
> + spec->gpio_mask = 0x01;
> + spec->gpio_dir = 0x01;
> + spec->gpio_data = 0x01;
> + spec->eapd_mask = 0x01; /* needed? */
> + spec->eapd_switch = 1; /* needed? */
> + }
> +
> + spec->mixer = stac92hd71bxx_mixer;
> + spec->init = stac92hd71bxx_core_init;
> + codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
> +
> + spec->num_pwrs = 0;
> + spec->powerdown_adcs = 1;
> + spec->digbeep_nid = 0x26;
> +
> + spec->mux_nids = stac92hd71bxx_mux_nids;
> + spec->adc_nids = stac92hd71bxx_adc_nids;
> + spec->dmic_nids = stac92hd71bxx_dmic_nids;
> + spec->dmux_nids = stac92hd71bxx_dmux_nids;
> + spec->smux_nids = stac92hd71bxx_smux_nids;
> + spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
> + spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
> + spec->num_dmics = stac92hd71bxx_connected_ports(codec,
> + stac92hd71bxx_dmic_nids,
> + STAC92HD71BXX_NUM_DMICS);
> + if (spec->num_dmics) {
> + spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> + spec->dinput_mux = &spec->private_dimux;
> + spec->private_dimux.num_items += spec->num_dmics -
> + (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
> + }
> + spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
> +
> + spec->multiout.num_dacs = 1;
> + spec->multiout.hp_nid = 0x11;
> + spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
> +
> + err = stac92xx_parse_auto_config(codec, 0x21, 0);
> + if (!err) {
> + if (spec->board_config < 0) {
> + printk(KERN_WARNING "hda_codec: No auto-config is "
> + "available, default to model=ref\n");
> + spec->board_config = STAC_92HD71B5_REF;
> + goto again;
> + }
> + err = -EINVAL;
> + }
> +
> + if (err < 0) {
> + stac92xx_free(codec);
> + return err;
> + }
> +
> + return 0;
> +}
> +
> +static struct hda_input_mux stac92hd75b_5port_dmux = {
> + .num_items = 3,
> + .items = {
> + { "Analog Inputs", 0x00 },
> + { "Mixer", 0x01 },
> + { "Digital Mic 1", 0x02 },
> + }
> +};
> +
> +static int patch_stac92hd75b_5port(struct hda_codec *codec)
> +{
> + struct sigmatel_spec *spec;
> + int err = 0;
> +
> + spec = kzalloc(sizeof(*spec), GFP_KERNEL);
> + if (spec == NULL)
> + return -ENOMEM;
> +
> + codec->spec = spec;
> + codec->patch_ops = stac92xx_patch_ops;
> + spec->num_pins = ARRAY_SIZE(stac92hd75b_5port_pin_nids);
> + spec->pin_nids = stac92hd75b_5port_pin_nids;
> +
> + memcpy(&spec->private_dimux, &stac92hd75b_5port_dmux,
> + sizeof(stac92hd75b_5port_dmux));
> + spec->board_config = snd_hda_check_board_config(codec,
> + STAC_92HD75B_5PORT_MODELS,
> + stac92hd75b_5port_models,
> + stac92hd75b_5port_cfg_tbl);
> +again:
> + if (spec->board_config < 0) {
> + snd_printdd(KERN_INFO "hda_codec: Unknown model for"
> + " STAC92HD75B_5PORT, using BIOS defaults\n");
> + err = stac92xx_save_bios_config_regs(codec);
> + if (err < 0) {
> + stac92xx_free(codec);
> + return err;
> + }
> + spec->pin_configs = spec->bios_pin_configs;
> + } else {
> + spec->pin_configs = stac92hd75b_5port_brd_tbl[spec->board_config];
> + if (!spec->pin_configs) {
> + err = stac92xx_save_bios_config_regs(codec);
> + if (err < 0) {
> + stac92xx_free(codec);
> + return err;
> + }
> + spec->pin_configs = spec->bios_pin_configs;
> + } else
> + stac92xx_set_config_regs(codec);
> + }
> +
> + if (spec->board_config > STAC_92HD75B_5PORT_REF) {
> + /* GPIO0 = EAPD */
> + spec->gpio_mask = 0x01;
> + spec->gpio_dir = 0x01;
> + spec->gpio_data = 0x01;
> + spec->eapd_mask = 0x01; /* needed? */
> + spec->eapd_switch = 1; /* needed? */
> + }
> +
> + if (spec->board_config == STAC_HP_M4) {
> + /* Enable VREF power saving on GPIO1 detect */
> + snd_hda_codec_write_cache(codec, codec->afg, 0,
> + AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
> + snd_hda_codec_write_cache(codec, codec->afg, 0,
> + AC_VERB_SET_UNSOLICITED_ENABLE,
> + (AC_USRSP_EN | STAC_VREF_EVENT | 0x01));
> + spec->gpio_mask |= 0x02;
> + stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
> + stac92xx_auto_set_pinctl(codec, 0x0e,
> + AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
> + spec->pin_configs[4] = 0x01813040;
> + }
> + if ((codec->revision_id & 0xf) == 0 ||
> + (codec->revision_id & 0xf) == 1) {
> +#ifdef SND_HDA_NEEDS_RESUME
> + codec->patch_ops = stac92hd71bxx_patch_ops;
> +#endif
> + spec->stream_delay = 40; /* 40 milliseconds */
> + }
> +
> + spec->mixer = stac92hd71bxx_analog_mixer;
> + spec->dinput_mux = &spec->private_dimux;
> + spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
> + codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
> +
> + spec->num_pwrs = 0;
> + spec->powerdown_adcs = 1;
> + spec->digbeep_nid = 0x26;
> +
> + spec->mux_nids = stac92hd71bxx_mux_nids;
> + spec->adc_nids = stac92hd71bxx_adc_nids;
> + spec->dmic_nids = stac92hd75b_5port_dmic_nids;
> + spec->dmux_nids = stac92hd71bxx_dmux_nids;
> + spec->smux_nids = stac92hd71bxx_smux_nids;
> + spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
> + spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
> + spec->num_dmics = stac92hd71bxx_connected_ports(codec,
> + stac92hd75b_5port_dmic_nids,
> + STAC92HD75B_5PORT_NUM_DMICS);
> + spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> + spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
> +
> + spec->multiout.num_dacs = 1;
> + spec->multiout.hp_nid = 0x11;
> + spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
> + spec->private_dimux.num_items += spec->num_dmics -
> + (ARRAY_SIZE(stac92hd75b_5port_dmic_nids) - 1);
> +
> + err = stac92xx_parse_auto_config(codec, 0x21, 0);
> + if (!err) {
> + if (spec->board_config < 0) {
> + printk(KERN_WARNING "hda_codec: No auto-config is "
> + "available, default to model=ref\n");
> + spec->board_config = STAC_92HD75B_5PORT_REF;
> + goto again;
> + }
> + err = -EINVAL;
> + }
> +
> + if (err < 0) {
> + stac92xx_free(codec);
> + return err;
> + }
> +
> + return 0;
> +}
> +
> static struct hda_input_mux stac92hd71bxx_dmux = {
> .num_items = 4,
> .items = {
> @@ -4549,10 +4980,12 @@ static int patch_stac92hd71bxx(struct hd
> codec->spec = spec;
> codec->patch_ops = stac92xx_patch_ops;
> spec->num_pins = ARRAY_SIZE(stac92hd71bxx_pin_nids);
> - spec->num_pwrs = ARRAY_SIZE(stac92hd71bxx_pwr_nids);
> spec->pin_nids = stac92hd71bxx_pin_nids;
> - memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
> - sizeof(stac92hd71bxx_dmux));
> +
> + /* On 92HD75B3/92HD75B4 0x27 isn't a pin nid */
> + if (codec->vendor_id == 0x111d7603)
> + spec->num_pins--;
> +
> spec->board_config = snd_hda_check_board_config(codec,
> STAC_92HD71BXX_MODELS,
> stac92hd71bxx_models,
> @@ -4577,46 +5010,35 @@ again:
> spec->gpio_mask = 0x01;
> spec->gpio_dir = 0x01;
> spec->gpio_data = 0x01;
> + spec->eapd_mask = 0x01; /* needed? */
> + spec->eapd_switch = 1; /* needed? */
> }
>
> + spec->mux_nids = stac92hd71bxx_mux_nids;
> + spec->adc_nids = stac92hd71bxx_adc_nids;
> + spec->dmic_nids = stac92hd71bxx_dmic_nids;
> + spec->dmux_nids = stac92hd71bxx_dmux_nids;
> + spec->smux_nids = stac92hd71bxx_smux_nids;
> + spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
> + spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
> + spec->num_dmics = stac92hd71bxx_connected_ports(codec,
> + stac92hd71bxx_dmic_nids,
> + STAC92HD71BXX_NUM_DMICS);
> + spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
> +
> switch (codec->vendor_id) {
> - case 0x111d76b6: /* 4 Port without Analog Mixer */
> - case 0x111d76b7:
> case 0x111d76b4: /* 6 Port without Analog Mixer */
> case 0x111d76b5:
> + memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
> + sizeof(stac92hd71b5_dmux));
> + if (spec->num_dmics) {
> + spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> + spec->dinput_mux = &spec->private_dimux;
> + }
> spec->mixer = stac92hd71bxx_mixer;
> spec->init = stac92hd71bxx_core_init;
> codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
> break;
> - case 0x111d7608: /* 5 Port with Analog Mixer */
> - switch (spec->board_config) {
> - case STAC_HP_M4:
> - /* Enable VREF power saving on GPIO1 detect */
> - snd_hda_codec_write_cache(codec, codec->afg, 0,
> - AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
> - snd_hda_codec_write_cache(codec, codec->afg, 0,
> - AC_VERB_SET_UNSOLICITED_ENABLE,
> - (AC_USRSP_EN | STAC_VREF_EVENT | 0x01));
> - spec->gpio_mask |= 0x02;
> - break;
> - }
> - if ((codec->revision_id & 0xf) == 0 ||
> - (codec->revision_id & 0xf) == 1) {
> -#ifdef SND_HDA_NEEDS_RESUME
> - codec->patch_ops = stac92hd71bxx_patch_ops;
> -#endif
> - spec->stream_delay = 40; /* 40 milliseconds */
> - }
> -
> - /* no output amps */
> - spec->num_pwrs = 0;
> - spec->mixer = stac92hd71bxx_analog_mixer;
> - spec->dinput_mux = &spec->private_dimux;
> -
> - /* disable VSW */
> - spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
> - stac92xx_set_config_reg(codec, 0xf, 0x40f000f0);
> - break;
> case 0x111d7603: /* 6 Port with Analog Mixer */
> if ((codec->revision_id & 0xf) == 1) {
> #ifdef SND_HDA_NEEDS_RESUME
> @@ -4624,65 +5046,29 @@ again:
> #endif
> spec->stream_delay = 40; /* 40 milliseconds */
> }
> -
> - /* no output amps */
> - spec->num_pwrs = 0;
> /* fallthru */
> default:
> + memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
> + sizeof(stac92hd71bxx_dmux));
> spec->dinput_mux = &spec->private_dimux;
> + spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> spec->mixer = stac92hd71bxx_analog_mixer;
> spec->init = stac92hd71bxx_analog_core_init;
> codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
> }
>
> - spec->aloopback_mask = 0x50;
> - spec->aloopback_shift = 0;
> -
> + spec->num_pwrs = 0;
> spec->powerdown_adcs = 1;
> spec->digbeep_nid = 0x26;
> - spec->mux_nids = stac92hd71bxx_mux_nids;
> - spec->adc_nids = stac92hd71bxx_adc_nids;
> - spec->dmic_nids = stac92hd71bxx_dmic_nids;
> - spec->dmux_nids = stac92hd71bxx_dmux_nids;
> - spec->smux_nids = stac92hd71bxx_smux_nids;
> - spec->pwr_nids = stac92hd71bxx_pwr_nids;
> -
> - spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
> - spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
> -
> - switch (spec->board_config) {
> - case STAC_HP_M4:
> - /* enable internal microphone */
> - stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
> - stac92xx_auto_set_pinctl(codec, 0x0e,
> - AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
> - /* fallthru */
> - case STAC_DELL_M4_2:
> - spec->num_dmics = 0;
> - spec->num_smuxes = 0;
> - spec->num_dmuxes = 0;
> - break;
> - case STAC_DELL_M4_1:
> - case STAC_DELL_M4_3:
> - spec->num_dmics = 1;
> - spec->num_smuxes = 0;
> - spec->num_dmuxes = 0;
> - break;
> - default:
> - spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
> - spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
> - spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> - };
>
> spec->multiout.num_dacs = 1;
> spec->multiout.hp_nid = 0x11;
> spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
> - if (spec->dinput_mux)
> - spec->private_dimux.num_items +=
> + spec->private_dimux.num_items +=
> spec->num_dmics -
> (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
>
> - err = stac92xx_parse_auto_config(codec, 0x21, 0x23);
> + err = stac92xx_parse_auto_config(codec, 0x21, 0);
> if (!err) {
> if (spec->board_config < 0) {
> printk(KERN_WARNING "hda_codec: No auto-config is "
> @@ -4699,7 +5085,7 @@ again:
> }
>
> return 0;
> -};
> +}
>
> static int patch_stac922x(struct hda_codec *codec)
> {
> @@ -5335,10 +5721,10 @@ struct hda_codec_preset snd_hda_preset_s
> { .id = 0x838476a5, .name = "STAC9255D", .patch = patch_stac9205 },
> { .id = 0x838476a6, .name = "STAC9254", .patch = patch_stac9205 },
> { .id = 0x838476a7, .name = "STAC9254D", .patch = patch_stac9205 },
> - { .id = 0x111d7603, .name = "92HD75B3X5", .patch = patch_stac92hd71bxx},
> - { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx},
> - { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx},
> - { .id = 0x111d7608, .name = "92HD75B2X5", .patch = patch_stac92hd71bxx},
> + { .id = 0x111d7603, .name = "92HD75B3/4", .patch = patch_stac92hd71bxx },
> + { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx },
> + { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx },
> + { .id = 0x111d7608, .name = "92HD75B1/2", .patch = patch_stac92hd75b_5port },
> { .id = 0x111d7674, .name = "92HD73D1X5", .patch = patch_stac92hd73xx },
> { .id = 0x111d7675, .name = "92HD73C1X5", .patch = patch_stac92hd73xx },
> { .id = 0x111d7676, .name = "92HD73E1X5", .patch = patch_stac92hd73xx },
> @@ -5348,7 +5734,7 @@ struct hda_codec_preset snd_hda_preset_s
> { .id = 0x111d76b3, .name = "92HD71B7X", .patch = patch_stac92hd71bxx },
> { .id = 0x111d76b4, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
> { .id = 0x111d76b5, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
> - { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
> - { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
> + { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
> + { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
> {} /* terminator */
> };
> [3 sound-alsa-hda-add-msi-quirk-list.patch <text/x-patch; UTF-8 (7bit)>]
> ALSA: hda - Add MSI quirk list
>
> It is reported that models of HP dv7 laptops needs MSI to function
> properly. This adds a MSI quirk list support to snd-hda-intel to
> preset enable_msi option for machines that needs MSI disabled/enabled
> and set required setting for HP dv7 laptops.
>
> Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
>
> ---
> sound/pci/hda/hda_intel.c | 25 +++++++++++++++++++++++++
> 1 file changed, 25 insertions(+)
>
> diff -p -up linux-2.6.27/sound/pci/hda/hda_intel.c.orig linux-2.6.27/sound/pci/hda/hda_intel.c
> --- linux-2.6.27/sound/pci/hda/hda_intel.c.orig 2009-01-22 06:52:07.000000000 -0500
> +++ linux-2.6.27/sound/pci/hda/hda_intel.c 2009-01-22 06:55:20.000000000 -0500
> @@ -2050,6 +2050,30 @@ static int azx_dev_free(struct snd_devic
> }
>
> /*
> + * white/black-listing for enable_msi
> + */
> +static struct snd_pci_quirk msi_list[] __devinitdata = {
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4, "HP dv7", 0x01),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc, "HP dv7", 0x01),
> + SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd, "HP dv7", 0x01),
> + {}
> +};
> +
> +static void __devinit check_msi(struct azx *chip)
> +{
> + const struct snd_pci_quirk *q;
> +
> + q = snd_pci_quirk_lookup(chip->pci, msi_list);
> + if (q) {
> + printk(KERN_INFO
> + "hda_intel: enable_msi set to 0x%x "
> + "for device %04x:%04x\n",
> + q->value, q->subvendor, q->subdevice);
> + enable_msi = q->value;
> + }
> +}
> +
> +/*
> * white/black-listing for position_fix
> */
> static struct snd_pci_quirk position_fix_list[] __devinitdata = {
> @@ -2148,6 +2172,7 @@ static int __devinit azx_create(struct s
> chip->pci = pci;
> chip->irq = -1;
> chip->driver_type = driver_type;
> + check_msi(chip);
> chip->msi = enable_msi;
> chip->dev_index = dev;
> INIT_WORK(&chip->irq_pending_work, azx_irq_pending_work);
> [4 <text/plain; us-ascii (7bit)>]
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2009-02-02 18:52 ` Takashi Iwai
@ 2009-02-02 19:19 ` Tim Barnette
2009-02-02 19:48 ` Herton Ronaldo Krzesinski
2009-02-03 13:49 ` Jean-Pierre André
2 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-02 19:19 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski; +Cc: alsa-devel, Jean-Pierre André
Herton, I downloaded the patches. What do I do with them? Will these
address MSI PCI enable and config mentioned in your email?
Thank You,
Tim Barnette
2009/2/2 Herton Ronaldo Krzesinski <herton@mandriva.com.br>
> Em Sábado 31 Janeiro 2009, às 05:52:19, Jean-Pierre André escreveu:
> >
> > Hi,
> >
> > > Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
> > > through the speakers, although it does work through the headhpones. I
> ran
> > > alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still
> no
> > > luck.
> > >
> >
> > I have the same IDT codec 92HD71B7X on another
> > HP DV4 model, and I have tracked the problem to be
> > the kernel configuring IRQ 22 through the APIC, but
> > interrupts triggerring IRQ 20 (on kernel 2.6.27 and
> > alsa 1.0.19). It would be interesting if you could
> > confirm this by analyzing /proc/interrupts.
> >
> > The workarounds I know of are :
> > - adding irqpoll to the boot options,
> > - or adding noapic to the boot options,
> > - using mplayer to play music.
> >
> > There are with option "snd-hda-intel model=hp-m4"
> > (this option is for HP DV5/DV7, but HP DV4
> > is probably different)
> >
> > I have not enough knowledge to tell where the problem
> > lies : kernel, apic, alsa.
>
> It looks like some of these HP laptops have some sort of IRQ issue indeed,
> to
> me it was reported that enabling pci MSI (both system wide and with
> enable_msi=1 given to snd-hda-intel) cured issues in some cases, along with
> some changes to sigmatel codec handling code in snd-hda-intel
>
> I have a ticked opened where people started to complain about sound issues
> with hda-intel+sigmatel codec starting with alsa 1.0.18rc3 (sorry, it's a
> great mess, type of the ticket everyone says sound doesn't work and report
> in,
> but where I tried to filter some things out):
> https://qa.mandriva.com/show_bug.cgi?id=44855
> Also some reports are hard to understand sometimes.
> With alsa 1.0.18 final in 2.6.27 (or 2.6.28) many issues related on the
> ticket
> were fixed, but issues with HP laptops remained.
>
> I don't have any of affected HP laptops for test, but based on sigmatel
> datasheets, reports of users and pin cfgs used in .ini files of sigmatel
> windows drivers I made some changes to sigmatel code, plus added patch to
> set
> enable_msi. The only issue I have with the changes, and that's why I didn't
> submit yet, is that I should have split them, don't know if everything is
> really required, and ask here to clarify some things below; also the
> changes
> are outdated compared to current sound git tree.
>
> I'm attaching here the changes, they were made against kernel 2.6.28.2
> - One patch deals with the sigmatel codec code, some things to note (others
> are cited on the patch):
> * despite being almost the same, only with some models missing
> widgets/pins, I
> splitted support from patch_stac92hd71bxx for idt 92HD71B5X (4 port),
> 92HD75B1/2 (5 port). Mostly because of different number of pins between
> them,
> may be could have still hacked more stac92xx_set_config_regs to avoid this.
> * Many people complained about the Analog Loopback, causing problems when
> it's
> enabled; I really don't know what exactly this is supposed to do (is it
> just a
> mute of outputs or something like is described here?:
> http://people.atrpms.net/~pcavalcanti/alsa-1.0.15rc2_snd-hda-intel.html<http://people.atrpms.net/%7Epcavalcanti/alsa-1.0.15rc2_snd-hda-intel.html>)
> and
> all sigmatel datasheets I look don't mention it, in the patch I removed it.
> * power management on pins (stac92hd71bxx_pwr_nids) are not listed on
> sigmatel
> datasheets I dowloaded from idt site (for STAC92HD71Bx and STAC92HD75Bx),
> so I
> removed its setting (or I'm missing something here...).
> - The other patch adds a quirk list to force enable_msi=1. PCI_MSI must be
> enabled to give results.
>
> >
> > Regards
> >
> > Jean-Pierre
> >
> >
> > > I ran alsa-info, output here:
> > >
> http://www.alsa-project.org/db/?f=844b7ee6468067460e17b7fc694e49052072a26f
> > >
> > > I filed a bug, here:
> > > https://bugtrack.alsa-project.org/alsa-bug/view.php?id=4374
> > >
> > > Any ideas?
> > >
>
> --
> []'s
> Herton
>
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 19:19 ` Tim Barnette
@ 2009-02-02 19:48 ` Herton Ronaldo Krzesinski
0 siblings, 0 replies; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-02 19:48 UTC (permalink / raw)
To: Tim Barnette; +Cc: alsa-devel, Jean-Pierre André
Em Segunda-feira 02 Fevereiro 2009, às 17:19:13, Tim Barnette escreveu:
> Herton, I downloaded the patches. What do I do with them? Will these
> address MSI PCI enable and config mentioned in your email?
You can try/apply them and build with 2.6.28.2 kernel. It'll not set
enable_msi=1 by default as the subvendor/subdevice ids are not on the list
(103c:30fb), just add them to sound/pci/hda/hda_intel.c at msi_list
(see sound-alsa-hda-add-msi-quirk-list.patch) and make sure CONFIG_PCI_MSI is
enabled on kernel config, or just load snd-hda-intel with option enable_msi=1
(and in this case you don't need to apply msi patch). But test before without
enabling msi, it may be not needed.
>
> Thank You,
> Tim Barnette
--
[]'s
Herton
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2009-02-02 18:52 ` Takashi Iwai
2009-02-02 19:19 ` Tim Barnette
@ 2009-02-03 13:49 ` Jean-Pierre André
2009-02-04 17:01 ` Jean-Pierre André
2 siblings, 1 reply; 36+ messages in thread
From: Jean-Pierre André @ 2009-02-03 13:49 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski; +Cc: tiwai, alsa-devel, tim.barnette
[-- Attachment #1: Type: text/plain, Size: 5242 bytes --]
Hi Herton,
Thank you for trying to sort his out,
Herton Ronaldo Krzesinski wrote:
> Em Sábado 31 Janeiro 2009, às 05:52:19, Jean-Pierre André escreveu:
>
>> Hi,
>>
>>
>>> Hi all, I have an HP DV4 1155-SE, I've been unable to get sound working
>>> through the speakers, although it does work through the headhpones. I ran
>>> alsa-.upgrade which downloaded compiled, and installed 1.0.19 - still no
>>> luck.
>>>
>>>
>> I have the same IDT codec 92HD71B7X on another
>> HP DV4 model, and I have tracked the problem to be
>> the kernel configuring IRQ 22 through the APIC, but
>> interrupts triggerring IRQ 20 (on kernel 2.6.27 and
>> alsa 1.0.19). It would be interesting if you could
>> confirm this by analyzing /proc/interrupts.
>>
>> The workarounds I know of are :
>> - adding irqpoll to the boot options,
>> - or adding noapic to the boot options,
>> - using mplayer to play music.
>>
>> There are with option "snd-hda-intel model=hp-m4"
>> (this option is for HP DV5/DV7, but HP DV4
>> is probably different)
>>
>> I have not enough knowledge to tell where the problem
>> lies : kernel, apic, alsa.
>>
>
> It looks like some of these HP laptops have some sort of IRQ issue indeed, to
> me it was reported that enabling pci MSI (both system wide and with
> enable_msi=1 given to snd-hda-intel) cured issues in some cases, along with
> some changes to sigmatel codec handling code in snd-hda-intel
>
> I have a ticked opened where people started to complain about sound issues
> with hda-intel+sigmatel codec starting with alsa 1.0.18rc3 (sorry, it's a
> great mess, type of the ticket everyone says sound doesn't work and report in,
> but where I tried to filter some things out):
> https://qa.mandriva.com/show_bug.cgi?id=44855
> Also some reports are hard to understand sometimes.
> With alsa 1.0.18 final in 2.6.27 (or 2.6.28) many issues related on the ticket
> were fixed, but issues with HP laptops remained.
>
> I don't have any of affected HP laptops for test, but based on sigmatel
> datasheets, reports of users and pin cfgs used in .ini files of sigmatel
> windows drivers I made some changes to sigmatel code, plus added patch to set
> enable_msi. The only issue I have with the changes, and that's why I didn't
> submit yet, is that I should have split them, don't know if everything is
> really required, and ask here to clarify some things below; also the changes
> are outdated compared to current sound git tree.
>
Thank you for your suggested patches. I had some difficulties in
applying them as your reference version is not from the lasted build.
(for instance from alsa-driver-1.0.19.0.g5aa59.6.gb162b.tar.bz2)
Actually, to get patch_sigmatel to compile, I had to reintegrate
old deprecated code. Attached are the patches I really applied.
And the result is worse than before : no sound at all, using option
"model hp-m4-2", as I see in the patch that this was designed for
my sound device (subsystem id 0x30f7). I am also using option
enable_msi=1.
And still no IRQ 22 seen, IRQ 20 instead, could be another problem,
but what can I do to clarify this ?
With the original code, this is what I get in the syslog,
Feb 3 12:27:18 pavilion2 kernel: HDA Intel 0000:00:1b.0: power state
changed by ACPI to D0
Feb 3 12:27:18 pavilion2 kernel: HDA Intel 0000:00:1b.0: PCI INT B ->
GSI 22 (level, low) -> IRQ 22
Feb 3 12:27:19 pavilion2 kernel: ALSA
/var/tmp/bach-build/BUILD/alsa-driver-1.0.19/pci/hda/hda_intel.c:634:
hda_intel: azx_get_response timeout, switching to polling mode: last
cmd=0x000f0000
Feb 3 12:27:19 pavilion2 kernel: input: HDA Digital PCBeep as
/devices/pci0000:00/0000:00:1b.0/input/input38
Feb 3 12:27:19 pavilion2 kernel: input: HDA Intel at 0xdf300000 irq 22
Line In at Ext Rear Jack as /devices/pci0000:00/0000:00:1b.0/input/input39
Feb 3 12:27:19 pavilion2 kernel: input: HDA Intel at 0xdf300000 irq 22
Mic at Ext Front Jack as /devices/pci0000:00/0000:00:1b.0/input/input40
Feb 3 12:27:19 pavilion2 kernel: input: HDA Intel at 0xdf300000 irq 22
HP Out at Ext Front Jack as /devices/pci0000:00/0000:00:1b.0/input/input41
With the patched one, the last line does not appear, this should
lead to the point where the patch has broken something :
Feb 3 11:23:47 pavilion2 kernel: HDA Intel 0000:00:1b.0: power state
changed by ACPI to D0
Feb 3 11:23:47 pavilion2 kernel: HDA Intel 0000:00:1b.0: PCI INT B ->
GSI 22 (level, low) -> IRQ 22
Feb 3 11:23:48 pavilion2 kernel: ALSA
/home/linux/rpmbuild/BUILD/alsa-driver-1.0.19/pci/hda/hda_intel.c:634:
hda_intel: azx_get_response timeout, switching to polling mode: last
cmd=0x000f0000
Feb 3 11:23:48 pavilion2 kernel: input: HDA Digital PCBeep as
/devices/pci0000:00/0000:00:1b.0/input/input19
Feb 3 11:23:48 pavilion2 kernel: input: HDA Intel at 0xdf300000 irq 22
Mic at Ext Front Jack as /devices/pci0000:00/0000:00:1b.0/input/input20
Feb 3 11:23:48 pavilion2 kernel: input: HDA Intel at 0xdf300000 irq 22
HP Out at Ext Front Jack as /devices/pci0000:00/0000:00:1b.0/input/input21
I am open to any further test which you might suggest
Regards
Jean-Pierre
[-- Attachment #2: herton-sigmatel.patch --]
[-- Type: text/plain, Size: 28984 bytes --]
--- alsa-driver-1.0.19/alsa-kernel/pci/hda/patch_sigmatel.c.old 2009-01-19 12:08:58.000000000 +0100
+++ alsa-driver-1.0.19/alsa-kernel/pci/hda/patch_sigmatel.c 2009-02-03 12:37:12.000000000 +0100
@@ -85,12 +85,26 @@
};
enum {
+ STAC_92HD71B5_REF,
+ STAC_92HD71B5_MODELS
+};
+
+enum {
+ STAC_92HD75B_5PORT_REF,
+ STAC_HP_M4,
+ STAC_92HD75B_5PORT_MODELS
+};
+
+enum {
STAC_92HD71BXX_REF,
STAC_DELL_M4_1,
STAC_DELL_M4_2,
STAC_DELL_M4_3,
- STAC_HP_M4,
- STAC_HP_DV5,
+ STAC_HP_M4_1,
+ STAC_HP_M4_2,
+ STAC_HP_M4_3,
+ STAC_HP_M4_4,
+ STAC_HP_M4_5,
STAC_92HD71BXX_MODELS
};
@@ -224,6 +238,7 @@
hda_nid_t *pin_nids;
unsigned int num_pins;
unsigned int *pin_configs;
+ unsigned int *bios_pin_configs;
/* codec specific stuff */
struct hda_verb *init;
@@ -341,10 +356,6 @@
0xc,
};
-static hda_nid_t stac92hd71bxx_pwr_nids[3] = {
- 0x0a, 0x0d, 0x0f
-};
-
static hda_nid_t stac92hd71bxx_adc_nids[2] = {
0x12, 0x13,
};
@@ -353,6 +364,10 @@
0x1a, 0x1b
};
+static hda_nid_t stac92hd71bxx_dac_nids[2] = {
+ 0x10, /*0x11, */
+};
+
static hda_nid_t stac92hd71bxx_dmux_nids[2] = {
0x1c, 0x1d,
};
@@ -361,6 +376,11 @@
0x24, 0x25,
};
+#define STAC92HD75B_5PORT_NUM_DMICS 1
+static hda_nid_t stac92hd75b_5port_dmic_nids[STAC92HD75B_5PORT_NUM_DMICS + 1] = {
+ 0x18, 0
+};
+
#define STAC92HD71BXX_NUM_DMICS 2
static hda_nid_t stac92hd71bxx_dmic_nids[STAC92HD71BXX_NUM_DMICS + 1] = {
0x18, 0x19, 0
@@ -476,10 +496,22 @@
0x0f, 0x10, 0x11, 0x12, 0x13,
0x1d, 0x1e, 0x1f, 0x20
};
-static hda_nid_t stac92hd71bxx_pin_nids[11] = {
+
+static hda_nid_t stac92hd71b5_pin_nids[11] = {
+ 0x0a, 0x0b, 0x0c, 0x0d, 0x14,
+ 0x18, 0x19, 0x1e, 0x1f, 0x20,
+ 0x27
+};
+
+static hda_nid_t stac92hd75b_5port_pin_nids[10] = {
+ 0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
+ 0x14, 0x18, 0x1e, 0x1f, 0x20
+};
+
+static hda_nid_t stac92hd71bxx_pin_nids[13] = {
0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
0x0f, 0x14, 0x18, 0x19, 0x1e,
- 0x1f,
+ 0x1f, 0x20, 0x27
};
static hda_nid_t stac927x_pin_nids[14] = {
@@ -857,10 +889,17 @@
static struct hda_verb stac92hd71bxx_core_init[] = {
/* set master volume and direct control */
{ 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
- /* unmute right and left channels for nodes 0x0a, 0xd, 0x0f */
+ /* connect headphone jack to dac1 */
+ { 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
+ /* connect port D/mono out to dac0 */
+ { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* make sure dmuxes are initially connected to analog muxes */
+ { 0x1c, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x1d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* unmute right and left channels for nodes 0x0a, 0xd */
{ 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{ 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
- { 0x0f, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{}
};
@@ -876,6 +915,14 @@
/* set master volume and direct control */
{ 0x28, AC_VERB_SET_VOLUME_KNOB_CONTROL, 0xff},
+ /* connect headphone jack to dac1 */
+ { 0x0a, AC_VERB_SET_CONNECT_SEL, 0x01},
+ /* connect port D/mono out to dac0 */
+ { 0x0d, AC_VERB_SET_CONNECT_SEL, 0x00},
+ { 0x15, AC_VERB_SET_CONNECT_SEL, 0x00},
+ /* unmute and max step for dac0/dac1 inputs in mixer */
+ { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x701f},
+ { 0x17, AC_VERB_SET_AMP_GAIN_MUTE, 0x711f},
/* unmute right and left channels for nodes 0x0a, 0xd */
{ 0x0a, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
{ 0x0d, AC_VERB_SET_AMP_GAIN_MUTE, AMP_IN_UNMUTE(0)},
@@ -1098,7 +1145,6 @@
static struct snd_kcontrol_new stac92hd71bxx_analog_mixer[] = {
STAC_INPUT_SOURCE(2),
- STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
@@ -1127,7 +1173,6 @@
static struct snd_kcontrol_new stac92hd71bxx_mixer[] = {
STAC_INPUT_SOURCE(2),
- STAC_ANALOG_LOOPBACK(0xFA0, 0x7A0, 2),
HDA_CODEC_VOLUME_IDX("Capture Volume", 0x0, 0x1c, 0x0, HDA_OUTPUT),
HDA_CODEC_MUTE_IDX("Capture Switch", 0x0, 0x1c, 0x0, HDA_OUTPUT),
@@ -1751,28 +1796,107 @@
{} /* terminator */
};
-static unsigned int ref92hd71bxx_pin_configs[11] = {
+static unsigned int ref92hd71b5_pin_configs[] = {
+ 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
+ 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
+ 0x98560060, 0x40f000f0, 0x40f000f0,
+};
+
+static unsigned int *stac92hd71b5_brd_tbl[STAC_92HD71B5_MODELS] = {
+ [STAC_92HD71B5_REF] = ref92hd71b5_pin_configs,
+};
+
+static const char *stac92hd71b5_models[STAC_92HD71B5_MODELS] = {
+ [STAC_92HD71B5_REF] = "ref",
+};
+
+static struct snd_pci_quirk stac92hd71b5_cfg_tbl[] = {
+ {} /* terminator */
+};
+
+static unsigned int ref92hd75b_5port_pin_configs[] = {
+ 0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
+ 0x40f000f0, 0x40f000f0, 0x40f000f0, 0x01452050,
+ 0x98560060, 0x40f000f0,
+};
+
+static unsigned int *stac92hd75b_5port_brd_tbl[STAC_92HD75B_5PORT_MODELS] = {
+ [STAC_92HD75B_5PORT_REF] = ref92hd75b_5port_pin_configs,
+ [STAC_HP_M4] = NULL,
+};
+
+static const char *stac92hd75b_5port_models[STAC_92HD75B_5PORT_MODELS] = {
+ [STAC_92HD75B_5PORT_REF] = "ref",
+ [STAC_HP_M4] = "hp-m4",
+};
+
+static struct snd_pci_quirk stac92hd75b_5port_cfg_tbl[] = {
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
+ "unknown HP", STAC_HP_M4),
+ {} /* terminator */
+};
+
+static unsigned int ref92hd71bxx_pin_configs[13] = {
0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
0x0181302e, 0x01014010, 0x01019020, 0x90a000f0,
- 0x90a000f0, 0x01452050, 0x01452050,
+ 0x90a000f0, 0x01452050, 0x01452050, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_1_pin_configs[11] = {
+static unsigned int dell_m4_1_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x40f000f0, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x4f0000f0, 0x4f0000f0,
+ 0x40f000f0, 0x4f0000f0, 0x4f0000f0, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_2_pin_configs[11] = {
+static unsigned int dell_m4_2_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x40f000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000,
};
-static unsigned int dell_m4_3_pin_configs[11] = {
+static unsigned int dell_m4_3_pin_configs[13] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x40f000f0, 0x40f000f0, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000,
+};
+
+static unsigned int hp_m4_1_pin_configs[13] = {
+ 0x0221201f, 0x02a12050, 0x40f000f0, 0x90170010,
+ 0x40f000f1, 0x0221201f, 0x40f000f2, 0x90a60040,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x00000000,
+ 0x90300041,
+};
+
+static unsigned int hp_m4_2_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x50f000f4, 0x50f000f5, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_3_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x40f000f0,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_4_pin_configs[13] = {
+ 0x0221201f, 0x02a12050, 0x90a70040, 0x90170010,
+ 0x40f000f1, 0x40f000f5, 0x40f000f2, 0x50f000f6,
+ 0x50f000f3, 0x50f000f7, 0x50f000f4, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_5_pin_configs[13] = {
+ 0x0221201f, 0x02a1205e, 0x90a70070, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x50f000f1,
+ 0x50f000f3, 0x50f000f6, 0x50f000f4, 0x28466060,
+ 0x9030005a,
};
static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
@@ -1780,8 +1904,11 @@
[STAC_DELL_M4_1] = dell_m4_1_pin_configs,
[STAC_DELL_M4_2] = dell_m4_2_pin_configs,
[STAC_DELL_M4_3] = dell_m4_3_pin_configs,
- [STAC_HP_M4] = NULL,
- [STAC_HP_DV5] = NULL,
+ [STAC_HP_M4_1] = hp_m4_1_pin_configs,
+ [STAC_HP_M4_2] = hp_m4_2_pin_configs,
+ [STAC_HP_M4_3] = hp_m4_3_pin_configs,
+ [STAC_HP_M4_4] = hp_m4_4_pin_configs,
+ [STAC_HP_M4_5] = hp_m4_5_pin_configs,
};
static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
@@ -1789,24 +1916,59 @@
[STAC_DELL_M4_1] = "dell-m4-1",
[STAC_DELL_M4_2] = "dell-m4-2",
[STAC_DELL_M4_3] = "dell-m4-3",
- [STAC_HP_M4] = "hp-m4",
- [STAC_HP_DV5] = "hp-dv5",
+ [STAC_HP_M4_1] = "hp-m4-1",
+ [STAC_HP_M4_2] = "hp-m4-2",
+ [STAC_HP_M4_3] = "hp-m4-3",
+ [STAC_HP_M4_4] = "hp-m4-4",
+ [STAC_HP_M4_5] = "hp-m4-5",
};
static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
/* SigmaTel reference board */
SND_PCI_QUIRK(PCI_VENDOR_ID_INTEL, 0x2668,
"DFI LanParty", STAC_92HD71BXX_REF),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
- "HP dv5", STAC_HP_M4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30de,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(0x30de, 0x103c,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x1505,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(0x1505, 0x103c,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f3,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
- "HP dv7", STAC_HP_M4),
+ "HP dv7", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
- "HP dv7", STAC_HP_M4),
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd,
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
+ "HP dv5", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3602,
+ "unknown HP", STAC_HP_M4_3),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
- "HP dv5", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
- "unknown HP", STAC_HP_M4),
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x360f,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3610,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30ff,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3601,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3607,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f8,
+ "unknown HP", STAC_HP_M4_5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fe,
+ "unknown HP", STAC_HP_M4_5),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
"unknown Dell", STAC_DELL_M4_1),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0234,
@@ -2339,9 +2501,11 @@
if (!spec->pin_configs)
return;
- for (i = 0; i < spec->num_pins; i++)
- stac92xx_set_config_reg(codec, spec->pin_nids[i],
- spec->pin_configs[i]);
+ for (i = 0; i < spec->num_pins; i++) {
+ if (spec->pin_configs[i])
+ stac92xx_set_config_reg(codec, spec->pin_nids[i],
+ spec->pin_configs[i]);
+ }
}
static int stac_save_pin_cfgs(struct hda_codec *codec, unsigned int *pins)
@@ -4583,6 +4747,50 @@
return 0;
}
+#ifdef SND_HDA_NEEDS_RESUME /* JPA reinserting old code, had been removed */
+static void stac92hd71xx_set_power_state(struct hda_codec *codec, int pwr)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int i;
+ snd_hda_codec_write_cache(codec, codec->afg, 0,
+ AC_VERB_SET_POWER_STATE, pwr);
+
+ msleep(1);
+ for (i = 0; i < spec->num_adcs; i++) {
+ snd_hda_codec_write_cache(codec,
+ spec->adc_nids[i], 0,
+ AC_VERB_SET_POWER_STATE, pwr);
+ }
+};
+
+static int stac92hd71xx_resume(struct hda_codec *codec)
+{
+ stac92hd71xx_set_power_state(codec, AC_PWRST_D0);
+ return stac92xx_resume(codec);
+}
+
+static int stac92hd71xx_suspend(struct hda_codec *codec, pm_message_t state)
+{
+ stac92hd71xx_set_power_state(codec, AC_PWRST_D3);
+ return stac92xx_suspend(codec, state);
+};
+
+#endif
+
+static struct hda_codec_ops stac92hd71bxx_patch_ops = {
+ .build_controls = stac92xx_build_controls,
+ .build_pcms = stac92xx_build_pcms,
+ .init = stac92xx_init,
+ .free = stac92xx_free,
+ .unsol_event = stac92xx_unsol_event,
+#ifdef SND_HDA_NEEDS_RESUME
+ .suspend = stac92hd71xx_suspend,
+ .resume = stac92hd71xx_resume,
+#endif
+};
+/* JPA end of old code */
+
+
static struct hda_input_mux stac92hd73xx_dmux = {
.num_items = 4,
.items = {
@@ -4830,6 +5038,282 @@
return 0;
}
+static int stac92hd71bxx_connected_ports(struct hda_codec *codec,
+ hda_nid_t *nids, int num_nids)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx, num;
+ unsigned int def_conf;
+
+ for (num = 0; num < num_nids; num++) {
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == nids[num])
+ break;
+ if (idx >= spec->num_pins)
+ break;
+ def_conf = get_defcfg_connect(spec->pin_configs[idx]);
+ if (def_conf == AC_JACK_PORT_NONE)
+ break;
+ }
+ return num;
+}
+
+static int stac92hd71bxx_connected_smuxes(struct hda_codec *codec,
+ hda_nid_t dig0pin)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx;
+
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == dig0pin)
+ break;
+ if ((idx + 2) >= spec->num_pins)
+ return 0;
+
+ /* dig1pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+1]) != AC_JACK_PORT_NONE)
+ return 2;
+
+ /* dig0pin + dig2pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+2]) != AC_JACK_PORT_NONE)
+ return 2;
+ if (get_defcfg_connect(spec->pin_configs[idx]) != AC_JACK_PORT_NONE)
+ return 1;
+ else
+ return 0;
+}
+
+static struct hda_input_mux stac92hd71b5_dmux = {
+ .num_items = 3,
+ .items = {
+ { "Analog Inputs", 0x00 },
+ { "Digital Mic 1", 0x02 },
+ { "Digital Mic 2", 0x03 },
+ }
+};
+
+static int patch_stac92hd71b5(struct hda_codec *codec)
+{
+ struct sigmatel_spec *spec;
+ int err = 0;
+
+ spec = kzalloc(sizeof(*spec), GFP_KERNEL);
+ if (spec == NULL)
+ return -ENOMEM;
+
+ codec->spec = spec;
+ codec->patch_ops = stac92xx_patch_ops;
+ spec->num_pins = ARRAY_SIZE(stac92hd71b5_pin_nids);
+ spec->pin_nids = stac92hd71b5_pin_nids;
+
+ memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
+ sizeof(stac92hd71b5_dmux));
+ spec->board_config = snd_hda_check_board_config(codec,
+ STAC_92HD71B5_MODELS,
+ stac92hd71b5_models,
+ stac92hd71b5_cfg_tbl);
+again:
+ if (spec->board_config < 0) {
+ snd_printdd(KERN_INFO "hda_codec: Unknown model for"
+ " STAC92HD71B5, using BIOS defaults\n");
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else {
+ spec->pin_configs = stac92hd71b5_brd_tbl[spec->board_config];
+ stac92xx_set_config_regs(codec);
+ }
+
+ if (spec->board_config > STAC_92HD71B5_REF) {
+ /* GPIO0 = EAPD */
+ spec->gpio_mask = 0x01;
+ spec->gpio_dir = 0x01;
+ spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
+ }
+
+ spec->mixer = stac92hd71bxx_mixer;
+ spec->init = stac92hd71bxx_core_init;
+ codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+
+ spec->num_pwrs = 0;
+ spec->powerdown_adcs = 1;
+ spec->digbeep_nid = 0x26;
+
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd71bxx_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ if (spec->num_dmics) {
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->dinput_mux = &spec->private_dimux;
+ spec->private_dimux.num_items += spec->num_dmics -
+ (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
+ }
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
+ spec->multiout.num_dacs = 1;
+ spec->multiout.hp_nid = 0x11;
+ spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
+
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
+ if (!err) {
+ if (spec->board_config < 0) {
+ printk(KERN_WARNING "hda_codec: No auto-config is "
+ "available, default to model=ref\n");
+ spec->board_config = STAC_92HD71B5_REF;
+ goto again;
+ }
+ err = -EINVAL;
+ }
+
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+
+ return 0;
+}
+
+static struct hda_input_mux stac92hd75b_5port_dmux = {
+ .num_items = 3,
+ .items = {
+ { "Analog Inputs", 0x00 },
+ { "Mixer", 0x01 },
+ { "Digital Mic 1", 0x02 },
+ }
+};
+
+static int patch_stac92hd75b_5port(struct hda_codec *codec)
+{
+ struct sigmatel_spec *spec;
+ int err = 0;
+
+ spec = kzalloc(sizeof(*spec), GFP_KERNEL);
+ if (spec == NULL)
+ return -ENOMEM;
+
+ codec->spec = spec;
+ codec->patch_ops = stac92xx_patch_ops;
+ spec->num_pins = ARRAY_SIZE(stac92hd75b_5port_pin_nids);
+ spec->pin_nids = stac92hd75b_5port_pin_nids;
+
+ memcpy(&spec->private_dimux, &stac92hd75b_5port_dmux,
+ sizeof(stac92hd75b_5port_dmux));
+ spec->board_config = snd_hda_check_board_config(codec,
+ STAC_92HD75B_5PORT_MODELS,
+ stac92hd75b_5port_models,
+ stac92hd75b_5port_cfg_tbl);
+again:
+ if (spec->board_config < 0) {
+ snd_printdd(KERN_INFO "hda_codec: Unknown model for"
+ " STAC92HD75B_5PORT, using BIOS defaults\n");
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else {
+ spec->pin_configs = stac92hd75b_5port_brd_tbl[spec->board_config];
+ if (!spec->pin_configs) {
+ err = stac92xx_save_bios_config_regs(codec);
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+ spec->pin_configs = spec->bios_pin_configs;
+ } else
+ stac92xx_set_config_regs(codec);
+ }
+
+ if (spec->board_config > STAC_92HD75B_5PORT_REF) {
+ /* GPIO0 = EAPD */
+ spec->gpio_mask = 0x01;
+ spec->gpio_dir = 0x01;
+ spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
+ }
+
+ if (spec->board_config == STAC_HP_M4) {
+ /* Enable VREF power saving on GPIO1 detect */
+ snd_hda_codec_write_cache(codec, codec->afg, 0,
+ AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
+ snd_hda_codec_write_cache(codec, codec->afg, 0,
+ AC_VERB_SET_UNSOLICITED_ENABLE,
+ (AC_USRSP_EN | STAC_VREF_EVENT | 0x01));
+ spec->gpio_mask |= 0x02;
+ stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
+ stac92xx_auto_set_pinctl(codec, 0x0e,
+ AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
+ spec->pin_configs[4] = 0x01813040;
+ }
+ if ((codec->revision_id & 0xf) == 0 ||
+ (codec->revision_id & 0xf) == 1) {
+#ifdef SND_HDA_NEEDS_RESUME
+ codec->patch_ops = stac92hd71bxx_patch_ops;
+#endif
+ spec->stream_delay = 40; /* 40 milliseconds */
+ }
+
+ spec->mixer = stac92hd71bxx_analog_mixer;
+ spec->dinput_mux = &spec->private_dimux;
+ spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
+ codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+
+ spec->num_pwrs = 0;
+ spec->powerdown_adcs = 1;
+ spec->digbeep_nid = 0x26;
+
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd75b_5port_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd75b_5port_dmic_nids,
+ STAC92HD75B_5PORT_NUM_DMICS);
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
+ spec->multiout.num_dacs = 1;
+ spec->multiout.hp_nid = 0x11;
+ spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
+ spec->private_dimux.num_items += spec->num_dmics -
+ (ARRAY_SIZE(stac92hd75b_5port_dmic_nids) - 1);
+
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
+ if (!err) {
+ if (spec->board_config < 0) {
+ printk(KERN_WARNING "hda_codec: No auto-config is "
+ "available, default to model=ref\n");
+ spec->board_config = STAC_92HD75B_5PORT_REF;
+ goto again;
+ }
+ err = -EINVAL;
+ }
+
+ if (err < 0) {
+ stac92xx_free(codec);
+ return err;
+ }
+
+ return 0;
+}
+
static struct hda_input_mux stac92hd71bxx_dmux = {
.num_items = 4,
.items = {
@@ -4852,10 +5336,12 @@
codec->spec = spec;
codec->patch_ops = stac92xx_patch_ops;
spec->num_pins = ARRAY_SIZE(stac92hd71bxx_pin_nids);
- spec->num_pwrs = ARRAY_SIZE(stac92hd71bxx_pwr_nids);
spec->pin_nids = stac92hd71bxx_pin_nids;
- memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
- sizeof(stac92hd71bxx_dmux));
+
+ /* On 92HD75B3/92HD75B4 0x27 isn't a pin nid */
+ if (codec->vendor_id == 0x111d7603)
+ spec->num_pins--;
+
spec->board_config = snd_hda_check_board_config(codec,
STAC_92HD71BXX_MODELS,
stac92hd71bxx_models,
@@ -4875,112 +5361,73 @@
if (spec->board_config > STAC_92HD71BXX_REF) {
/* GPIO0 = EAPD */
+/* JPA start of patch from Herton Ronaldo, manually applied */
spec->gpio_mask = 0x01;
spec->gpio_dir = 0x01;
spec->gpio_data = 0x01;
+ spec->eapd_mask = 0x01; /* needed? */
+ spec->eapd_switch = 1; /* needed? */
}
+ spec->mux_nids = stac92hd71bxx_mux_nids;
+ spec->adc_nids = stac92hd71bxx_adc_nids;
+ spec->dmic_nids = stac92hd71bxx_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+ spec->smux_nids = stac92hd71bxx_smux_nids;
+ spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
+ spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
+
switch (codec->vendor_id) {
- case 0x111d76b6: /* 4 Port without Analog Mixer */
- case 0x111d76b7:
case 0x111d76b4: /* 6 Port without Analog Mixer */
case 0x111d76b5:
+ memcpy(&spec->private_dimux, &stac92hd71b5_dmux,
+ sizeof(stac92hd71b5_dmux));
+ if (spec->num_dmics) {
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->dinput_mux = &spec->private_dimux;
+ }
spec->mixer = stac92hd71bxx_mixer;
spec->init = stac92hd71bxx_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
break;
- case 0x111d7608: /* 5 Port with Analog Mixer */
- switch (spec->board_config) {
- case STAC_HP_M4:
- /* Enable VREF power saving on GPIO1 detect */
- err = stac_add_event(spec, codec->afg,
- STAC_VREF_EVENT, 0x02);
- if (err < 0)
- return err;
- snd_hda_codec_write_cache(codec, codec->afg, 0,
- AC_VERB_SET_GPIO_UNSOLICITED_RSP_MASK, 0x02);
- snd_hda_codec_write_cache(codec, codec->afg, 0,
- AC_VERB_SET_UNSOLICITED_ENABLE,
- AC_USRSP_EN | err);
- spec->gpio_mask |= 0x02;
- break;
- }
- if ((codec->revision_id & 0xf) == 0 ||
- (codec->revision_id & 0xf) == 1)
- spec->stream_delay = 40; /* 40 milliseconds */
-
- /* no output amps */
- spec->num_pwrs = 0;
- spec->mixer = stac92hd71bxx_analog_mixer;
- spec->dinput_mux = &spec->private_dimux;
-
- /* disable VSW */
- spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
- stac_change_pin_config(codec, 0xf, 0x40f000f0);
- break;
case 0x111d7603: /* 6 Port with Analog Mixer */
- if ((codec->revision_id & 0xf) == 1)
+ if ((codec->revision_id & 0xf) == 1) {
+#ifdef SND_HDA_NEEDS_RESUME
+ codec->patch_ops = stac92hd71bxx_patch_ops; /* JPA guessed code */
+#endif
spec->stream_delay = 40; /* 40 milliseconds */
-
- /* no output amps */
- spec->num_pwrs = 0;
+ }
/* fallthru */
default:
+ memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
+ sizeof(stac92hd71bxx_dmux));
spec->dinput_mux = &spec->private_dimux;
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
spec->mixer = stac92hd71bxx_analog_mixer;
spec->init = stac92hd71bxx_analog_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
}
- spec->aloopback_mask = 0x50;
- spec->aloopback_shift = 0;
-
+ spec->num_pwrs = 0;
spec->powerdown_adcs = 1;
spec->digbeep_nid = 0x26;
- spec->mux_nids = stac92hd71bxx_mux_nids;
- spec->adc_nids = stac92hd71bxx_adc_nids;
- spec->dmic_nids = stac92hd71bxx_dmic_nids;
- spec->dmux_nids = stac92hd71bxx_dmux_nids;
- spec->smux_nids = stac92hd71bxx_smux_nids;
- spec->pwr_nids = stac92hd71bxx_pwr_nids;
- spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
- spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
-
- switch (spec->board_config) {
- case STAC_HP_M4:
- /* enable internal microphone */
- stac_change_pin_config(codec, 0x0e, 0x01813040);
- stac92xx_auto_set_pinctl(codec, 0x0e,
- AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
- /* fallthru */
- case STAC_DELL_M4_2:
- spec->num_dmics = 0;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- case STAC_DELL_M4_1:
- case STAC_DELL_M4_3:
- spec->num_dmics = 1;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- default:
- spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
- spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
- spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
- };
-
- spec->multiout.dac_nids = spec->dac_nids;
- if (spec->dinput_mux)
- spec->private_dimux.num_items +=
+ spec->multiout.num_dacs = 1;
+ spec->multiout.hp_nid = 0x11;
+ spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
+ spec->private_dimux.num_items +=
spec->num_dmics -
(ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
- err = stac92xx_parse_auto_config(codec, 0x21, 0x23);
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
if (!err) {
if (spec->board_config < 0) {
printk(KERN_WARNING "hda_codec: No auto-config is "
+/* JPA en dof patch from Herton Ronaldo, manually applied */
"available, default to model=ref\n");
spec->board_config = STAC_92HD71BXX_REF;
goto again;
@@ -4996,7 +5443,7 @@
codec->proc_widget_hook = stac92hd7x_proc_hook;
return 0;
-};
+}
static int patch_stac922x(struct hda_codec *codec)
{
@@ -5616,10 +6063,10 @@
{ .id = 0x838476a5, .name = "STAC9255D", .patch = patch_stac9205 },
{ .id = 0x838476a6, .name = "STAC9254", .patch = patch_stac9205 },
{ .id = 0x838476a7, .name = "STAC9254D", .patch = patch_stac9205 },
- { .id = 0x111d7603, .name = "92HD75B3X5", .patch = patch_stac92hd71bxx},
- { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx},
- { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx},
- { .id = 0x111d7608, .name = "92HD75B2X5", .patch = patch_stac92hd71bxx},
+ { .id = 0x111d7603, .name = "92HD75B3/4", .patch = patch_stac92hd71bxx },
+ { .id = 0x111d7604, .name = "92HD83C1X5", .patch = patch_stac92hd83xxx },
+ { .id = 0x111d7605, .name = "92HD81B1X5", .patch = patch_stac92hd83xxx },
+ { .id = 0x111d7608, .name = "92HD75B1/2", .patch = patch_stac92hd75b_5port },
{ .id = 0x111d7674, .name = "92HD73D1X5", .patch = patch_stac92hd73xx },
{ .id = 0x111d7675, .name = "92HD73C1X5", .patch = patch_stac92hd73xx },
{ .id = 0x111d7676, .name = "92HD73E1X5", .patch = patch_stac92hd73xx },
@@ -5629,8 +6076,8 @@
{ .id = 0x111d76b3, .name = "92HD71B7X", .patch = patch_stac92hd71bxx },
{ .id = 0x111d76b4, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
{ .id = 0x111d76b5, .name = "92HD71B6X", .patch = patch_stac92hd71bxx },
- { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
- { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71bxx },
+ { .id = 0x111d76b6, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
+ { .id = 0x111d76b7, .name = "92HD71B5X", .patch = patch_stac92hd71b5 },
{} /* terminator */
};
--- alsa-driver-1.0.19/alsa-kernel/pci/hda/hda_intel.c.old 2009-01-19 12:08:58.000000000 +0100
+++ alsa-driver-1.0.19/alsa-kernel/pci/hda/hda_intel.c 2009-02-03 09:40:11.000000000 +0100
@@ -2049,6 +2049,30 @@
}
/*
+ * white/black-listing for enable_msi
+ */
+static struct snd_pci_quirk msi_list[] __devinitdata = {
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4, "HP dv7", 0x01),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc, "HP dv7", 0x01),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd, "HP dv7", 0x01),
+ {}
+};
+
+static void __devinit check_msi(struct azx *chip)
+{
+ const struct snd_pci_quirk *q;
+
+ q = snd_pci_quirk_lookup(chip->pci, msi_list);
+ if (q) {
+ printk(KERN_INFO
+ "hda_intel: enable_msi set to 0x%x "
+ "for device %04x:%04x\n",
+ q->value, q->subvendor, q->subdevice);
+ enable_msi = q->value;
+ }
+}
+
+/*
* white/black-listing for position_fix
*/
static struct snd_pci_quirk position_fix_list[] __devinitdata = {
@@ -2151,6 +2175,7 @@
chip->pci = pci;
chip->irq = -1;
chip->driver_type = driver_type;
+ check_msi(chip);
chip->msi = enable_msi;
chip->dev_index = dev;
INIT_WORK(&chip->irq_pending_work, azx_irq_pending_work);
[-- Attachment #3: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-03 13:49 ` Jean-Pierre André
@ 2009-02-04 17:01 ` Jean-Pierre André
2009-02-04 17:09 ` Takashi Iwai
2009-02-04 17:49 ` Herton Ronaldo Krzesinski
0 siblings, 2 replies; 36+ messages in thread
From: Jean-Pierre André @ 2009-02-04 17:01 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski; +Cc: tiwai, alsa-devel, tim.barnette
Hi Herton,
I have identified why applying your patch broke the sound worse on my
computer, by reverting each individual modification until the sound
comes back. It has not brought overall improvements for me, but this
might help you getting it right.
On my computer, the main problem is an IRQ one, which I knew you did
not address, but I still wanted to know if something would improve
(see below)
Jean-Pierre André wrote:
> Hi Herton,
>
> Thank you for trying to sort his out,
>
> Herton Ronaldo Krzesinski wrote:
>> Em Sábado 31 Janeiro 2009, às 05:52:19, Jean-Pierre André escreveu:
>>
>>> Hi,
>>>
>>>
>>>> Hi all, I have an HP DV4 1155-SE, I've been unable to get sound
>>>> working
>>>> through the speakers, although it does work through the headhpones.
>>>> I ran
>>>> alsa-.upgrade which downloaded compiled, and installed 1.0.19 -
>>>> still no
>>>> luck.
>>>>
>>> I have the same IDT codec 92HD71B7X on another
>>> HP DV4 model, and I have tracked the problem to be
>>> the kernel configuring IRQ 22 through the APIC, but
>>> interrupts triggerring IRQ 20 (on kernel 2.6.27 and
>>> alsa 1.0.19). It would be interesting if you could
>>> confirm this by analyzing /proc/interrupts.
>>>
>>> The workarounds I know of are :
>>> - adding irqpoll to the boot options,
>>> - or adding noapic to the boot options,
>>> - using mplayer to play music.
>>>
>>> There are with option "snd-hda-intel model=hp-m4"
>>> (this option is for HP DV5/DV7, but HP DV4
>>> is probably different)
>>>
>>> I have not enough knowledge to tell where the problem
>>> lies : kernel, apic, alsa.
>>>
>>
>> It looks like some of these HP laptops have some sort of IRQ issue
>> indeed, to me it was reported that enabling pci MSI (both system wide
>> and with enable_msi=1 given to snd-hda-intel) cured issues in some
>> cases, along with some changes to sigmatel codec handling code in
>> snd-hda-intel
>
> Thank you for your suggested patches. I had some difficulties in
> applying them as your reference version is not from the lasted build.
> (for instance from alsa-driver-1.0.19.0.g5aa59.6.gb162b.tar.bz2)
> Actually, to get patch_sigmatel to compile, I had to reintegrate
> old deprecated code. Attached are the patches I really applied.
>
> And the result is worse than before : no sound at all, using option
> "model hp-m4-2", as I see in the patch that this was designed for
> my sound device (subsystem id 0x30f7). I am also using option
> enable_msi=1.
Your patch contained the following, mostly deleting code which was
replaced :
- switch (spec->board_config) {
- case STAC_HP_M4:
- /* enable internal microphone */
- stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
- stac92xx_auto_set_pinctl(codec, 0x0e,
- AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
- /* fallthru */
- case STAC_DELL_M4_2:
- spec->num_dmics = 0;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- case STAC_DELL_M4_1:
- case STAC_DELL_M4_3:
- spec->num_dmics = 1;
- spec->num_smuxes = 0;
- spec->num_dmuxes = 0;
- break;
- default:
- spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
- spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
- spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
- };
spec->multiout.num_dacs = 1;
spec->multiout.hp_nid = 0x11;
spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
- if (spec->dinput_mux)
- spec->private_dimux.num_items +=
+ spec->private_dimux.num_items +=
spec->num_dmics -
(ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
The main bad thing is the following line which is indicated as
unchanged, but which does not appear in alsa 1.0.19, so I cannot
tell if this line is wrong by itself or if this line requires some
other code not present in alsa 1.0.19. With this line present I
get no sound at all :
spec->multiout.num_dacs = 1;
The second point is you have deleted and not replaced the
following :
- /* enable internal microphone */
- stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
- stac92xx_auto_set_pinctl(codec, 0x0e,
- AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
This line is required to get a PCM control in the sound volume
controls. It is also related to getting the following in the syslog :
Line In at Ext Rear Jack as /devices/pci0000:00/0000:00:1b.0/input/input61
To me, "internal microphone", "PCM control" and "Line In at Ext Rear Jack"
are different things (and in my computer there is no rear jack !), so
there must be something wrong in the configuration.
With these two changes to your patch, I get the same results as with
alsa 1.0.19.
This was tested on a HP dv4-1115ef, with a sound device identified as :
Codec: IDT 92HD71B7X
Codec: Generic 10de ID 3
vendor id : 111d76b2
subsyst id 103c30f7
revis id 100302
Regards
Jean-Pierre
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 17:01 ` Jean-Pierre André
@ 2009-02-04 17:09 ` Takashi Iwai
2009-02-04 17:37 ` Jean-Pierre André
2009-02-04 17:40 ` Herton Ronaldo Krzesinski
2009-02-04 17:49 ` Herton Ronaldo Krzesinski
1 sibling, 2 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-04 17:09 UTC (permalink / raw)
To: Jean-Pierre André
Cc: alsa-devel, tim.barnette, Herton Ronaldo Krzesinski
At Wed, 04 Feb 2009 18:01:26 +0100,
Jean-Pierre André wrote:
>
> Hi Herton,
>
> I have identified why applying your patch broke the sound worse on my
> computer, by reverting each individual modification until the sound
> comes back. It has not brought overall improvements for me, but this
> might help you getting it right.
Oh well.
Herton, could you rebase the patch against the latest sound tree?
The patch rejects awfully, so hard to test...
> On my computer, the main problem is an IRQ one, which I knew you did
> not address, but I still wanted to know if something would improve
> (see below)
You can pass enable_msi=1 option instead of patching hda_intel.c.
If it doesn't solve the IRQ problem, it must be in a pretty deep level.
> This was tested on a HP dv4-1115ef, with a sound device identified as :
>
> Codec: IDT 92HD71B7X
> Codec: Generic 10de ID 3
Hm, you didn't set CONFIG_SND_HDA_CODEC_NVHDMI=y?
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 17:09 ` Takashi Iwai
@ 2009-02-04 17:37 ` Jean-Pierre André
2009-02-04 17:40 ` Herton Ronaldo Krzesinski
1 sibling, 0 replies; 36+ messages in thread
From: Jean-Pierre André @ 2009-02-04 17:37 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, tim.barnette, Herton Ronaldo Krzesinski
Hi Takashi,
Takashi Iwai wrote:
> At Wed, 04 Feb 2009 18:01:26 +0100,
> Jean-Pierre André wrote:
>
>> On my computer, the main problem is an IRQ one, which I knew you did
>> not address, but I still wanted to know if something would improve
>> (see below)
>>
>
> You can pass enable_msi=1 option instead of patching hda_intel.c.
> If it doesn't solve the IRQ problem, it must be in a pretty deep level.
>
Maybe. I just applied the suggested patches, and I was
using the option enable_msi=1. This could be redundant.
> This was tested on a HP dv4-1115ef, with a sound device identified as :
>
> Codec: IDT 92HD71B7X
> Codec: Generic 10de ID 3
>
>
> Hm, you didn't set CONFIG_SND_HDA_CODEC_NVHDMI=y?
>
Good catch. I am using a standard Fedora 10 distribution,
and I do not see the above in the .config
Are you telling me I have to recompile the kernel ? and
with an option "y" (not "m") will I have to recompile for
every ALSA release ?
Regards
Jean-Pierre
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 17:09 ` Takashi Iwai
2009-02-04 17:37 ` Jean-Pierre André
@ 2009-02-04 17:40 ` Herton Ronaldo Krzesinski
2009-02-04 22:42 ` Takashi Iwai
1 sibling, 1 reply; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-04 17:40 UTC (permalink / raw)
To: alsa-devel; +Cc: Takashi Iwai, tim.barnette, Jean-Pierre André
[-- Attachment #1: Type: text/plain, Size: 1702 bytes --]
Em Quarta-feira 04 Fevereiro 2009, às 15:09:15, Takashi Iwai escreveu:
> At Wed, 04 Feb 2009 18:01:26 +0100,
>
> Jean-Pierre André wrote:
> > Hi Herton,
> >
> > I have identified why applying your patch broke the sound worse on my
> > computer, by reverting each individual modification until the sound
> > comes back. It has not brought overall improvements for me, but this
> > might help you getting it right.
>
> Oh well.
>
> Herton, could you rebase the patch against the latest sound tree?
> The patch rejects awfully, so hard to test...
I've done now the rebased/splitted patches, was slow at verifying/reviewing
things but I think it's now good. In my previous patch to me I saw that was
doing some uneeded things, also was better to reuse patch_stac92hd71bxx
instead of splitting 4port/5port support/differences away. I removed the pin
configs for HP models too, it may be wrong/uneeded or cause problems like in
this case. Find attached now three patches with splitted fixes/enhancements,
but nothing that will help with the problem here unfortunately, I thought the
previous patch with pin configs could help.
>
> > On my computer, the main problem is an IRQ one, which I knew you did
> > not address, but I still wanted to know if something would improve
> > (see below)
>
> You can pass enable_msi=1 option instead of patching hda_intel.c.
> If it doesn't solve the IRQ problem, it must be in a pretty deep level.
>
> > This was tested on a HP dv4-1115ef, with a sound device identified as :
> >
> > Codec: IDT 92HD71B7X
> > Codec: Generic 10de ID 3
>
> Hm, you didn't set CONFIG_SND_HDA_CODEC_NVHDMI=y?
>
>
> Takashi
--
[]'s
Herton
[-- Attachment #2: 0001-ALSA-hda-Additional-pin-nids-for-STAC92HD71Bx-and.patch --]
[-- Type: text/x-patch, Size: 5217 bytes --]
From 1f0c1417a9acaffe9567b3f454ccd1395f978d8b Mon Sep 17 00:00:00 2001
From: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Date: Wed, 4 Feb 2009 11:23:19 -0500
Subject: [PATCH 1/3] ALSA: hda - Additional pin nids for STAC92HD71Bx and STAC92HD75Bx codecs
Current code for STAC92HD71Bx and STAC92HD75Bx doesn't consider pin
complexes 0x20 and 0x27. Also for 4 port models, nids 0x0e and 0x0f
are vendor reserved. This commit changes code so it'll consider the
additional pin complexes for models that have it, and avoid reserved
nids to be touched on 4 port models.
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
sound/pci/hda/patch_sigmatel.c | 59 +++++++++++++++++++++++++++++-----------
1 files changed, 43 insertions(+), 16 deletions(-)
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index a7df81e..58c9ff9 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -481,10 +481,17 @@ static hda_nid_t stac92hd83xxx_pin_nids[14] = {
0x0f, 0x10, 0x11, 0x12, 0x13,
0x1d, 0x1e, 0x1f, 0x20
};
-static hda_nid_t stac92hd71bxx_pin_nids[11] = {
+
+#define STAC92HD71BXX_NUM_PINS 13
+static hda_nid_t stac92hd71bxx_pin_nids_4port[STAC92HD71BXX_NUM_PINS] = {
+ 0x0a, 0x0b, 0x0c, 0x0d, 0x00,
+ 0x00, 0x14, 0x18, 0x19, 0x1e,
+ 0x1f, 0x20, 0x27
+};
+static hda_nid_t stac92hd71bxx_pin_nids_6port[STAC92HD71BXX_NUM_PINS] = {
0x0a, 0x0b, 0x0c, 0x0d, 0x0e,
0x0f, 0x14, 0x18, 0x19, 0x1e,
- 0x1f,
+ 0x1f, 0x20, 0x27
};
static hda_nid_t stac927x_pin_nids[14] = {
@@ -1745,28 +1752,32 @@ static struct snd_pci_quirk stac92hd83xxx_cfg_tbl[] = {
{} /* terminator */
};
-static unsigned int ref92hd71bxx_pin_configs[11] = {
+static unsigned int ref92hd71bxx_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x02214030, 0x02a19040, 0x01a19020, 0x01014010,
0x0181302e, 0x01014010, 0x01019020, 0x90a000f0,
- 0x90a000f0, 0x01452050, 0x01452050,
+ 0x90a000f0, 0x01452050, 0x01452050, 0x00000000,
+ 0x00000000
};
-static unsigned int dell_m4_1_pin_configs[11] = {
+static unsigned int dell_m4_1_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x0421101f, 0x04a11221, 0x40f000f0, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x4f0000f0, 0x4f0000f0,
+ 0x40f000f0, 0x4f0000f0, 0x4f0000f0, 0x00000000,
+ 0x00000000
};
-static unsigned int dell_m4_2_pin_configs[11] = {
+static unsigned int dell_m4_2_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x23a1902e, 0x23014250, 0x40f000f0, 0x40f000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000
};
-static unsigned int dell_m4_3_pin_configs[11] = {
+static unsigned int dell_m4_3_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x0421101f, 0x04a11221, 0x90a70330, 0x90170110,
0x40f000f0, 0x40f000f0, 0x40f000f0, 0x90a000f0,
- 0x40f000f0, 0x044413b0, 0x044413b0,
+ 0x40f000f0, 0x044413b0, 0x044413b0, 0x00000000,
+ 0x00000000
};
static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
@@ -2311,7 +2322,9 @@ static int stac92xx_save_bios_config_regs(struct hda_codec *codec)
for (i = 0; i < spec->num_pins; i++) {
hda_nid_t nid = spec->pin_nids[i];
unsigned int pin_cfg;
-
+
+ if (!nid)
+ continue;
pin_cfg = snd_hda_codec_read(codec, nid, 0,
AC_VERB_GET_CONFIG_DEFAULT, 0x00);
snd_printdd(KERN_INFO "hda_codec: pin nid %2.2x bios pin config %8.8x\n",
@@ -2354,8 +2367,9 @@ static void stac92xx_set_config_regs(struct hda_codec *codec)
return;
for (i = 0; i < spec->num_pins; i++)
- stac92xx_set_config_reg(codec, spec->pin_nids[i],
- spec->pin_configs[i]);
+ if (spec->pin_nids[i] && spec->pin_configs[i])
+ stac92xx_set_config_reg(codec, spec->pin_nids[i],
+ spec->pin_configs[i]);
}
static int stac_save_pin_cfgs(struct hda_codec *codec, unsigned int *pins)
@@ -4952,9 +4966,21 @@ static int patch_stac92hd71bxx(struct hda_codec *codec)
codec->spec = spec;
codec->patch_ops = stac92xx_patch_ops;
- spec->num_pins = ARRAY_SIZE(stac92hd71bxx_pin_nids);
+ spec->num_pins = STAC92HD71BXX_NUM_PINS;
+ switch (codec->vendor_id) {
+ case 0x111d76b6:
+ case 0x111d76b7:
+ spec->pin_nids = stac92hd71bxx_pin_nids_4port;
+ break;
+ case 0x111d7603:
+ case 0x111d7608:
+ /* On 92HD75Bx 0x27 isn't a pin nid */
+ spec->num_pins--;
+ /* fallthrough */
+ default:
+ spec->pin_nids = stac92hd71bxx_pin_nids_6port;
+ }
spec->num_pwrs = ARRAY_SIZE(stac92hd71bxx_pwr_nids);
- spec->pin_nids = stac92hd71bxx_pin_nids;
memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
sizeof(stac92hd71bxx_dmux));
spec->board_config = snd_hda_check_board_config(codec,
@@ -5018,7 +5044,8 @@ again:
/* disable VSW */
spec->init = &stac92hd71bxx_analog_core_init[HD_DISABLE_PORTF];
unmute_init++;
- stac_change_pin_config(codec, 0xf, 0x40f000f0);
+ stac_change_pin_config(codec, 0x0f, 0x40f000f0);
+ stac_change_pin_config(codec, 0x19, 0x40f000f3);
break;
case 0x111d7603: /* 6 Port with Analog Mixer */
if ((codec->revision_id & 0xf) == 1)
--
1.6.1.2
[-- Attachment #3: 0002-ALSA-hda-Dynamic-detection-of-dmics-dmuxes-smuxes.patch --]
[-- Type: text/x-patch, Size: 6976 bytes --]
From d4e2417aa7ec8f7022143d04566ecf7f1e3d3553 Mon Sep 17 00:00:00 2001
From: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Date: Wed, 4 Feb 2009 11:34:22 -0500
Subject: [PATCH 2/3] ALSA: hda - Dynamic detection of dmics/dmuxes/smuxes in stac92hd71bxx
Detect the number of connected ports and number of smuxes dynamically,
looking at pin configs, using new introduced functions
stac92hd71bxx_connected_ports and stac92hd71bxx_connected_smuxes. Also
use proper input mux configuration for 4port and 5port models.
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
sound/pci/hda/patch_sigmatel.c | 99 +++++++++++++++++++++++++++++++++++-----
1 files changed, 87 insertions(+), 12 deletions(-)
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index 58c9ff9..c36c1c0 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -4944,7 +4944,16 @@ again:
return 0;
}
-static struct hda_input_mux stac92hd71bxx_dmux = {
+static struct hda_input_mux stac92hd71bxx_dmux_nomixer = {
+ .num_items = 3,
+ .items = {
+ { "Analog Inputs", 0x00 },
+ { "Digital Mic 1", 0x02 },
+ { "Digital Mic 2", 0x03 },
+ }
+};
+
+static struct hda_input_mux stac92hd71bxx_dmux_amixer = {
.num_items = 4,
.items = {
{ "Analog Inputs", 0x00 },
@@ -4954,11 +4963,57 @@ static struct hda_input_mux stac92hd71bxx_dmux = {
}
};
+static int stac92hd71bxx_connected_ports(struct hda_codec *codec,
+ hda_nid_t *nids, int num_nids)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx, num;
+ unsigned int def_conf;
+
+ for (num = 0; num < num_nids; num++) {
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == nids[num])
+ break;
+ if (idx >= spec->num_pins)
+ break;
+ def_conf = get_defcfg_connect(spec->pin_configs[idx]);
+ if (def_conf == AC_JACK_PORT_NONE)
+ break;
+ }
+ return num;
+}
+
+static int stac92hd71bxx_connected_smuxes(struct hda_codec *codec,
+ hda_nid_t dig0pin)
+{
+ struct sigmatel_spec *spec = codec->spec;
+ int idx;
+
+ for (idx = 0; idx < spec->num_pins; idx++)
+ if (spec->pin_nids[idx] == dig0pin)
+ break;
+ if ((idx + 2) >= spec->num_pins)
+ return 0;
+
+ /* dig1pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+1]) != AC_JACK_PORT_NONE)
+ return 2;
+
+ /* dig0pin + dig2pin case */
+ if (get_defcfg_connect(spec->pin_configs[idx+2]) != AC_JACK_PORT_NONE)
+ return 2;
+ if (get_defcfg_connect(spec->pin_configs[idx]) != AC_JACK_PORT_NONE)
+ return 1;
+ else
+ return 0;
+}
+
static int patch_stac92hd71bxx(struct hda_codec *codec)
{
struct sigmatel_spec *spec;
struct hda_verb *unmute_init = stac92hd71bxx_unmute_core_init;
int err = 0;
+ unsigned int ndmic_nids = 0;
spec = kzalloc(sizeof(*spec), GFP_KERNEL);
if (spec == NULL)
@@ -4981,8 +5036,6 @@ static int patch_stac92hd71bxx(struct hda_codec *codec)
spec->pin_nids = stac92hd71bxx_pin_nids_6port;
}
spec->num_pwrs = ARRAY_SIZE(stac92hd71bxx_pwr_nids);
- memcpy(&spec->private_dimux, &stac92hd71bxx_dmux,
- sizeof(stac92hd71bxx_dmux));
spec->board_config = snd_hda_check_board_config(codec,
STAC_92HD71BXX_MODELS,
stac92hd71bxx_models,
@@ -5007,16 +5060,32 @@ again:
spec->gpio_data = 0x01;
}
+ spec->dmic_nids = stac92hd71bxx_dmic_nids;
+ spec->dmux_nids = stac92hd71bxx_dmux_nids;
+
switch (codec->vendor_id) {
case 0x111d76b6: /* 4 Port without Analog Mixer */
case 0x111d76b7:
case 0x111d76b4: /* 6 Port without Analog Mixer */
case 0x111d76b5:
+ memcpy(&spec->private_dimux, &stac92hd71bxx_dmux_nomixer,
+ sizeof(stac92hd71bxx_dmux_nomixer));
spec->mixer = stac92hd71bxx_mixer;
spec->init = stac92hd71bxx_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ if (spec->num_dmics) {
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ spec->dinput_mux = &spec->private_dimux;
+ ndmic_nids = ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1;
+ }
break;
case 0x111d7608: /* 5 Port with Analog Mixer */
+ memcpy(&spec->private_dimux, &stac92hd71bxx_dmux_amixer,
+ sizeof(stac92hd71bxx_dmux_amixer));
+ spec->private_dimux.num_items--;
switch (spec->board_config) {
case STAC_HP_M4:
/* Enable VREF power saving on GPIO1 detect */
@@ -5046,6 +5115,12 @@ again:
unmute_init++;
stac_change_pin_config(codec, 0x0f, 0x40f000f0);
stac_change_pin_config(codec, 0x19, 0x40f000f3);
+ stac92hd71bxx_dmic_nids[STAC92HD71BXX_NUM_DMICS - 1] = 0;
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS - 1);
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ ndmic_nids = ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 2;
break;
case 0x111d7603: /* 6 Port with Analog Mixer */
if ((codec->revision_id & 0xf) == 1)
@@ -5055,10 +5130,17 @@ again:
spec->num_pwrs = 0;
/* fallthru */
default:
+ memcpy(&spec->private_dimux, &stac92hd71bxx_dmux_amixer,
+ sizeof(stac92hd71bxx_dmux_amixer));
spec->dinput_mux = &spec->private_dimux;
spec->mixer = stac92hd71bxx_analog_mixer;
spec->init = stac92hd71bxx_analog_core_init;
codec->slave_dig_outs = stac92hd71bxx_slave_dig_outs;
+ spec->num_dmics = stac92hd71bxx_connected_ports(codec,
+ stac92hd71bxx_dmic_nids,
+ STAC92HD71BXX_NUM_DMICS);
+ spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
+ ndmic_nids = ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1;
}
if (get_wcaps(codec, 0xa) & AC_WCAP_IN_AMP)
@@ -5071,13 +5153,12 @@ again:
spec->digbeep_nid = 0x26;
spec->mux_nids = stac92hd71bxx_mux_nids;
spec->adc_nids = stac92hd71bxx_adc_nids;
- spec->dmic_nids = stac92hd71bxx_dmic_nids;
- spec->dmux_nids = stac92hd71bxx_dmux_nids;
spec->smux_nids = stac92hd71bxx_smux_nids;
spec->pwr_nids = stac92hd71bxx_pwr_nids;
spec->num_muxes = ARRAY_SIZE(stac92hd71bxx_mux_nids);
spec->num_adcs = ARRAY_SIZE(stac92hd71bxx_adc_nids);
+ spec->num_smuxes = stac92hd71bxx_connected_smuxes(codec, 0x1e);
switch (spec->board_config) {
case STAC_HP_M4:
@@ -5097,17 +5178,11 @@ again:
spec->num_smuxes = 0;
spec->num_dmuxes = 0;
break;
- default:
- spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
- spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
- spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
};
spec->multiout.dac_nids = spec->dac_nids;
if (spec->dinput_mux)
- spec->private_dimux.num_items +=
- spec->num_dmics -
- (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
+ spec->private_dimux.num_items += spec->num_dmics - ndmic_nids;
err = stac92xx_parse_auto_config(codec, 0x21, 0x23);
if (!err) {
--
1.6.1.2
[-- Attachment #4: 0003-ALSA-hda-Don-t-call-stac92xx_parse_auto_config-wi.patch --]
[-- Type: text/x-patch, Size: 1082 bytes --]
From b5f5f197575db773651d8e101dff15dc9cff8484 Mon Sep 17 00:00:00 2001
From: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
Date: Wed, 4 Feb 2009 11:37:27 -0500
Subject: [PATCH 3/3] ALSA: hda - Don't call stac92xx_parse_auto_config with wrong dig_in
Don't use uneeded/wrong third parameter for stac92xx_parse_auto_config
in patch_stac92hd71bxx (no SPDIF in).
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
sound/pci/hda/patch_sigmatel.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index c36c1c0..0b00110 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -5184,7 +5184,7 @@ again:
if (spec->dinput_mux)
spec->private_dimux.num_items += spec->num_dmics - ndmic_nids;
- err = stac92xx_parse_auto_config(codec, 0x21, 0x23);
+ err = stac92xx_parse_auto_config(codec, 0x21, 0);
if (!err) {
if (spec->board_config < 0) {
printk(KERN_WARNING "hda_codec: No auto-config is "
--
1.6.1.2
[-- Attachment #5: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply related [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 17:01 ` Jean-Pierre André
2009-02-04 17:09 ` Takashi Iwai
@ 2009-02-04 17:49 ` Herton Ronaldo Krzesinski
1 sibling, 0 replies; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-04 17:49 UTC (permalink / raw)
To: alsa-devel; +Cc: tiwai, tim.barnette, Jean-Pierre André
Em Quarta-feira 04 Fevereiro 2009, às 15:01:26, Jean-Pierre André escreveu:
> Hi Herton,
>
> I have identified why applying your patch broke the sound worse on my
> computer, by reverting each individual modification until the sound
> comes back. It has not brought overall improvements for me, but this
> might help you getting it right.
Hmm yes, for now just disregard my original patch, I think the default pin
configs inside it are not right/needed for HP laptops.
>
> On my computer, the main problem is an IRQ one, which I knew you did
> not address, but I still wanted to know if something would improve
> (see below)
<snip>
> Your patch contained the following, mostly deleting code which was
> replaced :
>
> - switch (spec->board_config) {
> - case STAC_HP_M4:
> - /* enable internal microphone */
> - stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
> - stac92xx_auto_set_pinctl(codec, 0x0e,
> - AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
> - /* fallthru */
> - case STAC_DELL_M4_2:
> - spec->num_dmics = 0;
> - spec->num_smuxes = 0;
> - spec->num_dmuxes = 0;
> - break;
> - case STAC_DELL_M4_1:
> - case STAC_DELL_M4_3:
> - spec->num_dmics = 1;
> - spec->num_smuxes = 0;
> - spec->num_dmuxes = 0;
> - break;
> - default:
> - spec->num_dmics = STAC92HD71BXX_NUM_DMICS;
> - spec->num_smuxes = ARRAY_SIZE(stac92hd71bxx_smux_nids);
> - spec->num_dmuxes = ARRAY_SIZE(stac92hd71bxx_dmux_nids);
> - };
>
> spec->multiout.num_dacs = 1;
> spec->multiout.hp_nid = 0x11;
> spec->multiout.dac_nids = stac92hd71bxx_dac_nids;
> - if (spec->dinput_mux)
> - spec->private_dimux.num_items +=
> + spec->private_dimux.num_items +=
> spec->num_dmics -
> (ARRAY_SIZE(stac92hd71bxx_dmic_nids) - 1);
>
> The main bad thing is the following line which is indicated as
> unchanged, but which does not appear in alsa 1.0.19, so I cannot
> tell if this line is wrong by itself or if this line requires some
> other code not present in alsa 1.0.19. With this line present I
> get no sound at all :
>
> spec->multiout.num_dacs = 1;
>
> The second point is you have deleted and not replaced the
> following :
>
> - /* enable internal microphone */
> - stac92xx_set_config_reg(codec, 0x0e, 0x01813040);
> - stac92xx_auto_set_pinctl(codec, 0x0e,
> - AC_PINCTL_IN_EN | AC_PINCTL_VREF_80);
>
> This line is required to get a PCM control in the sound volume
> controls. It is also related to getting the following in the syslog :
>
> Line In at Ext Rear Jack as /devices/pci0000:00/0000:00:1b.0/input/input61
>
> To me, "internal microphone", "PCM control" and "Line In at Ext Rear Jack"
> are different things (and in my computer there is no rear jack !), so
> there must be something wrong in the configuration.
I don't know now if the default pin configs in my patch had something
missing/wrong, or something in current patch_sigmatel.c autoconfig code needs
this additional forced line-in to avoid hitting some case, but I thought it's
better to let away the pin configs I added. In the new patches I rebased and
posted the forced line-in is left unchanged.
>
> With these two changes to your patch, I get the same results as with
> alsa 1.0.19.
>
> This was tested on a HP dv4-1115ef, with a sound device identified as :
>
> Codec: IDT 92HD71B7X
> Codec: Generic 10de ID 3
> vendor id : 111d76b2
> subsyst id 103c30f7
> revis id 100302
>
>
> Regards
>
> Jean-Pierre
--
[]'s
Herton
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 17:40 ` Herton Ronaldo Krzesinski
@ 2009-02-04 22:42 ` Takashi Iwai
2009-02-05 2:46 ` Tim Barnette
2009-02-05 7:04 ` Takashi Iwai
0 siblings, 2 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-04 22:42 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski
Cc: alsa-devel, tim.barnette, Jean-Pierre André
At Wed, 4 Feb 2009 15:40:45 -0200,
Herton Ronaldo Krzesinski wrote:
>
> Em Quarta-feira 04 Fevereiro 2009, às 15:09:15, Takashi Iwai escreveu:
> > At Wed, 04 Feb 2009 18:01:26 +0100,
> >
> > Jean-Pierre André wrote:
> > > Hi Herton,
> > >
> > > I have identified why applying your patch broke the sound worse on my
> > > computer, by reverting each individual modification until the sound
> > > comes back. It has not brought overall improvements for me, but this
> > > might help you getting it right.
> >
> > Oh well.
> >
> > Herton, could you rebase the patch against the latest sound tree?
> > The patch rejects awfully, so hard to test...
>
> I've done now the rebased/splitted patches, was slow at verifying/reviewing
> things but I think it's now good. In my previous patch to me I saw that was
> doing some uneeded things, also was better to reuse patch_stac92hd71bxx
> instead of splitting 4port/5port support/differences away. I removed the pin
> configs for HP models too, it may be wrong/uneeded or cause problems like in
> this case. Find attached now three patches with splitted fixes/enhancements,
> but nothing that will help with the problem here unfortunately, I thought the
> previous patch with pin configs could help.
Thanks! I'll check and review these tomorrow.
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 22:42 ` Takashi Iwai
@ 2009-02-05 2:46 ` Tim Barnette
2009-02-05 7:06 ` Takashi Iwai
2009-02-05 7:04 ` Takashi Iwai
1 sibling, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-05 2:46 UTC (permalink / raw)
To: Takashi Iwai
Cc: alsa-devel, Jean-Pierre André, Herton Ronaldo Krzesinski
Thanks, Takashi. Please let us know what you discover.
On Wed, Feb 4, 2009 at 5:42 PM, Takashi Iwai <tiwai@suse.de> wrote:
> At Wed, 4 Feb 2009 15:40:45 -0200,
> Herton Ronaldo Krzesinski wrote:
> >
> > Em Quarta-feira 04 Fevereiro 2009, às 15:09:15, Takashi Iwai escreveu:
> > > At Wed, 04 Feb 2009 18:01:26 +0100,
> > >
> > > Jean-Pierre André wrote:
> > > > Hi Herton,
> > > >
> > > > I have identified why applying your patch broke the sound worse on my
> > > > computer, by reverting each individual modification until the sound
> > > > comes back. It has not brought overall improvements for me, but this
> > > > might help you getting it right.
> > >
> > > Oh well.
> > >
> > > Herton, could you rebase the patch against the latest sound tree?
> > > The patch rejects awfully, so hard to test...
> >
> > I've done now the rebased/splitted patches, was slow at
> verifying/reviewing
> > things but I think it's now good. In my previous patch to me I saw that
> was
> > doing some uneeded things, also was better to reuse patch_stac92hd71bxx
> > instead of splitting 4port/5port support/differences away. I removed the
> pin
> > configs for HP models too, it may be wrong/uneeded or cause problems like
> in
> > this case. Find attached now three patches with splitted
> fixes/enhancements,
> > but nothing that will help with the problem here unfortunately, I thought
> the
> > previous patch with pin configs could help.
>
> Thanks! I'll check and review these tomorrow.
>
>
> Takashi
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-04 22:42 ` Takashi Iwai
2009-02-05 2:46 ` Tim Barnette
@ 2009-02-05 7:04 ` Takashi Iwai
1 sibling, 0 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-05 7:04 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski
Cc: alsa-devel, tim.barnette, Jean-Pierre André
At Wed, 04 Feb 2009 23:42:44 +0100,
I wrote:
>
> At Wed, 4 Feb 2009 15:40:45 -0200,
> Herton Ronaldo Krzesinski wrote:
> >
> > Em Quarta-feira 04 Fevereiro 2009, às 15:09:15, Takashi Iwai escreveu:
> > > At Wed, 04 Feb 2009 18:01:26 +0100,
> > >
> > > Jean-Pierre André wrote:
> > > > Hi Herton,
> > > >
> > > > I have identified why applying your patch broke the sound worse on my
> > > > computer, by reverting each individual modification until the sound
> > > > comes back. It has not brought overall improvements for me, but this
> > > > might help you getting it right.
> > >
> > > Oh well.
> > >
> > > Herton, could you rebase the patch against the latest sound tree?
> > > The patch rejects awfully, so hard to test...
> >
> > I've done now the rebased/splitted patches, was slow at verifying/reviewing
> > things but I think it's now good. In my previous patch to me I saw that was
> > doing some uneeded things, also was better to reuse patch_stac92hd71bxx
> > instead of splitting 4port/5port support/differences away. I removed the pin
> > configs for HP models too, it may be wrong/uneeded or cause problems like in
> > this case. Find attached now three patches with splitted fixes/enhancements,
> > but nothing that will help with the problem here unfortunately, I thought the
> > previous patch with pin configs could help.
>
> Thanks! I'll check and review these tomorrow.
All look good, so applied now.
thanks,
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-05 2:46 ` Tim Barnette
@ 2009-02-05 7:06 ` Takashi Iwai
0 siblings, 0 replies; 36+ messages in thread
From: Takashi Iwai @ 2009-02-05 7:06 UTC (permalink / raw)
To: Tim Barnette
Cc: alsa-devel, Jean-Pierre André, Herton Ronaldo Krzesinski
At Wed, 4 Feb 2009 21:46:47 -0500,
Tim Barnette wrote:
>
> Thanks, Takashi. Please let us know what you discover.
As Herton mentioned, these patches are fixes for misc problems that
are not directly unrelated with HP dv4 issue. (Some of) HP dv4 likely
needs a fix of pin config -- or a fix of BIOS.
Did you try hda-verb command I suggested before, BTW? I don't here
any feedback about it...
thanks,
Takashi
>
> On Wed, Feb 4, 2009 at 5:42 PM, Takashi Iwai <tiwai@suse.de> wrote:
>
> At Wed, 4 Feb 2009 15:40:45 -0200,
> Herton Ronaldo Krzesinski wrote:
> >
> > Em Quarta-feira 04 Fevereiro 2009, às 15:09:15, Takashi Iwai escreveu:
> > > At Wed, 04 Feb 2009 18:01:26 +0100,
> > >
> > > Jean-Pierre André wrote:
> > > > Hi Herton,
> > > >
> > > > I have identified why applying your patch broke the sound worse on
> my
> > > > computer, by reverting each individual modification until the sound
> > > > comes back. It has not brought overall improvements for me, but this
> > > > might help you getting it right.
> > >
> > > Oh well.
> > >
> > > Herton, could you rebase the patch against the latest sound tree?
> > > The patch rejects awfully, so hard to test...
> >
> > I've done now the rebased/splitted patches, was slow at verifying/
> reviewing
> > things but I think it's now good. In my previous patch to me I saw that
> was
> > doing some uneeded things, also was better to reuse patch_stac92hd71bxx
> > instead of splitting 4port/5port support/differences away. I removed the
> pin
> > configs for HP models too, it may be wrong/uneeded or cause problems
> like in
> > this case. Find attached now three patches with splitted fixes/
> enhancements,
> > but nothing that will help with the problem here unfortunately, I
> thought the
> > previous patch with pin configs could help.
>
> Thanks! I'll check and review these tomorrow.
>
> Takashi
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-02 15:25 ` Takashi Iwai
2009-02-02 16:26 ` Tim Barnette
@ 2009-02-13 19:16 ` Tim Barnette
2009-02-13 19:22 ` Tim Barnette
1 sibling, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-13 19:16 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Jean-Pierre André
Takashi, I was able to build hda-verb and when I executed the command below,
it responded with:
nid=0xd, verb=0x707, param=0x40
value=0x0
On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> At Mon, 2 Feb 2009 10:17:03 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I made this change and rebooted.
> >
> > I noticed right away the mute light is no longer on... but still no sound
> > through speakers, only headphones..
> >
> > /sys/module/snd_hda_intel/parameters/model
> > contains
> > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> >
> > attached is the alsa-info.txt you requested..
>
> Did you try the latest alsa-driver snapshot?
>
> If it still doesn't work, I guess this is a BIOS problem.
> The other HP dv laptops show the widget 0x0d as the speaker while
> yours is unused.
>
> Try to run:
> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>
>
> Takashi
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-13 19:16 ` Tim Barnette
@ 2009-02-13 19:22 ` Tim Barnette
2009-02-14 10:24 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-13 19:22 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel, Jean-Pierre André
..And it worked! I now have sound! Can you tell me what I actually did
here?
On Fri, Feb 13, 2009 at 2:16 PM, Tim Barnette <tim.barnette@gmail.com>wrote:
> Takashi, I was able to build hda-verb and when I executed the command
> below, it responded with:
> nid=0xd, verb=0x707, param=0x40
> value=0x0
>
>
> On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
>
>> At Mon, 2 Feb 2009 10:17:03 -0500,
>> Tim Barnette wrote:
>> >
>> > Thanks, Takashi. I made this change and rebooted.
>> >
>> > I noticed right away the mute light is no longer on... but still no
>> sound
>> > through speakers, only headphones..
>> >
>> > /sys/module/snd_hda_intel/parameters/model
>> > contains
>> > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
>> >
>> > attached is the alsa-info.txt you requested..
>>
>> Did you try the latest alsa-driver snapshot?
>>
>> If it still doesn't work, I guess this is a BIOS problem.
>> The other HP dv laptops show the widget 0x0d as the speaker while
>> yours is unused.
>>
>> Try to run:
>> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>>
>>
>> Takashi
>>
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-13 19:22 ` Tim Barnette
@ 2009-02-14 10:24 ` Takashi Iwai
2009-02-14 19:13 ` Herton Ronaldo Krzesinski
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-14 10:24 UTC (permalink / raw)
To: Tim Barnette
Cc: alsa-devel, Jean-Pierre André, Herton Ronaldo Krzesinski
At Fri, 13 Feb 2009 14:22:00 -0500,
Tim Barnette wrote:
>
> ..And it worked! I now have sound! Can you tell me what I actually did here?
The problem was that your BIOS didn't set the correct default pin
configuration. The driver doesn't know which pin should be used for
the speaker output, as a consequence, it's set as INPUT.
Now you set it OUTPUT manually by hda-verb, and (fortunately) the
route to that pin was alive even though it wasn't declared, you get
the speaker output now.
The next step is to implement a proper pin-config to override by
the driver. This won't be much work, but hey, wait for a while.
(Or, did Herton already work on that?)
thanks,
Takashi
>
> On Fri, Feb 13, 2009 at 2:16 PM, Tim Barnette <tim.barnette@gmail.com> wrote:
>
> Takashi, I was able to build hda-verb and when I executed the command
> below, it responded with:
> nid=0xd, verb=0x707, param=0x40
> value=0x0
>
> On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
>
> At Mon, 2 Feb 2009 10:17:03 -0500,
> Tim Barnette wrote:
> >
> > Thanks, Takashi. I made this change and rebooted.
> >
> > I noticed right away the mute light is no longer on... but still no
> sound
> > through speakers, only headphones..
> >
> > /sys/module/snd_hda_intel/parameters/model
> > contains
> > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> >
> > attached is the alsa-info.txt you requested..
>
> Did you try the latest alsa-driver snapshot?
>
> If it still doesn't work, I guess this is a BIOS problem.
> The other HP dv laptops show the widget 0x0d as the speaker while
> yours is unused.
>
> Try to run:
> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>
> Takashi
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-14 10:24 ` Takashi Iwai
@ 2009-02-14 19:13 ` Herton Ronaldo Krzesinski
2009-02-16 10:48 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-14 19:13 UTC (permalink / raw)
To: alsa-devel; +Cc: Takashi Iwai, Tim Barnette, Jean-Pierre André
[-- Attachment #1: Type: text/plain, Size: 2696 bytes --]
On Saturday 14 February 2009 08:24:15 Takashi Iwai wrote:
> At Fri, 13 Feb 2009 14:22:00 -0500,
> Tim Barnette wrote:
> >
> > ..And it worked! I now have sound! Can you tell me what I actually did here?
>
> The problem was that your BIOS didn't set the correct default pin
> configuration. The driver doesn't know which pin should be used for
> the speaker output, as a consequence, it's set as INPUT.
> Now you set it OUTPUT manually by hda-verb, and (fortunately) the
> route to that pin was alive even though it wasn't declared, you get
> the speaker output now.
>
> The next step is to implement a proper pin-config to override by
> the driver. This won't be much work, but hey, wait for a while.
>
> (Or, did Herton already work on that?)
I had added before pin configs for which source came from *.ini files of IDT
windows drivers provided by HP. But I don't know if they are at all necessary,
may be just setting config of 0x0d pin should suffice for all hp-dv5 models,
as all of them have speaker on 0x0d from all reports and also looking at the
*.ini files.
I have three patches, you can choose one of them :), see attached. The first
one is my previous pin configs work "let's set for all cases the pin configs
based on *.ini files", the others are same smaller change/less intrusive that
instead just deals with this hp dv4 case.
>
>
> thanks,
>
> Takashi
>
> >
> > On Fri, Feb 13, 2009 at 2:16 PM, Tim Barnette <tim.barnette@gmail.com> wrote:
> >
> > Takashi, I was able to build hda-verb and when I executed the command
> > below, it responded with:
> > nid=0xd, verb=0x707, param=0x40
> > value=0x0
> >
> > On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> >
> > At Mon, 2 Feb 2009 10:17:03 -0500,
> > Tim Barnette wrote:
> > >
> > > Thanks, Takashi. I made this change and rebooted.
> > >
> > > I noticed right away the mute light is no longer on... but still no
> > sound
> > > through speakers, only headphones..
> > >
> > > /sys/module/snd_hda_intel/parameters/model
> > > contains
> > > hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> > >
> > > attached is the alsa-info.txt you requested..
> >
> > Did you try the latest alsa-driver snapshot?
> >
> > If it still doesn't work, I guess this is a BIOS problem.
> > The other HP dv laptops show the widget 0x0d as the speaker while
> > yours is unused.
> >
> > Try to run:
> > hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
> >
> > Takashi
--
[]'s
Herton
[-- Attachment #2: patch1.patch --]
[-- Type: text/x-patch, Size: 5653 bytes --]
ALSA: hda - Add STAC92HD71B* models for several HP laptops
Add hp-m4-{1,2,3,4,5} models for STAC92HD71B* codecs. Removed
model=hp-dv5, replaced by them.
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
Documentation/sound/alsa/HD-Audio-Models.txt | 5 +
sound/pci/hda/patch_sigmatel.c | 91 ++++++++++++++++++++++++---
2 files changed, 87 insertions(+), 9 deletions(-)
diff --git a/Documentation/sound/alsa/HD-Audio-Models.txt b/Documentation/sound/alsa/HD-Audio-Models.txt
index 0e52d27..0783dc1 100644
--- a/Documentation/sound/alsa/HD-Audio-Models.txt
+++ b/Documentation/sound/alsa/HD-Audio-Models.txt
@@ -339,6 +339,11 @@ STAC92HD71B*
dell-m4-2 Dell desktops
dell-m4-3 Dell desktops
hp-m4 HP dv laptops
+ hp-m4-1 HP dv laptops
+ hp-m4-2 HP dv laptops
+ hp-m4-3 HP dv laptops
+ hp-m4-4 HP dv laptops
+ hp-m4-5 HP dv laptops
STAC92HD73*
===========
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index aeb5d21..29f3fb7 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -93,7 +93,11 @@ enum {
STAC_DELL_M4_2,
STAC_DELL_M4_3,
STAC_HP_M4,
- STAC_HP_DV5,
+ STAC_HP_M4_1,
+ STAC_HP_M4_2,
+ STAC_HP_M4_3,
+ STAC_HP_M4_4,
+ STAC_HP_M4_5,
STAC_92HD71BXX_MODELS
};
@@ -1793,13 +1797,52 @@ static unsigned int dell_m4_3_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x00000000
};
+static unsigned int hp_m4_1_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a12050, 0x40f000f0, 0x90170010,
+ 0x40f000f1, 0x0221201f, 0x40f000f2, 0x90a60040,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x00000000,
+ 0x90300041,
+};
+
+static unsigned int hp_m4_2_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x50f000f4, 0x50f000f5, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_3_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x28466060, 0x50f000f4, 0x40f000f0,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_4_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a12050, 0x90a70040, 0x90170010,
+ 0x40f000f1, 0x40f000f5, 0x40f000f2, 0x50f000f6,
+ 0x50f000f3, 0x50f000f7, 0x50f000f4, 0x28466060,
+ 0x9030005a,
+};
+
+static unsigned int hp_m4_5_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a1205e, 0x90a70070, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x50f000f1,
+ 0x50f000f3, 0x50f000f6, 0x50f000f4, 0x28466060,
+ 0x9030005a,
+};
+
static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
[STAC_92HD71BXX_REF] = ref92hd71bxx_pin_configs,
[STAC_DELL_M4_1] = dell_m4_1_pin_configs,
[STAC_DELL_M4_2] = dell_m4_2_pin_configs,
[STAC_DELL_M4_3] = dell_m4_3_pin_configs,
[STAC_HP_M4] = NULL,
- [STAC_HP_DV5] = NULL,
+ [STAC_HP_M4_1] = hp_m4_1_pin_configs,
+ [STAC_HP_M4_2] = hp_m4_2_pin_configs,
+ [STAC_HP_M4_3] = hp_m4_3_pin_configs,
+ [STAC_HP_M4_4] = hp_m4_4_pin_configs,
+ [STAC_HP_M4_5] = hp_m4_5_pin_configs,
};
static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
@@ -1808,7 +1851,11 @@ static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
[STAC_DELL_M4_2] = "dell-m4-2",
[STAC_DELL_M4_3] = "dell-m4-3",
[STAC_HP_M4] = "hp-m4",
- [STAC_HP_DV5] = "hp-dv5",
+ [STAC_HP_M4_1] = "hp-m4-1",
+ [STAC_HP_M4_2] = "hp-m4-2",
+ [STAC_HP_M4_3] = "hp-m4-3",
+ [STAC_HP_M4_4] = "hp-m4-4",
+ [STAC_HP_M4_5] = "hp-m4-5",
};
static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
@@ -1817,18 +1864,44 @@ static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
"DFI LanParty", STAC_92HD71BXX_REF),
SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101,
"DFI LanParty", STAC_92HD71BXX_REF),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x1505,
+ "unknown HP", STAC_HP_M4_1),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30de,
+ "unknown HP", STAC_HP_M4_1),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
- "HP dv5", STAC_HP_M4),
+ "HP dv5", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f3,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
- "HP dv7", STAC_HP_DV5),
+ "HP dv7", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
- "HP dv4", STAC_HP_DV5),
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f8,
+ "unknown HP", STAC_HP_M4_5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
+ "unknown HP", STAC_HP_M4_2),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
- "HP dv7", STAC_HP_M4),
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fd,
+ "unknown HP", STAC_HP_M4_2),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fe,
+ "unknown HP", STAC_HP_M4_5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30ff,
+ "unknown HP", STAC_HP_M4_4),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
- "HP dv5", STAC_HP_DV5),
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3601,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3602,
+ "unknown HP", STAC_HP_M4_3),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
- "HP dv5", STAC_HP_DV5),
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3607,
+ "unknown HP", STAC_HP_M4_4),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x360f,
+ "unknown HP", STAC_HP_M4_3),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3610,
+ "unknown HP", STAC_HP_M4_3),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
"unknown HP", STAC_HP_M4),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
[-- Attachment #3: patch2.patch --]
[-- Type: text/x-patch, Size: 2573 bytes --]
ALSA: hda - Fix speaker output on HP DV4 1155-SE
Add new model=hp-dv4 with custom pin configs which fix speaker output
in HP DV4 1155-SE laptop.
Reference: alsa-devel mailing list thread on
http://mailman.alsa-project.org/pipermail/alsa-devel/2009-February/014390.html
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
Documentation/sound/alsa/HD-Audio-Models.txt | 2 ++
sound/pci/hda/patch_sigmatel.c | 12 ++++++++++++
2 files changed, 14 insertions(+)
diff --git a/Documentation/sound/alsa/HD-Audio-Models.txt b/Documentation/sound/alsa/HD-Audio-Models.txt
index 0e52d27..df063ad 100644
--- a/Documentation/sound/alsa/HD-Audio-Models.txt
+++ b/Documentation/sound/alsa/HD-Audio-Models.txt
@@ -339,6 +339,8 @@ STAC92HD71B*
dell-m4-2 Dell desktops
dell-m4-3 Dell desktops
hp-m4 HP dv laptops
+ hp-dv4 HP dv laptops
+ hp-dv5 HP dv laptops
STAC92HD73*
===========
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index aeb5d21..e8be9f8 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -93,6 +93,7 @@ enum {
STAC_DELL_M4_2,
STAC_DELL_M4_3,
STAC_HP_M4,
+ STAC_HP_DV4,
STAC_HP_DV5,
STAC_92HD71BXX_MODELS
};
@@ -1793,12 +1794,20 @@ static unsigned int dell_m4_3_pin_configs[STAC92HD71BXX_NUM_PINS] = {
0x00000000
};
+static unsigned int stac_hp_dv4_pin_configs[STAC92HD71BXX_NUM_PINS] = {
+ 0x0221201f, 0x02a1205e, 0x40f000f1, 0x90170010,
+ 0x4080005f, 0x40f000f5, 0x40f000f2, 0x90a60070,
+ 0x50f000f3, 0x50f000f4, 0x50f000f5, 0x28466060,
+ 0x9030005a,
+};
+
static unsigned int *stac92hd71bxx_brd_tbl[STAC_92HD71BXX_MODELS] = {
[STAC_92HD71BXX_REF] = ref92hd71bxx_pin_configs,
[STAC_DELL_M4_1] = dell_m4_1_pin_configs,
[STAC_DELL_M4_2] = dell_m4_2_pin_configs,
[STAC_DELL_M4_3] = dell_m4_3_pin_configs,
[STAC_HP_M4] = NULL,
+ [STAC_HP_DV4] = stac_hp_dv4_pin_configs,
[STAC_HP_DV5] = NULL,
};
@@ -1808,6 +1817,7 @@ static const char *stac92hd71bxx_models[STAC_92HD71BXX_MODELS] = {
[STAC_DELL_M4_2] = "dell-m4-2",
[STAC_DELL_M4_3] = "dell-m4-3",
[STAC_HP_M4] = "hp-m4",
+ [STAC_HP_DV4] = "hp-dv4",
[STAC_HP_DV5] = "hp-dv5",
};
@@ -1823,6 +1833,8 @@ static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
"HP dv7", STAC_HP_DV5),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
"HP dv4", STAC_HP_DV5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
+ "HP dv4", STAC_HP_DV4),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
"HP dv7", STAC_HP_M4),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
[-- Attachment #4: patch3.patch --]
[-- Type: text/x-patch, Size: 1406 bytes --]
ALSA: hda - Fix speaker output on HP DV4 1155-SE
Force speaker pin config with model=hp-dv5 model for cases when bios
doesn't set it up properly. All reported hp laptops using model=hp-dv5
model have speaker at pin 0x0d with same config, so it's safe to add
this within hp-dv5 model.
Reference: alsa-devel mailing list thread on
http://mailman.alsa-project.org/pipermail/alsa-devel/2009-February/014390.html
Signed-off-by: Herton Ronaldo Krzesinski <herton@mandriva.com.br>
---
sound/pci/hda/patch_sigmatel.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index aeb5d21..7320059 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -1823,6 +1823,8 @@ static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
"HP dv7", STAC_HP_DV5),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
"HP dv4", STAC_HP_DV5),
+ SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
+ "HP dv7", STAC_HP_DV5),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
"HP dv7", STAC_HP_M4),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
@@ -5170,6 +5172,10 @@ again:
spec->num_smuxes = 0;
spec->num_dmuxes = 0;
break;
+ case STAC_HP_DV5:
+ stac_change_pin_config(codec, 0x0d, 0x90170010);
+ stac92xx_auto_set_pinctl(codec, 0x0d, AC_PINCTL_OUT_EN);
+ break;
};
spec->multiout.dac_nids = spec->dac_nids;
[-- Attachment #5: Type: text/plain, Size: 160 bytes --]
_______________________________________________
Alsa-devel mailing list
Alsa-devel@alsa-project.org
http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
^ permalink raw reply related [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through, speakers...]
[not found] <mailman.2709.1234557113.1965.alsa-devel@alsa-project.org>
@ 2009-02-16 5:25 ` Guy Stalnaker
2009-02-16 10:47 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Guy Stalnaker @ 2009-02-16 5:25 UTC (permalink / raw)
To: alsa-devel
Herton and Takashi,
I can confirm that compiling and installing the latest snapshot of
alsa-drivers, adding "model=hp-dv5" to /etc/modprobe.d/alsa-base, and
running hda-verb with the parameters Takashi indicates DOES result in
sound from the onboard, internal speakers on my Hewlitt Packard dv4 1225
Pavilion Entertainment PC.
The mute on headphone use does not work, but that's okay by me for now.
I think you're on the right track in diagnosing the problem and it's
solution.
Thank you very, very much for helping us. I know it'll likely be a
while before the solution actually makes it into distributions, but at
the least I can use my sound apps without having to plug my laptop into
something to hear what's playing. Kinda defeats the notion of having a
laptop if one has to keep it plugged in.
Do either of you mind if I collate notes from the posts exchanged on
alsa-devel and post them on the Ubuntu forums? There are a lot of other
HP users who have posted about the same problem. It's likely they have
no idea the resource available to them in the alsa-devel archives.
BEST regards,
Guy S.
> ------------------------------
>
> Message: 4
> Date: Fri, 13 Feb 2009 14:16:21 -0500
> From: Tim Barnette <tim.barnette@gmail.com>
> Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
> speakers...]
> To: Takashi Iwai <tiwai@suse.de>
> Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
> <jean-pierre.andre@wanadoo.fr>
> Message-ID:
> <b71cdde20902131116l4c7da119s6c51a67e37371ebe@mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> Takashi, I was able to build hda-verb and when I executed the command below,
> it responded with:
> nid=0xd, verb=0x707, param=0x40
> value=0x0
>
> On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
>
>> At Mon, 2 Feb 2009 10:17:03 -0500,
>> Tim Barnette wrote:
>>> Thanks, Takashi. I made this change and rebooted.
>>>
>>> I noticed right away the mute light is no longer on... but still no sound
>>> through speakers, only headphones..
>>>
>>> /sys/module/snd_hda_intel/parameters/model
>>> contains
>>> hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
>>>
>>> attached is the alsa-info.txt you requested..
>> Did you try the latest alsa-driver snapshot?
>>
>> If it still doesn't work, I guess this is a BIOS problem.
>> The other HP dv laptops show the widget 0x0d as the speaker while
>> yours is unused.
>>
>> Try to run:
>> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>>
>>
>> Takashi
>>
>
>
> ------------------------------
>
> Message: 5
> Date: Fri, 13 Feb 2009 14:22:00 -0500
> From: Tim Barnette <tim.barnette@gmail.com>
> Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
> speakers...]
> To: Takashi Iwai <tiwai@suse.de>
> Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
> <jean-pierre.andre@wanadoo.fr>
> Message-ID:
> <b71cdde20902131122q16eb7e44u92daf2a4c9500bd0@mail.gmail.com>
> Content-Type: text/plain; charset=ISO-8859-1
>
> ..And it worked! I now have sound! Can you tell me what I actually did
> here?
--
Guy Stalnaker, I2@DOIT, jstalnak@wisc.edu
1210 West Dayton Street, Room 3209 CSS, Madison WI 53706
work 608.263.8035, cell 608.235.4718, fax 608.265.6681
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through, speakers...]
2009-02-16 5:25 ` [Fwd: HP DV4 1155 SE - No Sound through, speakers...] Guy Stalnaker
@ 2009-02-16 10:47 ` Takashi Iwai
2009-02-18 4:10 ` Guy Stalnaker
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-16 10:47 UTC (permalink / raw)
To: Guy Stalnaker; +Cc: alsa-devel
At Sun, 15 Feb 2009 23:25:15 -0600,
Guy Stalnaker wrote:
>
> Herton and Takashi,
>
> I can confirm that compiling and installing the latest snapshot of
> alsa-drivers, adding "model=hp-dv5" to /etc/modprobe.d/alsa-base, and
> running hda-verb with the parameters Takashi indicates DOES result in
> sound from the onboard, internal speakers on my Hewlitt Packard dv4 1225
> Pavilion Entertainment PC.
>
> The mute on headphone use does not work, but that's okay by me for now.
Good. Could you try the very latest alsa-driver-snapshot tarball?
Herton's patch is already included. If your PCI SSID matches, it
should work as is. If not, please run alsa-info.sh with --no-upload
option and attach the generated file.
> I think you're on the right track in diagnosing the problem and it's
> solution.
>
> Thank you very, very much for helping us. I know it'll likely be a
> while before the solution actually makes it into distributions, but at
> the least I can use my sound apps without having to plug my laptop into
> something to hear what's playing. Kinda defeats the notion of having a
> laptop if one has to keep it plugged in.
>
> Do either of you mind if I collate notes from the posts exchanged on
> alsa-devel and post them on the Ubuntu forums? There are a lot of other
> HP users who have posted about the same problem. It's likely they have
> no idea the resource available to them in the alsa-devel archives.
Sure, it's an open mailing list, so feel free to cite the thread.
Takashi
> BEST regards,
>
> Guy S.
>
> > ------------------------------
> >
> > Message: 4
> > Date: Fri, 13 Feb 2009 14:16:21 -0500
> > From: Tim Barnette <tim.barnette@gmail.com>
> > Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
> > speakers...]
> > To: Takashi Iwai <tiwai@suse.de>
> > Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
> > <jean-pierre.andre@wanadoo.fr>
> > Message-ID:
> > <b71cdde20902131116l4c7da119s6c51a67e37371ebe@mail.gmail.com>
> > Content-Type: text/plain; charset=ISO-8859-1
> >
> > Takashi, I was able to build hda-verb and when I executed the command below,
> > it responded with:
> > nid=0xd, verb=0x707, param=0x40
> > value=0x0
> >
> > On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
> >
> >> At Mon, 2 Feb 2009 10:17:03 -0500,
> >> Tim Barnette wrote:
> >>> Thanks, Takashi. I made this change and rebooted.
> >>>
> >>> I noticed right away the mute light is no longer on... but still no sound
> >>> through speakers, only headphones..
> >>>
> >>> /sys/module/snd_hda_intel/parameters/model
> >>> contains
> >>> hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
> >>>
> >>> attached is the alsa-info.txt you requested..
> >> Did you try the latest alsa-driver snapshot?
> >>
> >> If it still doesn't work, I guess this is a BIOS problem.
> >> The other HP dv laptops show the widget 0x0d as the speaker while
> >> yours is unused.
> >>
> >> Try to run:
> >> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
> >>
> >>
> >> Takashi
> >>
> >
> >
> > ------------------------------
> >
> > Message: 5
> > Date: Fri, 13 Feb 2009 14:22:00 -0500
> > From: Tim Barnette <tim.barnette@gmail.com>
> > Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
> > speakers...]
> > To: Takashi Iwai <tiwai@suse.de>
> > Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
> > <jean-pierre.andre@wanadoo.fr>
> > Message-ID:
> > <b71cdde20902131122q16eb7e44u92daf2a4c9500bd0@mail.gmail.com>
> > Content-Type: text/plain; charset=ISO-8859-1
> >
> > ..And it worked! I now have sound! Can you tell me what I actually did
> > here?
>
> --
> Guy Stalnaker, I2@DOIT, jstalnak@wisc.edu
> 1210 West Dayton Street, Room 3209 CSS, Madison WI 53706
> work 608.263.8035, cell 608.235.4718, fax 608.265.6681
> _______________________________________________
> Alsa-devel mailing list
> Alsa-devel@alsa-project.org
> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-14 19:13 ` Herton Ronaldo Krzesinski
@ 2009-02-16 10:48 ` Takashi Iwai
2009-02-16 13:21 ` Takashi Iwai
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-16 10:48 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski
Cc: alsa-devel, Tim Barnette, Jean-Pierre André
At Sat, 14 Feb 2009 17:13:55 -0200,
Herton Ronaldo Krzesinski wrote:
>
> On Saturday 14 February 2009 08:24:15 Takashi Iwai wrote:
> > At Fri, 13 Feb 2009 14:22:00 -0500,
> > Tim Barnette wrote:
> > >
> > > ..And it worked! I now have sound! Can you tell me what I actually did here?
> >
> > The problem was that your BIOS didn't set the correct default pin
> > configuration. The driver doesn't know which pin should be used for
> > the speaker output, as a consequence, it's set as INPUT.
> > Now you set it OUTPUT manually by hda-verb, and (fortunately) the
> > route to that pin was alive even though it wasn't declared, you get
> > the speaker output now.
> >
> > The next step is to implement a proper pin-config to override by
> > the driver. This won't be much work, but hey, wait for a while.
> >
> > (Or, did Herton already work on that?)
>
> I had added before pin configs for which source came from *.ini files of IDT
> windows drivers provided by HP. But I don't know if they are at all necessary,
> may be just setting config of 0x0d pin should suffice for all hp-dv5 models,
> as all of them have speaker on 0x0d from all reports and also looking at the
> *.ini files.
>
> I have three patches, you can choose one of them :), see attached. The first
> one is my previous pin configs work "let's set for all cases the pin configs
> based on *.ini files", the others are same smaller change/less intrusive that
> instead just deals with this hp dv4 case.
I took the last, the smallest one. It's not too bad to define all
models, but at this stage, I'd like rather to slim the code down.
Thanks!
Takashi
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-16 10:48 ` Takashi Iwai
@ 2009-02-16 13:21 ` Takashi Iwai
2009-02-17 19:51 ` Tim Barnette
0 siblings, 1 reply; 36+ messages in thread
From: Takashi Iwai @ 2009-02-16 13:21 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski
Cc: alsa-devel, Tim Barnette, Jean-Pierre André
At Mon, 16 Feb 2009 11:48:24 +0100,
I wrote:
>
> At Sat, 14 Feb 2009 17:13:55 -0200,
> Herton Ronaldo Krzesinski wrote:
> >
> > On Saturday 14 February 2009 08:24:15 Takashi Iwai wrote:
> > > At Fri, 13 Feb 2009 14:22:00 -0500,
> > > Tim Barnette wrote:
> > > >
> > > > ..And it worked! I now have sound! Can you tell me what I actually did here?
> > >
> > > The problem was that your BIOS didn't set the correct default pin
> > > configuration. The driver doesn't know which pin should be used for
> > > the speaker output, as a consequence, it's set as INPUT.
> > > Now you set it OUTPUT manually by hda-verb, and (fortunately) the
> > > route to that pin was alive even though it wasn't declared, you get
> > > the speaker output now.
> > >
> > > The next step is to implement a proper pin-config to override by
> > > the driver. This won't be much work, but hey, wait for a while.
> > >
> > > (Or, did Herton already work on that?)
> >
> > I had added before pin configs for which source came from *.ini files of IDT
> > windows drivers provided by HP. But I don't know if they are at all necessary,
> > may be just setting config of 0x0d pin should suffice for all hp-dv5 models,
> > as all of them have speaker on 0x0d from all reports and also looking at the
> > *.ini files.
> >
> > I have three patches, you can choose one of them :), see attached. The first
> > one is my previous pin configs work "let's set for all cases the pin configs
> > based on *.ini files", the others are same smaller change/less intrusive that
> > instead just deals with this hp dv4 case.
>
> I took the last, the smallest one. It's not too bad to define all
> models, but at this stage, I'd like rather to slim the code down.
And now I cleaned up the quirk entries.
Takashi
===
>From 2ae466f8cc522843fa9a456e46007dd98b052b13 Mon Sep 17 00:00:00 2001
From: Takashi Iwai <tiwai@suse.de>
Date: Mon, 16 Feb 2009 14:16:36 +0100
Subject: [PATCH] ALSA: hda - Cleanup IDT92HD7x HP quirks
Clean up IDT92HD7x quirks for HP laptops with SND_PCI_QUIRK_MASK().
Signed-off-by: Takashi Iwai <tiwai@suse.de>
---
sound/pci/hda/patch_sigmatel.c | 20 +++++---------------
1 files changed, 5 insertions(+), 15 deletions(-)
diff --git a/sound/pci/hda/patch_sigmatel.c b/sound/pci/hda/patch_sigmatel.c
index 7320059..d00a211 100644
--- a/sound/pci/hda/patch_sigmatel.c
+++ b/sound/pci/hda/patch_sigmatel.c
@@ -1817,22 +1817,12 @@ static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[] = {
"DFI LanParty", STAC_92HD71BXX_REF),
SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101,
"DFI LanParty", STAC_92HD71BXX_REF),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
- "HP dv5", STAC_HP_M4),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
- "HP dv7", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
- "HP dv4", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
- "HP dv7", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
- "HP dv7", STAC_HP_M4),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
- "HP dv5", STAC_HP_DV5),
- SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
- "HP dv5", STAC_HP_DV5),
+ SND_PCI_QUIRK_MASK(PCI_VENDOR_ID_HP, 0xfff0, 0x30f0,
+ "HP dv4-7", STAC_HP_DV5),
+ SND_PCI_QUIRK_MASK(PCI_VENDOR_ID_HP, 0xfff0, 0x3600,
+ "HP dv4-7", STAC_HP_DV5),
SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
- "unknown HP", STAC_HP_M4),
+ "HP mini 1000", STAC_HP_M4),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
"unknown Dell", STAC_DELL_M4_1),
SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0234,
--
1.6.1.3
^ permalink raw reply related [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-16 13:21 ` Takashi Iwai
@ 2009-02-17 19:51 ` Tim Barnette
2009-02-18 13:16 ` Herton Ronaldo Krzesinski
0 siblings, 1 reply; 36+ messages in thread
From: Tim Barnette @ 2009-02-17 19:51 UTC (permalink / raw)
To: Takashi Iwai
Cc: alsa-devel, Jean-Pierre André, Herton Ronaldo Krzesinski
Thanks guys. Will the patch make it to a near-term future upgrade so I can
run the alsa-upgrade script instead of the patch?
Also, now my headphones no longer work... And my speaker light on the
keyboard seems to malfunction.. Any idea about those?
On Mon, Feb 16, 2009 at 8:21 AM, Takashi Iwai <tiwai@suse.de> wrote:
> At Mon, 16 Feb 2009 11:48:24 +0100,
> I wrote:
> >
> > At Sat, 14 Feb 2009 17:13:55 -0200,
> > Herton Ronaldo Krzesinski wrote:
> > >
> > > On Saturday 14 February 2009 08:24:15 Takashi Iwai wrote:
> > > > At Fri, 13 Feb 2009 14:22:00 -0500,
> > > > Tim Barnette wrote:
> > > > >
> > > > > ..And it worked! I now have sound! Can you tell me what I
> actually did here?
> > > >
> > > > The problem was that your BIOS didn't set the correct default pin
> > > > configuration. The driver doesn't know which pin should be used for
> > > > the speaker output, as a consequence, it's set as INPUT.
> > > > Now you set it OUTPUT manually by hda-verb, and (fortunately) the
> > > > route to that pin was alive even though it wasn't declared, you get
> > > > the speaker output now.
> > > >
> > > > The next step is to implement a proper pin-config to override by
> > > > the driver. This won't be much work, but hey, wait for a while.
> > > >
> > > > (Or, did Herton already work on that?)
> > >
> > > I had added before pin configs for which source came from *.ini files
> of IDT
> > > windows drivers provided by HP. But I don't know if they are at all
> necessary,
> > > may be just setting config of 0x0d pin should suffice for all hp-dv5
> models,
> > > as all of them have speaker on 0x0d from all reports and also looking
> at the
> > > *.ini files.
> > >
> > > I have three patches, you can choose one of them :), see attached. The
> first
> > > one is my previous pin configs work "let's set for all cases the pin
> configs
> > > based on *.ini files", the others are same smaller change/less
> intrusive that
> > > instead just deals with this hp dv4 case.
> >
> > I took the last, the smallest one. It's not too bad to define all
> > models, but at this stage, I'd like rather to slim the code down.
>
> And now I cleaned up the quirk entries.
>
>
> Takashi
>
> ===
> From 2ae466f8cc522843fa9a456e46007dd98b052b13 Mon Sep 17 00:00:00 2001
> From: Takashi Iwai <tiwai@suse.de>
> Date: Mon, 16 Feb 2009 14:16:36 +0100
> Subject: [PATCH] ALSA: hda - Cleanup IDT92HD7x HP quirks
>
> Clean up IDT92HD7x quirks for HP laptops with SND_PCI_QUIRK_MASK().
>
> Signed-off-by: Takashi Iwai <tiwai@suse.de>
> ---
> sound/pci/hda/patch_sigmatel.c | 20 +++++---------------
> 1 files changed, 5 insertions(+), 15 deletions(-)
>
> diff --git a/sound/pci/hda/patch_sigmatel.c
> b/sound/pci/hda/patch_sigmatel.c
> index 7320059..d00a211 100644
> --- a/sound/pci/hda/patch_sigmatel.c
> +++ b/sound/pci/hda/patch_sigmatel.c
> @@ -1817,22 +1817,12 @@ static struct snd_pci_quirk stac92hd71bxx_cfg_tbl[]
> = {
> "DFI LanParty", STAC_92HD71BXX_REF),
> SND_PCI_QUIRK(PCI_VENDOR_ID_DFI, 0x3101,
> "DFI LanParty", STAC_92HD71BXX_REF),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f2,
> - "HP dv5", STAC_HP_M4),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f4,
> - "HP dv7", STAC_HP_DV5),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30f7,
> - "HP dv4", STAC_HP_DV5),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fb,
> - "HP dv7", STAC_HP_DV5),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x30fc,
> - "HP dv7", STAC_HP_M4),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3600,
> - "HP dv5", STAC_HP_DV5),
> - SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x3603,
> - "HP dv5", STAC_HP_DV5),
> + SND_PCI_QUIRK_MASK(PCI_VENDOR_ID_HP, 0xfff0, 0x30f0,
> + "HP dv4-7", STAC_HP_DV5),
> + SND_PCI_QUIRK_MASK(PCI_VENDOR_ID_HP, 0xfff0, 0x3600,
> + "HP dv4-7", STAC_HP_DV5),
> SND_PCI_QUIRK(PCI_VENDOR_ID_HP, 0x361a,
> - "unknown HP", STAC_HP_M4),
> + "HP mini 1000", STAC_HP_M4),
> SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0233,
> "unknown Dell", STAC_DELL_M4_1),
> SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x0234,
> --
> 1.6.1.3
>
>
>
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through, speakers...]
2009-02-16 10:47 ` Takashi Iwai
@ 2009-02-18 4:10 ` Guy Stalnaker
0 siblings, 0 replies; 36+ messages in thread
From: Guy Stalnaker @ 2009-02-18 4:10 UTC (permalink / raw)
To: Takashi Iwai; +Cc: alsa-devel
Takashi,
Sorry it took me until tonight. I downloaded and install the current
snapshot and it works. That is, I get sound from the speakers of my HP
Pavilion dv4 1225 laptop without needing to use the hda-verb command.
There is now a "Speakers" section in the GNOME Panel Volume Applet that
was not there before. It starts out muted, but after changing that, I
have sound.
Again, MUCH THANKS to you, Herton, and the two gentlemen who also posted
about their HP dv4 issues.
Best regards,
Guy S.
Takashi Iwai wrote:
> At Sun, 15 Feb 2009 23:25:15 -0600,
> Guy Stalnaker wrote:
>> Herton and Takashi,
>>
>> I can confirm that compiling and installing the latest snapshot of
>> alsa-drivers, adding "model=hp-dv5" to /etc/modprobe.d/alsa-base, and
>> running hda-verb with the parameters Takashi indicates DOES result in
>> sound from the onboard, internal speakers on my Hewlitt Packard dv4 1225
>> Pavilion Entertainment PC.
>>
>> The mute on headphone use does not work, but that's okay by me for now.
>
> Good. Could you try the very latest alsa-driver-snapshot tarball?
> Herton's patch is already included. If your PCI SSID matches, it
> should work as is. If not, please run alsa-info.sh with --no-upload
> option and attach the generated file.
>
>
>> I think you're on the right track in diagnosing the problem and it's
>> solution.
>>
>> Thank you very, very much for helping us. I know it'll likely be a
>> while before the solution actually makes it into distributions, but at
>> the least I can use my sound apps without having to plug my laptop into
>> something to hear what's playing. Kinda defeats the notion of having a
>> laptop if one has to keep it plugged in.
>>
>> Do either of you mind if I collate notes from the posts exchanged on
>> alsa-devel and post them on the Ubuntu forums? There are a lot of other
>> HP users who have posted about the same problem. It's likely they have
>> no idea the resource available to them in the alsa-devel archives.
>
> Sure, it's an open mailing list, so feel free to cite the thread.
>
>
>
> Takashi
>
>> BEST regards,
>>
>> Guy S.
>>
>>> ------------------------------
>>>
>>> Message: 4
>>> Date: Fri, 13 Feb 2009 14:16:21 -0500
>>> From: Tim Barnette <tim.barnette@gmail.com>
>>> Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
>>> speakers...]
>>> To: Takashi Iwai <tiwai@suse.de>
>>> Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
>>> <jean-pierre.andre@wanadoo.fr>
>>> Message-ID:
>>> <b71cdde20902131116l4c7da119s6c51a67e37371ebe@mail.gmail.com>
>>> Content-Type: text/plain; charset=ISO-8859-1
>>>
>>> Takashi, I was able to build hda-verb and when I executed the command below,
>>> it responded with:
>>> nid=0xd, verb=0x707, param=0x40
>>> value=0x0
>>>
>>> On Mon, Feb 2, 2009 at 10:25 AM, Takashi Iwai <tiwai@suse.de> wrote:
>>>
>>>> At Mon, 2 Feb 2009 10:17:03 -0500,
>>>> Tim Barnette wrote:
>>>>> Thanks, Takashi. I made this change and rebooted.
>>>>>
>>>>> I noticed right away the mute light is no longer on... but still no sound
>>>>> through speakers, only headphones..
>>>>>
>>>>> /sys/module/snd_hda_intel/parameters/model
>>>>> contains
>>>>> hp-dv5,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>,<NULL>
>>>>>
>>>>> attached is the alsa-info.txt you requested..
>>>> Did you try the latest alsa-driver snapshot?
>>>>
>>>> If it still doesn't work, I guess this is a BIOS problem.
>>>> The other HP dv laptops show the widget 0x0d as the speaker while
>>>> yours is unused.
>>>>
>>>> Try to run:
>>>> hda-verb /dev/snd/hwC0D0 0x0d SET_PIN_WID 0x40
>>>>
>>>>
>>>> Takashi
>>>>
>>>
>>> ------------------------------
>>>
>>> Message: 5
>>> Date: Fri, 13 Feb 2009 14:22:00 -0500
>>> From: Tim Barnette <tim.barnette@gmail.com>
>>> Subject: Re: [alsa-devel] [Fwd: HP DV4 1155 SE - No Sound through
>>> speakers...]
>>> To: Takashi Iwai <tiwai@suse.de>
>>> Cc: alsa-devel@alsa-project.org, Jean-Pierre Andr?
>>> <jean-pierre.andre@wanadoo.fr>
>>> Message-ID:
>>> <b71cdde20902131122q16eb7e44u92daf2a4c9500bd0@mail.gmail.com>
>>> Content-Type: text/plain; charset=ISO-8859-1
>>>
>>> ..And it worked! I now have sound! Can you tell me what I actually did
>>> here?
>> --
>> Guy Stalnaker, I2@DOIT, jstalnak@wisc.edu
>> 1210 West Dayton Street, Room 3209 CSS, Madison WI 53706
>> work 608.263.8035, cell 608.235.4718, fax 608.265.6681
>> _______________________________________________
>> Alsa-devel mailing list
>> Alsa-devel@alsa-project.org
>> http://mailman.alsa-project.org/mailman/listinfo/alsa-devel
>>
--
Guy Stalnaker, I2@DOIT, jstalnak@wisc.edu
1210 West Dayton Street, Room 3209 CSS, Madison WI 53706
work 608.263.8035, cell 608.235.4718, fax 608.265.6681
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-17 19:51 ` Tim Barnette
@ 2009-02-18 13:16 ` Herton Ronaldo Krzesinski
2009-02-24 18:08 ` Tim Barnette
0 siblings, 1 reply; 36+ messages in thread
From: Herton Ronaldo Krzesinski @ 2009-02-18 13:16 UTC (permalink / raw)
To: alsa-devel; +Cc: Takashi Iwai, Tim Barnette, Jean-Pierre André
Em Terça-feira 17 Fevereiro 2009, às 16:51:03, Tim Barnette escreveu:
> Thanks guys. Will the patch make it to a near-term future upgrade so I can
> run the alsa-upgrade script instead of the patch?
The changes are in latest sound tree/alsa-driver snapshot
(ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/alsa-driver-
snapshot.tar.gz). I don't know about alsa-upgrade script.
>
> Also, now my headphones no longer work... And my speaker light on the
> keyboard seems to malfunction.. Any idea about those?
You tested with latest alsa-driver snapshot, and stopped to work there?
--
[]'s
Herton
^ permalink raw reply [flat|nested] 36+ messages in thread
* Re: [Fwd: HP DV4 1155 SE - No Sound through speakers...]
2009-02-18 13:16 ` Herton Ronaldo Krzesinski
@ 2009-02-24 18:08 ` Tim Barnette
0 siblings, 0 replies; 36+ messages in thread
From: Tim Barnette @ 2009-02-24 18:08 UTC (permalink / raw)
To: Herton Ronaldo Krzesinski
Cc: Takashi Iwai, alsa-devel, Jean-Pierre André
I downloaded the latest alsa-driver, configured, make'd, installed, and
voila... it all appears to work... Thank you soooooo much..
On Wed, Feb 18, 2009 at 8:16 AM, Herton Ronaldo Krzesinski <
herton@mandriva.com.br> wrote:
> Em Terça-feira 17 Fevereiro 2009, às 16:51:03, Tim Barnette escreveu:
> > Thanks guys. Will the patch make it to a near-term future upgrade so I
> can
> > run the alsa-upgrade script instead of the patch?
>
> The changes are in latest sound tree/alsa-driver snapshot
> (ftp://ftp.kernel.org/pub/linux/kernel/people/tiwai/snapshot/alsa-driver-
> snapshot.tar.gz). I don't know about alsa-upgrade script.
>
> >
> > Also, now my headphones no longer work... And my speaker light on the
> > keyboard seems to malfunction.. Any idea about those?
>
> You tested with latest alsa-driver snapshot, and stopped to work there?
>
> --
> []'s
> Herton
>
^ permalink raw reply [flat|nested] 36+ messages in thread
end of thread, other threads:[~2009-02-24 18:08 UTC | newest]
Thread overview: 36+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
[not found] <mailman.2709.1234557113.1965.alsa-devel@alsa-project.org>
2009-02-16 5:25 ` [Fwd: HP DV4 1155 SE - No Sound through, speakers...] Guy Stalnaker
2009-02-16 10:47 ` Takashi Iwai
2009-02-18 4:10 ` Guy Stalnaker
[not found] <4983FE7A.1040201@wanadoo.fr>
2009-01-31 7:52 ` [Fwd: HP DV4 1155 SE - No Sound through speakers...] Jean-Pierre André
2009-01-31 9:20 ` Takashi Iwai
2009-02-01 22:34 ` Tim Barnette
2009-02-02 6:45 ` Takashi Iwai
2009-02-02 15:17 ` Tim Barnette
2009-02-02 15:25 ` Takashi Iwai
2009-02-02 16:26 ` Tim Barnette
2009-02-02 16:28 ` Takashi Iwai
2009-02-02 17:01 ` Tim Barnette
2009-02-02 17:10 ` Takashi Iwai
2009-02-13 19:16 ` Tim Barnette
2009-02-13 19:22 ` Tim Barnette
2009-02-14 10:24 ` Takashi Iwai
2009-02-14 19:13 ` Herton Ronaldo Krzesinski
2009-02-16 10:48 ` Takashi Iwai
2009-02-16 13:21 ` Takashi Iwai
2009-02-17 19:51 ` Tim Barnette
2009-02-18 13:16 ` Herton Ronaldo Krzesinski
2009-02-24 18:08 ` Tim Barnette
2009-02-02 18:20 ` Herton Ronaldo Krzesinski
2009-02-02 18:52 ` Takashi Iwai
2009-02-02 19:19 ` Tim Barnette
2009-02-02 19:48 ` Herton Ronaldo Krzesinski
2009-02-03 13:49 ` Jean-Pierre André
2009-02-04 17:01 ` Jean-Pierre André
2009-02-04 17:09 ` Takashi Iwai
2009-02-04 17:37 ` Jean-Pierre André
2009-02-04 17:40 ` Herton Ronaldo Krzesinski
2009-02-04 22:42 ` Takashi Iwai
2009-02-05 2:46 ` Tim Barnette
2009-02-05 7:06 ` Takashi Iwai
2009-02-05 7:04 ` Takashi Iwai
2009-02-04 17:49 ` Herton Ronaldo Krzesinski
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.