Community
cancel
Showing results for 
Search instead for 
Did you mean: 
JDisn
Beginner
2,586 Views

How to fix audio pops in Linux.

Hey gang,

I run Linux on my HNK Hades Canyon NUC.

(Fedora 28 with kernel 4.18-rc7)

There is a very subtle yet annoying audio POP that happens immediately before & after any normal audio play-back.

My intuition felt that issue resembled some kind of power-saving feature, and I was not wrong.

To solve this issue simply disable the power saving feature of the Intel HD Audio driver in Linux.

To observe the current values:

# cat /sys/module/snd_hda_intel/parameters/power_save

1

# cat /sys/module/snd_hda_intel/parameters/power_save_controller

Y

The value of "1" for the power_save is the worst possible default imaginable, it's the most absurdly aggressive power saving mode possible. It would have been more sane to default to 10 or 20 seconds, but I digress.

The value of "Y" simply indicates the power saving feature is enabled.

To disable these features on a running system, simply use standard IO on the same files:

# echo 'N' > /sys/module/snd_hda_intel/parameters/power_save_controller

# echo '0' > /sys/module/snd_hda_intel/parameters/power_save

(Edit: made a copy/paste correction here to correctly show the stdio echo into the files)

Repeat the earlier steps to verify the change.

To make the change more permanent you can re-build your kernel with modified CONFIG_SND_HDA_POWER_SAVE_DEFAULT parameter, see the kconfig documentation for details.

https://cateee.net/lkddb/web-lkddb/SND_HDA_POWER_SAVE_DEFAULT.html https://cateee.net/lkddb/web-lkddb/SND_HDA_POWER_SAVE_DEFAULT.html

Another option might be to blacklist the kernel module on bootup, or write a scrip to set these values on boot.

Anyways, hope this helps someone.

0 Kudos
4 Replies
Chris_V_Intel
Moderator
898 Views

Thank you for sharing!

sasd
Beginner
898 Views

Thanks alot! You've made my day! This issue was bothering me since I've got my new NUC.

sasd
Beginner
898 Views

Btw, to make it permanent, the following works on fedora and others:

# echo `options snd-hda-intel power_save=0` > /etc/modprobe.d/alsa-base.conf

 

fixes not just pops but also constant "ground loop" kind of speaker humming noises

JDisn
Beginner
898 Views

The best way to eliminate the ground-loop audio hum would be to use the toslink SPDI/F connector available on the Hades Canyon. However, I've had trouble getting that to function in upstream kernels (in the ALSA sub-system). If anybody solves that topic, please let me know.

Reply