Crackling and popping sound when using headphones

Bug #1648183 reported by Antony on 2016-12-07
This bug affects 23 people
Affects Status Importance Assigned to Milestone
alsa-driver (Arch Linux)
alsa-driver (Ubuntu)

Bug Description

Laptop is HP Pavilion - 15-au118tx. The laptop has B and O play and the output from speakers are just fine, when using headphones there is some kind of crackling and popping sound in both ears but prominently in the left ear.

The issue happens only when the sound is played, if i reduce the PCM way low using alsamixer, the effect is minimized but the volume is also reduced. Increasing the volume in the panel increases the PCM as well.

ProblemType: Bug
DistroRelease: Ubuntu 16.10
Package: alsa-base 1.0.25+dfsg-0ubuntu5
ProcVersionSignature: Ubuntu 4.8.0-30.32-generic 4.8.6
Uname: Linux 4.8.0-30-generic x86_64
NonfreeKernelModules: nvidia_uvm nvidia_drm nvidia_modeset nvidia
ApportVersion: 2.20.3-0ubuntu8
Architecture: amd64
 /dev/snd/controlC0: antony 1719 F.... pulseaudio
CurrentDesktop: Unity
Date: Wed Dec 7 23:30:05 2016
InstallationDate: Installed on 2016-11-20 (17 days ago)
InstallationMedia: Ubuntu 16.10 "Yakkety Yak" - Release amd64 (20161012.2)
PackageArchitecture: all
SourcePackage: alsa-driver
Symptom: audio
Symptom_AlsaPlaybackTest: ALSA playback test through plughw:PCH failed
Symptom_Card: Built-in Audio - HDA Intel PCH
Symptom_Jack: Black Headphone Out, Left
Symptom_Type: Digital clip or distortion, or "overdriven" sound
Title: [HP Pavilion Notebook, Realtek ALC295, Black Headphone Out, Left] Sound is distorted
UpgradeStatus: No upgrade log present (probably fresh install) 07/19/2016
dmi.bios.vendor: Insyde
dmi.bios.version: F.14
dmi.board.asset.tag: Type2 - Board Asset Tag 8216
dmi.board.vendor: HP
dmi.board.version: 83.13
dmi.chassis.type: 10
dmi.chassis.vendor: HP
dmi.chassis.version: Chassis Version
dmi.modalias: dmi:bvnInsyde:bvrF.14:bd07/19/2016:svnHP:pnHPPavilionNotebook:pvrType1ProductConfigId:rvnHP:rn8216:rvr83.13:cvnHP:ct10:cvrChassisVersion: HP Pavilion Notebook
dmi.product.version: Type1ProductConfigId
dmi.sys.vendor: HP
mtime.conffile..etc.modprobe.d.alsa-base.conf: 2016-12-07T23:12:52.939689

Antony (antonyjoseph) wrote :
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in alsa-driver (Ubuntu):
status: New → Confirmed
humble_coffee (humblecoffee) wrote :

I'm also experiencing this exact issue. While it doesn't happen all the time, it's sufficiently frequent and unpleasant that I just can't listen to music through the audio jack. It's still an issue using the 4.9 mainline kernel. Using a USB sound card makes the problems go away.

Same issue with HP Pavillion AU-111TX.

cassiodoroVicinetti (artghio) wrote :

Same issue with HP 15-au035nl.

Martin Evald (martin-evald) wrote :

Same issue with an ASUS ZenBook 3 UX390UA. I experience the issue as a volume dependent cross-talk between the channels, predominantly affecting the left channel when a medium volume sound is being played in the right channel, but to a lesser extent (lower volume of the cross-talk) affecting the right channel as well. Going by hearing the cross-talk seems to be 1-bit audio.

The common denominator seems to be the (newly supported) Realtek ALC295 driver:

humble_coffee (humblecoffee) wrote :

