No Sound with Realtek ALC269

Hello,

iI have bought me a Toshiba Satellite L875 Notebook.
The only annoying thing with it, is that iI don't can hear music or something else with this sound card.

Commands trying to play music:

With AudioCD:
cdcontrol play 4
mplayer *.wav

But no sound was playing through the speakers.
Also have tried different configuration with the nid pins.

My information:

/dev/sndstat
Code:
Installed devices:
pcm0: <ATI R6xx (HDMI)> (play)
pcm1: <Realtek ALC269 (Analog 2.0+HP/2.0)> (play/rec) default
pcm2: <Realtek ALC269 (Internal Analog Mic)> (rec)
/boot/loader.conf
Code:
#remove some uncessary modules...
WITHOUT_BLUETOOTH="YES"

#licence for sound
legal.realtek.license_ack=1
legal.intel.license_ack=1

#synaptics support
hw.psm.synaptics_support="1"
aio_load="YES"

#temperature
coretemp_load="YES"

kern.vty=vt
#wlan support
if_ath_load="YES"
wlan_wep_load="YES"
wlan_ccmp_load="YES"
wlan_tkip_load="YES"

#radeon graphic
#radeonkms_load="YES"
#radeonkmsfw_TURKS_pfp_load="YES"
#radeonkmsfw_TURKS_me_load="YES"
#radeonkmsfw_BTC_rlc_load="YES"
#radeonkmsfw_TURKS_mc_load="YES"

#sound support
#sound_enable="YES"
sound_load="YES"

snd_hda_load="YES"
snd_ich_load="YES"

#for lagg0 network interface
if_lagg_load="YES"

hint.hdacc.1.cad0.nid21.config="as=1 seq=15 device=Headphones"
hint.hdacc.1.cad0.nid20.config="as=1 seq=0 device=Speaker"
mixer
Code:
Mixer vol  is currently set to 100:100
Mixer pcm  is currently set to 100:100
Mixer speaker  is currently set to 100:100
Mixer mic  is currently set to  67:67
Mixer mix  is currently set to  74:74
Mixer rec  is currently set to  37:37
Mixer igain  is currently set to  0:0
Mixer ogain  is currently set to 100:100
Recording source: mic
pindump:
Code:
hdaa1: Dumping AFG pins:
hdaa1: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa1: 18 90a60940 4  0  Mic  Fixed Digital Internal  Unknown 9
hdaa1:  Caps: IN
hdaa1: 20 90170110 1  0  Speaker  Fixed Analog  Internal  Unknown 1
hdaa1:  Caps:  OUT  EAPD  Sense: 0x00000000 (disconnected)
hdaa1: 21 0421101f 1  15 Headphones  Jack  1/8  Right  Black  0
hdaa1:  Caps:  OUT HP EAPD  Sense: 0x80000000 (connected)
hdaa1: 23 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps:  OUT
hdaa1: 24 04a11830 3  0  Mic  Jack  1/8  Right  Black  8
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 25 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 26 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT HP  VREF Sense: 0x00000000 (disconnected)
hdaa1: 27 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 30 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps:  OUT
hdaa1: NumGPIO=2 NumGPO=0 NumGPI=0 GPIWake=0 GPIUnsol=1
hdaa1:  GPIO0: disabled
hdaa1:  GPIO1: disabled
dmesg
http://pastebin.com/bfZ83HfS

Hope someone could help.

I wanted to wait for a solution for this thread of an other member
https://forums.freebsd.org/threads/no-sound-on-laptop-with-freebsd-10-1.50030/ and change it for my needs, but it takes to long. :(

Edit: Found something strange, iI can't find /dev/dsp
 
One concept is that the associations have to contain values that all go the same direction. For example as=2 would be "in" and would contain "mic" "line-in" "system beeps". as=1 would then be "outs" containing "headphones", "line-out" and "speakers". On workstation motherboards, with headers for front jacks, as=3 would be a grouping for outs on the front panel.


freebsd_snd_400px.png

The online pictures I saw of your laptop model shows 2 black 1/8inch jacks on the right side. I did not see any other 1/8inch jacks. Of the 1/8" jacks on the right one should be a mic (nid24) and one should be headphones (nid21). Some where in there is a source for system beeps and it would be helpful to know if your system generates those. One confusing part of the manual page is how associations are specified. Association 0 is coded as "as=1", Association 1 coded as "as=2"


It looks like the pindump you posted reflects
hint.hdacc.1.cad0.nid21.config="as=1 seq=15 device=Headphones"
hint.hdacc.1.cad0.nid20.config="as=1 seq=0 device=Speaker"

