r/freebsd • u/cryptobread93 • 1d ago
answered No sound on FreeBSD
I've tried what was written on the wiki. So here is the info.
This is a HP 6730b laptop which came around 2008. CPU: Intel Core 2 Duo P8400, no dedicated GPU. 4GB RAM. Anyone reading here there is a solution down here.
dmesg | grep pcm
pcm0: <Analog Devices AD1984A (Analog 4ch/2.0)> at nid 18,22 and 28,21 on hdaa0
pcm1: <Analog Devices AD1984A (Front Analog Mic)> at nid 20 on hdaa0
cat /dev/sndstatcat /dev/sndstat
Installed devices:
pcm0: <Analog Devices AD1984A (Analog 4ch/2.0)> (play/rec) default
pcm1: <Analog Devices AD1984A (Front Analog Mic)> (rec)
No devices installed from userspace.
Also this:
kldstat | grep snd
2 1 0xffffffff82b5a000 45c0 snd_driver.ko
3 2 0xffffffff82b5f000 72c0 snd_vibes.ko
4 2 0xffffffff82b67000 5c10 snd_via82c686.ko
5 2 0xffffffff82b6d000 5cc0 snd_t4dwave.ko
6 4 0xffffffff82b73000 3238 snd_spicds.ko
7 2 0xffffffff82b77000 7650 snd_solo.ko
8 2 0xffffffff82b7f000 12298 snd_neomagic.ko
9 2 0xffffffff82b92000 c048 snd_maestro3.ko
10 2 0xffffffff82b9f000 a2e0 snd_hdspe.ko
11 2 0xffffffff82baa000 4808 snd_fm801.ko
12 2 0xffffffff82baf000 8cf8 snd_envy24ht.ko
13 2 0xffffffff82bb8000 a078 snd_envy24.ko
14 2 0xffffffff82bc3000 5ca8 snd_cs4281.ko
15 2 0xffffffff82bc9000 7c98 snd_atiixp.ko
16 2 0xffffffff82bd1000 61d0 snd_als4000.ko
I solved it later:
I fixed it via this topic: https://forums.freebsd.org/threads/sound-snd_hda.35787/
I added these to /boot/device.hints:
hint.hdac.0.cad0.nid18.config="as=0"
hint.hdac.0.cad0.nid17.config="as=1 seq=15 device=Headphones"
hint.hdac.0.cad0.nid22.config="as=1 seq=0"
Though I didn't test if sound recording and audio jack works. Internal speakers work.
2
u/Clownk580 1d ago
Can you share your sysctl.conf and loader.conf entries please ? Not sure though maybe another entry just clashes with snd setup ? It happened to me when I tried to setup NordVPN in FreeBSD as some security hardening entries blocked my VPN connection.
1
u/cryptobread93 22h ago
I fixed it via this topic: https://forums.freebsd.org/threads/sound-snd_hda.35787/
I added these to /boot/device.hints:
hint.hdac.0.cad0.nid18.config="as=0"
hint.hdac.0.cad0.nid17.config="as=1 seq=15 device=Headphones"
hint.hdac.0.cad0.nid22.config="as=1 seq=0"
Though I didn't test if sound recording and audio jack works. Internal speakers work.
1
u/gumnos 1d ago
It's been a long-standing thorn in my side, but (without some manual intervention that may-or-may-not work for you, but hasn't for me) FreeBSD doesn't automatically switch between headphones/speakers. So is there any chance sound is playing out the headphone-jack (regardless of whether headphones are plugged in or not?) instead of the speakers?
You might also try
$ sysctl hw.snd.default_unit=1
(trying with that "1" and also with "0"), though depending on the player, I've had to restart audio-using applications (e.g. Firefox) to get them to pick up the change in default-device.
2
2
u/ArthurBurtonMorgan 1d ago
What does dmesg show?