I don't see ALC295 appearing in any of my device descriptions anywhere. Here's my output of 'aplay --list-devices' ...

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: Generic Analog [Generic Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 1: CODEC [USB Audio CODEC], device 0: USB Audio [USB Audio]
  Subdevices: 0/1
  Subdevice #0: subdevice #0

Also, a link I posted on AskUbuntu with a bit more information:

Egor (egormkn) wrote :

Same issue with HP Pavilion 15-au027ur on Zesty beta 1
Codec: Realtek ALC295

M Lopha (loafgoats) wrote :

This might be a kernel issue and not just a problem with Ubuntu since I've had this exact same issue on an HP Envy 13 i5 Kaby Lake running ALC295 on pretty much every distro. Back when I'd dual boot, I used to boot into Windows before booting back into Linux to fix this problem and it worked on every distro. Now I have a machine with only Linux on it can't seem to make this issue go away. Here's a list of the audio devices used.

Audio device: Intel Corporation Device 9d71 (rev 21) (prog-if 80)
 Subsystem: Hewlett-Packard Company Device 82b9
 Flags: bus master, fast devsel, latency 32, IRQ 132
 Memory at a1328000 (64-bit, non-prefetchable) [size=16K]
 Memory at a1310000 (64-bit, non-prefetchable) [size=64K]
 Capabilities: <access denied>
 Kernel driver in use: snd_hda_intel
 Kernel modules: snd_hda_intel, snd_soc_skl

**** List of PLAYBACK Hardware Devices ****
card 0: PCH [HDA Intel PCH], device 0: ALC295 Analog [ALC295 Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 3: HDMI 0 [HDMI 0]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 7: HDMI 1 [HDMI 1]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: PCH [HDA Intel PCH], device 8: HDMI 2 [HDMI 2]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

Paul (polalbert) wrote :

Same problem with a brand new HP OMEN 15-AX212NF, same soundcard.
I can add that the dirty saturation seems to disappear when level is lower

Dominik Tews (ddominnik) wrote :

Same issue on HP Pavilion x360 u003ng.
(Sorry for German output)
00:1f.3 Audio device: Intel Corporation Sunrise Point-LP HD Audio (rev 21)
 Subsystem: Hewlett-Packard Company Sunrise Point-LP HD Audio
**** Liste der Hardware-Geräte (PLAYBACK) ****
Karte 0: PCH [HDA Intel PCH], Gerät 0: ALC295 Analog [ALC295 Analog]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 3: HDMI 0 [HDMI 0]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 7: HDMI 1 [HDMI 1]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0
Karte 0: PCH [HDA Intel PCH], Gerät 8: HDMI 2 [HDMI 2]
  Sub-Geräte: 1/1
  Sub-Gerät #0: subdevice #0

Robert Joynt (robertjjoynt) wrote :

I have the same issue on an HP Omen 15 notebook (15-ax201TX). I have a duel boot setup to Ubuntu 16.10 and Windows 10. If I boot into Windows 10 first (even just to the login screen) and then restart and boot into Ubuntu 16.10 the sound is fine - no crackling.

Julien Martin (julienwcs) wrote :

Hi everyone ! Same issue here with my HP Envy 13 kaby lake running with a single Mint boot. Codec Realtek ALC295 too. If I plug my headphones on a usb audio card everything is fine.

Nate Meyers (natedaswas) wrote :

Same issue with asus zenbook 3, same audio card. In addition the built in speaker output is broken, it can only be 0% or 100%, no in between. Seemingly related.

Nate Meyers (natedaswas) wrote :

This bug has been submitted to the linux kernel bug tracker as well

Yamato Reed (mashitoreed) wrote :

I've managed to fix partially the problem or at least I can narrow it down. So , if I override all my other audio lines via hdajackretask module and only enable the headphone one, the sound is perfect. What happens though when I turn back on the line for the Internal speakers , it goes back to crackling and popping in the internal speakers and headphones. So basically this allows the user to use EITHER internal speakers OR headphones , NOT both.

Robert Joynt (robertjjoynt) wrote :

I've managed to fix this problem on my machine (HP Omen 15 running Ubuntu 17.04 using codec for Realtek ALC295 sound device). To fix the problem, I can do the following:

Install alsa-tools if not installed:

sudo apt install alsa-tools

Create and save a script in /usr/local/bin:

hda-verb /dev/snd/hwC0D0 0x20 SET_COEF_INDEX 0x67
hda-verb /dev/snd/hwC0D0 0x20 SET_PROC_COEF 0x3000

Run the script as root in a terminal to immediately fix the problem.

To run the script on startup, use cron with the @reboot command:

sudo crontab -e

and then add line in crontab:
@reboot [full path to script]

To run script on resume from suspend, copy the script to /lib/systemd/system-sleep

For more technical details regarding this fix, see

cassiodoroVicinetti (artghio) wrote :

I confirm I fixed my problem thanks to robertjjoynt's suggestion!

Paul (polalbert) wrote :

Awesome !

I confirm I've solved the issue in Arch distro with an HP Omen 17-w209ns thanks to Robert Joynt!!

humble_coffee (humblecoffee) wrote :

Yep fixed for me also. That's fantastic, thanks heaps Robert!!

Kushal (kushal-pandya04) wrote :

Thanks a lot Robert, your fix worked for me on HP AU113TX as well! I hope this gets fixed in upcoming kernel updates as I don't see HP fixing it from their end in case it requires vendor fix.

whatonearth (whatonearth) wrote :

Unfortunately for me this fix hasn't worked given that the subwoofer and microphone on my Pavilion 15-aw054sa do not produce/record any sound. I, of course, have an ALC295 and I'm running Mint Sonya (which is based on Ubuntu). I have made two comments on the Bugzilla entry ( and nothing has happened regarding the bug. I have run alsa-tools after running Robert's fix and this is the result: (

Iwasanewt (iwasanewt) wrote :

Can confirm that Robert Joynt's solution worked on my HP Omen 15t X7R21AV running Kubuntu 17.04.

Celberune (celberune) wrote :

It's working ! It's working ! Great Thx to Robert Joynt's fix !
so many hours spent on this creepy sound...
Linux is a pain to configure...
And after it's magic to use.
Windows is magic to configure... and after a pain to use ;-)

Erikas (erikmnkl) wrote :

For those who wants a proper workaround using systemd - see

Marius Nestor (marius-nestor) wrote :

I confirm Robert Joynt's fix is working on HP Pavilion x360 Convertible 13-u103nq. Thanks Erikas for the systemd workaround, but let's hope it will be fixed soon upstream, especially that there's already a patch [1] in place.


Erikas (erikmnkl) wrote :

Slight updated SYSTEMD workaround script from my previous comment (used to fail on boot). See updated at

Wenduo Wang (wenduowang) wrote :

The solution by @robertjjoynt worked for me on 2017 HP Omen 15 with Linux Mint 18.2 with Kernel 4.10.0-27. It is MAGIC!

Paul (polalbert) wrote :

May I add that for me it's hwC1D0

You maybe should check what file exists in /dev/snd/

Erikas (erikmnkl) wrote :

Since we are talking about bash commands, shouldn't this be more elegant solution?

hda-verb /dev/snd/hwC[[:print:]]*D0 0x20 SET_COEF_INDEX 0x67
hda-verb /dev/snd/hwC[[:print:]]*D0 0x20 SET_PROC_COEF 0x3000

Just test it yourself:

ls -l /dev/snd/hwC[[:print:]]*D0

JM (josemesnaola) wrote :

The solution by @robertjjoynt worked for me on 2017 ASUS ZenBook 3 (ux490ua) with Debian 9 with Kernel 4.9.0-4.

Adrian Casais (adriancasais) wrote :

Same problem with HP Pavilion Power 15-cb. Kernel 4.10.0-38-generic. Although @robertjjoynt workaround WORKED for me also, I think this issue should be fixed from it's root...

Théo Besnard (snarkypupil) wrote :

First, thank's a lot to @robertjjoynt for the solution. It works also on my pc (Omen Pc by HP), however i can't find out how to run the script on start up. I think i've done a wrong thing on the crontab command. Could someone tell me the exactly things to write in the crontab script (my script name is and its directory is /usr/local/bin

Thanks a lot to the person who will answer me !

Théo Besnard (snarkypupil) wrote :

I fixed it myself. Cron wasn't running on start. I fixed it this way :
# update-rc.d cron defaults

Thanks again to @robertjjoynt

Erikas (erikmnkl) wrote :

I've updated script for systemd systems. It fixes comment #30 issue and now does not leave any error messages during boot (script issue):

Nate Graham (pointedstick) wrote :

The script worked for me too with an HP Spectre x360 13-w013dx.

Chris Raven (i5lic) wrote :

Whilst running ArchLinux, this bug seems to be resolved without the requirement of custom scripts, under kernel 4.15. Full details are below:

Linux UX430UA 4.15.5-1-ARCH #1 SMP PREEMPT Thu Feb 22 22:15:20 UTC 2018 x86_64 GNU/Linux
Pulseaudio 11.1

As per the update #36 by Erikas, he has updated the UX43UA and UX43UQ page for anyone running below this kernel, but I can confirm I did not apply that script on this installation, and it's working fine.

Erikas (erikmnkl) wrote :

Chris (#38) - try to put your computer to sleep and wake up while listening to something. Issue still persists, but once you plug out and plug in your headset - it returns back to normal volume as expected.

mehmet aslan (aslan-mehmet) wrote :

same issue with hp-cb007nt
Ubuntu 16.04.4 LTS
kernel 4.13.0-43-generic
solution #17 works
thanks robertjjoynt

MAI Anh Tuan (anhtuan-mai19) wrote :

the solution of @robertjjoynt doesn't work on ubuntu 18.04
my pc is HP Pavilion Power 15CB
card 0: PCH [HDA Intel PCH], device 0: ALC295 Analog [ALC295 Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

The solution by @robertjjoynt did *not* work for me.

Also, is there a way to revert changes produced by @robertjjoynt? Not that it's any different now, but don't want to mess around with settings if it doesn't fix the issue.

OS: Ubuntu 18.04
System: HP Elitebook 830 G5

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.