snd_hda(4) suggests that those values should go in /boot/device.hints. It would be helpful to remove the above from /boot/loader.conf, regenerate your native pindump and post. I have not changed enough pin settings to know if your hints will affect other associations that are not specified in /boot/device.hints. Lastly, snd_hda is complied in the 10.1 kernel. Unless your device is not recognized, it should not be necessary to have
snd_hda_load="YES"
snd_ich_load="YES"

Edit: Corrected dyslexia associations/as
 
One concept is that the associations have to contain values that all go the same direction. For example as=2 would be "in" and would contain "mic" "line-in" "system beeps". as=1 would then be "outs" containing "headphones", "line-out" and "speakers". On workstation motherboards, with headers for front jacks, as=3 would be a grouping for outs on the front panel.
View attachment 2428
The online pictures I saw of your laptop model shows 2 black 1/8inch jacks on the right side. I did not see any other 1/8inch jacks. Of the 1/8" jacks on the right one should be a mic (nid24) and one should be headphones (nid21). Some where in there is a source for system beeps and it would be helpful to know if your system generates those. One confusing part of the manual page is how associations are specified. Association 0 is coded as "as=1", Association 1 coded as "as=2"
Yes, when you look from the side on the notebook, you see 2 black 1/8inch jacks, the left one is headphone and the right one is the microphone.
It looks like the pindump you posted reflects

snd_hda(4) suggests that those values should go in /boot/device.hints. It would be helpful to remove the above from /boot/loader.conf, regenerate your native pindump and post. I have not changed enough pin settings to know if your hints will affect other associations that are not specified in /boot/device.hints. Lastly, snd_hda is complied in the 10.1 kernel. Unless your device is not recognized, it should not be necessary to have

Edit: Corrected dyslexia associations/as
I have remove the lines and restart the notebook, but nothing changed

pindump without device.hints (nothing changed):
Code:
hdacc1: <Realtek ALC269 HDA CODEC> at cad 0 on hdac1
hdaa1: <Realtek ALC269 Audio Function Group> at nid 1 on hdacc1
pcm1: <Realtek ALC269 (Analog 2.0+HP/2.0)> at nid 20,21 and 24 on hdaa1
pcm2: <Realtek ALC269 (Internal Analog Mic)> at nid 18 on hdaa1
hdaa1: Dumping AFG pins:
hdaa1: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa1: 18 90a60940 4  0  Mic  Fixed Digital Internal  Unknown 9
hdaa1:  Caps: IN 
hdaa1: 20 90170110 1  0  Speaker  Fixed Analog  Internal  Unknown 1
hdaa1:  Caps:  OUT  EAPD  Sense: 0x00000000 (disconnected)
hdaa1: 21 0421101f 1  15 Headphones  Jack  1/8  Right  Black  0
hdaa1:  Caps:  OUT HP EAPD  Sense: 0x00000000 (disconnected)
hdaa1: 23 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps:  OUT 
hdaa1: 24 04a11830 3  0  Mic  Jack  1/8  Right  Black  8
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 25 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 26 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT HP  VREF Sense: 0x00000000 (disconnected)
hdaa1: 27 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps: IN OUT  VREF Sense: 0x00000000 (disconnected)
hdaa1: 30 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1:  Caps:  OUT 
hdaa1: NumGPIO=2 NumGPO=0 NumGPI=0 GPIWake=0 GPIUnsol=1
hdaa1:  GPIO0: disabled
hdaa1:  GPIO1: disabled
Change hdacc to hdac , but no effect.
Code:
hint.hdac.1.cad0.nid21.config="as=1 seq=15 device=Headphones"
hint.hdac.1.cad0.nid20.config="as=1 seq=0 device=Speaker"
Also no beep sound is coming out.
printf "\007"
sysctl hw.syscons.bell
Code:
hw.syscons.bell: 1
In the BIOS Settings it is also activated.
 
Installed devices:
pcm0: <ATI R6xx (HDMI)> (play)
pcm1: <Realtek ALC269 (Analog 2.0+HP/2.0)> (play/rec) default
pcm2: <Realtek ALC269 (Internal Analog Mic)> (rec)

I missed this before. The system is allocating 3 pcm devices and unless specified, the first one, pcm0 (ati video, hdmi) is normally the default. It looks like you specified pcm1 to be the default, but want to double check. Do you have the /etc/sysctl.conf entry as described in handbook 8.2.3? Also found this thread which suggests changing hdac -> hdaa

hint.hdac.1.cad0.nid20.config="as=1 seq=0 device=Speaker"

I would try
Code:
hint.hdaa.1.cad0.nid20.config="as=1 seq=0 device=Speaker
hint.hdaa.1.cad0.nid21.config="as=1 seq=15 device=Headphones

Edit: Revised recommendation based on Thread 30502
 
