Re: snd_hda, freebsd 8 and headphones

Alexander Motin <[email protected]>
Newsgroups gmane.os.freebsd.devel.mobile
Message-ID <[email protected]>
glimm - wrote:
> After updating to 8.0 my headphones stopped working on my laptop. I
> think that should fix hdac.c file, but can not imagine how. Help me:)
> 
> Model - Sony VAIO SZ650
> 
> snd_hda verbose:
> 
> hdac0: <Intel 82801H High Definition Audio Controller> mem
> 0xfc300000-0xfc303fff irq 21 at device 27.0 on pci0 hdac0: HDA Driver
> Revision: 20090624_0136 hdac0: attempting to allocate 1 MSI vectors (1
> supported) msi: routing MSI IRQ 256 to local APIC 0 vector 48
> hdac0: using IRQ 256 for MSI
> hdac0: [MPSAFE]
> hdac0: [ITHREAD]
> hdac0: Probing codec #0...
> hdac0: HDA Codec #0: Sigmatel STAC9872AK
> hdac0: HDA Codec ID: 0x83847662
> hdac0: Vendor: 0x8384
> hdac0: Device: 0x7662
> hdac0: Revision: 0x02
> hdac0: Stepping: 0x01
> hdac0: PCI Subvendor: 0x9008104d
> hdac0: Found audio FG nid=1 startnode=2 endnode=25 total=23
> hdac0: Probing codec #1...
> hdac0: HDA Codec #1: Conexant (Unknown)
> hdac0: HDA Codec ID: 0x14f12c06
> hdac0: Vendor: 0x14f1
> hdac0: Device: 0x2c06
> hdac0: Revision: 0x00
> hdac0: Stepping: 0x00
> hdac0: PCI Subvendor: 0x9008104d
> hdac0: Found modem FG nid=2 startnode=112 endnode=116 total=4
> hdac0:
> hdac0: Processing audio FG cad=0 nid=1...
> hdac0: GPIO: 0xc0000005 NumGPIO=5 NumGPO=0 NumGPI=0 GPIWake=1
> GPIUnsol=1 hdac0: nid 10 0x03211020 as 2 seq 0 Headphones Jack
> jack 1 loc 3 color Black misc 0 hdac0: nid 11 0x411111f0 as 15
> seq 0 Speaker None jack 1 loc 1 color Black misc 1 hdac0:
> nid 12 0x411111f0 as 15 seq 0 Speaker None jack 1 loc 1
> color Black misc 1 hdac0: nid 13 0x03a15030 as 3 seq 0
> Mic Jack jack 1 loc 3 color Red misc 0 hdac0: nid 14 0x411111f0
> as 15 seq 0 Speaker None jack 1 loc 1 color Black misc 1
> hdac0: nid 15 0x90170110 as 1 seq 0 Speaker Fixed jack 7 loc
> 16 color Unknown misc 1 hdac0: nid 17 0x411111f0 as 15 seq 0
> Speaker None jack 1 loc 1 color Black misc 1 hdac0: nid 19
> 0x411111f0 as 15 seq 0 Speaker None jack 1 loc 1 color
> Black misc 1 hdac0: nid 20 0x90a7013e as 3 seq 14 Mic Fixed
> jack 7 loc 16 color Unknown misc 1 hdac0: Patched pins configuration:
> hdac0: nid 10 0x03211020 as 2 seq 0 Headphones Jack jack 1 loc
> 3 color Black misc 0 hdac0: nid 11 0x411111f0 as 15 seq 0
> Speaker None jack 1 loc 1 color Black misc 1 [DISABLED] hdac0:
> nid 12 0x411111f0 as 15 seq 0 Speaker None jack 1 loc 1
> color Black misc 1 [DISABLED] hdac0: nid 13 0x03a15030 as 3 seq
> 0 Mic Jack jack 1 loc 3 color Red misc 0 hdac0: nid
> 14 0x411111f0 as 15 seq 0 Speaker None jack 1 loc 1 color
> Black misc 1 [DISABLED] hdac0: nid 15 0x90170110 as 1 seq 0
> Speaker Fixed jack 7 loc 16 color Unknown misc 1 hdac0: nid 17
> 0x411111f0 as 15 seq 0 Speaker None jack 1 loc 1 color
> Black misc 1 [DISABLED] hdac0: nid 19 0x411111f0 as 15 seq 0
> Speaker None jack 1 loc 1 color Black misc 1 [DISABLED] hdac0:
> nid 20 0x90a7013e as 3 seq 14 Mic Fixed jack 7 loc 16 color
> Unknown misc 1 hdac0: 3 associations found: hdac0: Association 0 (1)
> out: hdac0: Pin nid=15 seq=0 hdac0: Association 1 (2) out: hdac0: Pin
> nid=10 seq=0 hdac0: Association 2 (3) in: hdac0: Pin nid=13 seq=0
> hdac0: Pin nid=20 seq=14 hdac0: Tracing association 0 (1) hdac0: Pin
> 15 traced to DAC 5 hdac0: Association 0 (1) trace succeeded hdac0:
> Tracing association 1 (2) hdac0: Pin 10 traced to DAC 2
> hdac0: Association 1 (2) trace succeeded
> hdac0: Tracing association 2 (3)
> hdac0: Unable to trace pin 13 to ADC 6, undo traces
> hdac0: Pin 13 traced to ADC 8
> hdac0: Pin 20 traced to ADC 8
> hdac0: Association 2 (3) trace succeeded

It is difficult to read this without original formatting, but below we
can see that you codec configured to provide separate audio devices for
speaker and headphones:

> pcm0: <HDA Sigmatel STAC9872AK PCM #0 Analog> at cad 0 nid 1 on hdac0
> pcm0: +-------------------------------+
> pcm0: | DUMPING Playback/Record Paths |
> pcm0: +-------------------------------+
> pcm0:
> pcm0: Playback:
> pcm0:
> pcm0: nid=15 [pin: Speaker (Fixed)]
> pcm0: |
> pcm0: + <- nid=5 [audio output] [src: pcm]
> pcm0:
> pcm0: Record:
> pcm0:
> pcm0: nid=8 [audio input]
> pcm0: |
> pcm0: + <- nid=9 [audio selector] [src: mic, monitor]
> pcm0: |
> pcm0: + <- nid=21 [audio selector] [src: mic, monitor]
> pcm0: |
> pcm0: + <- nid=13 [pin: Mic (Red Jack)] [src: mic]
> pcm0: + <- nid=20 [pin: Mic (Fixed)] [src: monitor]
> pcm0:
> pcm1: <HDA Sigmatel STAC9872AK PCM #1 Analog> at cad 0 nid 1 on hdac0
> pcm1: +-------------------------------+
> pcm1: | DUMPING Playback/Record Paths |
> pcm1: +-------------------------------+
> pcm1:
> pcm1: Playback:
> pcm1:
> pcm1: nid=10 [pin: Headphones (Black Jack)]
> pcm1: |
> pcm1: + <- nid=2 [audio output] [src: pcm]

Usually in such cases codec configured to do automatic audio redirection
 on headphones plug-in, but for some reason not in your case.

So you may try to either playback via pcm1 device to headphones, or add
line:
hint.hdac.0.cad0.nid10.config="as=1 seq=15"
into /boot/loader.conf to configure automatic redirection. Also you may
want to read snd_hda man page, which describes it.

-- 
Alexander Motin
_______________________________________________
[email protected] mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-mobile
To unsubscribe, send any mail to "[email protected]"
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.