I missed this before. The system is allocating 3 pcm devices and unless specified, the first one, pcm0 (ati video, hdmi) is normally the default. It looks like you specified pcm1 to be the default, but want to double check. Do you have the /etc/sysctl.conf entry as described in handbook 8.2.3? Also found this thread which suggests changing hdac -> hdaa

I would try
Code:
hint.hdaa.1.cad0.nid20.config="as=1 seq=0 device=Speaker
hint.hdaa.1.cad0.nid21.config="as=1 seq=15 device=Headphones

Edit: Revised recommendation based on Thread 30502

Thanks for the Thread, iI have read it fully, but nothing helped here :(

/etc/sysctl.conf
Code:
hw.snd.default_unit=1
/boot/device.hints
Code:
#hint.hdaa.1.cad0.nid21.config="as=1 seq=15 device=Headphones"
hint.hdaa.1.cad0.nid20.config="as=1 seq=0 device=Speaker"
Also tried without the cad0, but no success...

Verbose Bootlog with grep "hda"
Code:
hdac0: <ATI RV930 HDA Controller> mem 0xc2020000-0xc2023fff irq 17 at device 0.1 on pci1
hdac0: PCI card vendor: 0x1179, device: 0xfb41
hdac0: HDA Driver Revision: 20120126_0002
hdac0: Config options: on=0x00000000 off=0x00000000
hdac0: attempting to allocate 1 MSI vectors (1 supported)
hdac0: using IRQ 264 for MSI
hdac0: Caps: OSS 1, ISS 0, BSS 0, NSDO 1, 64bit, CORB 256, RIRB 256
hdac1: <Intel Panther Point HDA Controller> mem 0xc3100000-0xc3103fff irq 22 at device 27.0 on pci0
hdac1: PCI card vendor: 0x1179, device: 0xfb40
hdac1: HDA Driver Revision: 20120126_0002
hdac1: Config options: on=0x00000000 off=0x00000000
hdac1: attempting to allocate 1 MSI vectors (1 supported)
hdac1: using IRQ 265 for MSI
hdac1: Caps: OSS 4, ISS 4, BSS 0, NSDO 1, 64bit, CORB 256, RIRB 256
hdacc0: <ATI R6xx HDA CODEC> at cad 0 on hdac0
hdaa0: <ATI R6xx Audio Function Group> at nid 1 on hdacc0
hdaa0: Subsystem ID: 0x00aa0100
hdaa0: NumGPIO=0 NumGPO=0 NumGPI=0 GPIWake=0 GPIUnsol=0
hdaa0: Original pins configuration:
hdaa0: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa0:  3 18560010 1  0  Digital-out  Jack  Digital 0x18  Unknown 0
hdaa0: Patched pins configuration:
hdaa0: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa0:  3 18560010 1  0  Digital-out  Jack  Digital 0x18  Unknown 0
hdaa0: 1 associations found:
hdaa0: Association 0 (1) out:
hdaa0:  Pin nid=3 seq=0
hdaa0: Tracing association 0 (1)
hdaa0:  Pin 3 traced to DAC 2
hdaa0: Association 0 (1) trace succeeded
hdaa0: Looking for additional DAC for association 0 (1)
hdaa0: Tracing input monitor
hdaa0: Tracing other input monitors
hdaa0: Tracing beeper
hdaa0: Pin sense: nid=3 sense=0x7fffffff (disconnected, ELD valid)
hdaa0: FG config/quirks: forcestereo ivref50 ivref80 ivref100 ivref
pcm0: <ATI R6xx (HDMI)> at nid 3 on hdaa0
hdacc1: <Realtek ALC269 HDA CODEC> at cad 0 on hdac1
hdaa1: <Realtek ALC269 Audio Function Group> at nid 1 on hdacc1
hdaa1: Subsystem ID: 0x1179fb40
hdaa1: NumGPIO=2 NumGPO=0 NumGPI=0 GPIWake=0 GPIUnsol=1
hdaa1:  GPIO0: disabled
hdaa1:  GPIO1: disabled
hdaa1: Original pins configuration:
hdaa1: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa1: 18 90a60940 4  0  Mic  Fixed Digital Internal  Unknown 9
hdaa1: 20 90170110 1  0  Speaker  Fixed Analog  Internal  Unknown 1
hdaa1: 21 0421101f 1  15 Headphones  Jack  1/8  Right  Black  0
hdaa1: 23 411111f0 15 0  Speaker  None  1/8  Rear  Black  1
hdaa1: 24 04a11830 3  0  Mic  Jack  1/8  Right  Black  8
hdaa1: 25 411111f0 15 0  Speaker  None  1/8  Rear  Black  1
hdaa1: 26 411111f0 15 0  Speaker  None  1/8  Rear  Black  1
hdaa1: 27 411111f0 15 0  Speaker  None  1/8  Rear  Black  1
hdaa1: 29 4005822d 2  13 Line-out  None  Optical 0x00  Purple  2
hdaa1: 30 411111f0 15 0  Speaker  None  1/8  Rear  Black  1
hdaa1: Patching widget caps nid=29 0x00400400 -> 0x00700400
hdaa1: Patched pins configuration:
hdaa1: nid  0x  as seq device  conn  jack  loc  color  misc
hdaa1: 18 90a60940 4  0  Mic  Fixed Digital Internal  Unknown 9
hdaa1: 20 90170110 1  0  Speaker  Fixed Analog  Internal  Unknown 1
hdaa1: 21 0421101f 1  15 Headphones  Jack  1/8  Right  Black  0
hdaa1: 23 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1: 24 04a11830 3  0  Mic  Jack  1/8  Right  Black  8
hdaa1: 25 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1: 26 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1: 27 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1: 30 411111f0 15 0  Speaker  None  1/8  Rear  Black  1 DISA
hdaa1: 3 associations found:
hdaa1: Association 0 (1) out:
hdaa1:  Pin nid=20 seq=0
hdaa1:  Pin nid=21 seq=15
hdaa1: Association 1 (3) in:
hdaa1:  Pin nid=24 seq=0
hdaa1: Association 2 (4) in:
hdaa1:  Pin nid=18 seq=0
hdaa1: Tracing association 0 (1)
hdaa1:  Pin 20 traced to DAC 2
hdaa1:  Pin 21 traced to DAC 2 and hpredir 0
hdaa1: Association 0 (1) trace succeeded
hdaa1: Tracing association 1 (3)
hdaa1:  Pin 24 traced to ADC 8
hdaa1: Association 1 (3) trace succeeded
hdaa1: Tracing association 2 (4)
hdaa1:  Pin 18 traced to ADC 9
hdaa1: Association 2 (4) trace succeeded
hdaa1: Looking for additional DAC for association 0 (1)
hdaa1: Looking for additional ADC for association 1 (3)
hdaa1: Looking for additional ADC for association 2 (4)
hdaa1: Tracing input monitor
hdaa1:  Tracing nid 11 to out
hdaa1:  nid 11 is input monitor
hdaa1:  Tracing nid 34 to out
hdaa1:  Tracing nid 35 to out
hdaa1: Tracing other input monitors
hdaa1:  Tracing nid 18 to out
hdaa1:  Tracing nid 24 to out
hdaa1: Tracing beeper
hdaa1: Headphones redirection for association 0 nid=21 using unsolicited responses.
hdaa1: Redirect output to: main
hdaa1: FG config/quirks: forcestereo ivref50 ivref80 ivref100 ivref
pcm1: <Realtek ALC269 (Analog 2.0+HP/2.0)> at nid 20,21 and 24 on hdaa1
pcm2: <Realtek ALC269 (Internal Analog Mic)> at nid 18 on hdaa1
Edit :

Strange behaviour...
Sometimes iI have a /dev/dsp1.0 and sometimes not...
Also iI have tried to play a mp3-file with audio/mpg123 and turn on sysctl hw.snd.verbose=4 and get a lot of messages.

http://pastebin.com/1uX9Azcf

The last lines looks suspect for me.
 
Two thoughts.

snd_hda(4) example shows the pins to be hdaa0: 20 but the hint is passed as
Code:
hint.hdac.0.cad0.nid20.config="as=1"
I would try, if you have not already done so,:
Code:
hint.hdac.1.cad0.nid21.config="as=1 seq=15 device=Headphones"
hint.hdac.1.cad0.nid20.config="as=1 seq=0 device=Speaker"
Secondly, your patched configuration is that it is using nid20 for the speakers. In the examples in the snd_hda(4) and most of the successful posts on this the speaker output is one of the higher nid's. A thought would be to simplify the configuration by disabling
Code:
as=0
the headphone jacks and sequentially setting nid's 23, 25, 26, 27 and 30
Code:
as=1 seq=0
You could also isolate and test the headphone jack as a line-out.
 
I was not successful with this shepper.
I have found an interesting Thread how is 2 years old in the mailing list, with a guy who has also has a Realteak ALC269:
http://lists.freebsd.org/pipermail/freebsd-questions/2012-October/245919.html
At the moment I'm trying his patches to hdaa.c with
Code:
lmute=0;
rmute=0
Trying to unmute everything in my notebook, maybe I could find something. And if this is a driver problem I have to write a maintainer :)

Edit: Interesting, since I have unmute everything in the hda.c I can hear the bell-sound printf "\007" or with printf "\a" no mp3 or something else, but I will go further for it :)
 
Configuring sound is complicated enough without having to patch the underlying code. You might want to see if you can get the interest of one of the developers. Alexander Motin has occasionally posted in the forums. There is a dated email contact in this Sound-FreeBSD Wiki. Good Luck.
 
Back
Top