You are not logged in.

#1 2011-06-02 11:36:13

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

[Solved] Popping sound when laptop is on battery

Hello,

The only thing that doesn't work properly with Linux on my laptop is the sound: it popped on shutdown/reboot and sometimes after a sound has played. I managed to solve the popping on shutdown/reboot, but not the following issue:

When my laptop is on battery mode, I get a popping sound every time I played some music, watched a video or I get a sound-notification. Basically, I always get it after a sound has played. As soon as I plug my laptop into AC, the sound behaves normally. I assume this has something to do with a powersaving of some sort, but I don't know where and what to look for.

Is there anyone with a similar issue and knows a solution?

Last edited by Unia (2011-06-16 17:20:16)


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#2 2011-06-02 12:08:26

brebs
Member
Registered: 2007-04-03
Posts: 3,742

Re: [Solved] Popping sound when laptop is on battery

Maybe you want in /etc/modprobe.d/whatever.conf

options snd-hda-intel power_save=0

Offline

#3 2011-06-02 12:15:52

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

I tried placing that in /etc/modprobe.d/sound.conf and /etc/modprobe.d/modprobe.conf - both do not work.


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#4 2011-06-02 20:17:08

einhard
Member
From: Poland
Registered: 2010-01-05
Posts: 89

Re: [Solved] Popping sound when laptop is on battery

What audio codec your laptop have? (intel-hda?) Are you using alsa? Maybe you must specify your sound card model (intel-hda=/=intel-hda). Check model settings on wiki https://wiki.archlinux.org/index.php/Alsa

Are you using laptop-mode-tools? If yes, disable it for a while.

Check if /sys/module/snd_hda_intel/parameters/power_save (path may differ) is set to 0 on battery

Disable pm-utils quirk intel-audio-powersave. You can also disable rest and check then.

Offline

#5 2011-06-03 10:30:54

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

right, so I'm not sure whether I fully get what you're saying. Anyway, here's what I came up with:

einhard wrote:

What audio codec your laptop have? (intel-hda?) Are you using alsa? Maybe you must specify your sound card model (intel-hda=/=intel-hda). Check model settings on wiki https://wiki.archlinux.org/index.php/Alsa

I'm using alsa. Here's what lspci says:

┌─[jente@lappy][12:28:36] 
└─■ lspci | grep Audio
00:1b.0 Audio device: Intel Corporation 5 Series/3400 Series Chipset High Definition Audio (rev 05)
02:00.1 Audio device: ATI Technologies Inc Manhattan HDMI Audio [Mobility Radeon HD 5000 Series]

And here's what alsamixer says:

Card: HDA Intel                                  
Chip: Realtek ALC272X 

Is that of any use perhaps?

einhard wrote:

Are you using laptop-mode-tools? If yes, disable it for a while.

Nope, not using that.

einhard wrote:

Check if /sys/module/snd_hda_intel/parameters/power_save (path may differ) is set to 0 on battery

It's set to 0

einhard wrote:

Disable pm-utils quirk intel-audio-powersave. You can also disable rest and check then.

What do you mean by that?


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#6 2011-06-03 18:14:41

einhard
Member
From: Poland
Registered: 2010-01-05
Posts: 89

Re: [Solved] Popping sound when laptop is on battery

Could you give output from /etc/asound.conf and ~/.asoundrc (if exists). I think this problem may be related to dmix.

pm-utils is power management solution. It has hooks which are activated on battery. You can disable them by creating an empty file with hook name in /etc/pm/power.d/. Hooks are in /usr/lib/pm-utils/power.d. If you want to disable intel-audio-powersave hook just type

# touch /etc/pm/power.d/intel-audio-powersave

Try disabling all hooks to find out if it's the cause of this issue. Excluding pm-utils, laptop-mode-tools and DM power managers (kde powerdevil, gnome power manager, etc.) relation to powersaving is very slim.

What power management solutions are you using?

I don't know what kind of notebook you have, so you can also try

options snd-hda-intel model=your_card_model

in /etc/modprobe.d/modprobe.conf or /etc/modprobe.d/sound.conf. Model list: http://www.kernel.org/doc/Documentation … Models.txt

As a last resort you can install pulseaudio to find out if it's alsa configuration problem.

Could you explain also what exactly "popping sound" mean to you? Do you get some brief distortions when you start playing sounds, stuttering whole time, high pitched sound(s), or maybe something else?

How have you managed to solve the popping on shutdown/reboot?

Last edited by einhard (2011-06-03 19:19:50)

Offline

#7 2011-06-05 12:29:16

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

einhard wrote:

Could you give output from /etc/asound.conf and ~/.asoundrc (if exists). I think this problem may be related to dmix.

I don't have any of those files.

einhard wrote:

pm-utils is power management solution. It has hooks which are activated on battery. You can disable them by creating an empty file with hook name in /etc/pm/power.d/. Hooks are in /usr/lib/pm-utils/power.d. If you want to disable intel-audio-powersave hook just type

# touch /etc/pm/power.d/intel-audio-powersave

Try disabling all hooks to find out if it's the cause of this issue. Excluding pm-utils, laptop-mode-tools and DM power managers (kde powerdevil, gnome power manager, etc.) relation to powersaving is very slim.

I'll try that if your other suggestion (see below) won't work.

einhard wrote:

What power management solutions are you using?

I'm using cpufrequtils and gnome-power-manager

einhard wrote:

I don't know what kind of notebook you have, so you can also try

options snd-hda-intel model=your_card_model

in /etc/modprobe.d/modprobe.conf or /etc/modprobe.d/sound.conf. Model list: http://www.kernel.org/doc/Documentation … Models.txt

I'll let you know how this works after a reboot!

einhard wrote:

As a last resort you can install pulseaudio to find out if it's alsa configuration problem.

Could you explain also what exactly "popping sound" mean to you? Do you get some brief distortions when you start playing sounds, stuttering whole time, high pitched sound(s), or maybe something else?

How have you managed to solve the popping on shutdown/reboot?

I'd rather not install pulseaudio again, I've had it installed when I had GNOME3 installed and the popping sound was still there. The popping sound is like my speakers are blowing up, can't really describe it. I solved the popping on shutdown/reboot by placing modprobe -r snd-hda-intel in /etc/rc.local.shutdown.

EDIT: Seems like your solution worked. However, I had the popping sound from a Compiz standalone session and I'm now working from subtle. I'll log into Compiz some time later and check again, so I won't add [Solved] just yet.

Last edited by Unia (2011-06-05 12:34:39)


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#8 2011-06-05 13:02:26

Awebb
Member
Registered: 2010-05-06
Posts: 6,275

Re: [Solved] Popping sound when laptop is on battery

It might be a driver problem, I once had such sound problems after a kernel update and after the next update they were gone.

Offline

#9 2011-06-05 13:27:45

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

Awebb wrote:

It might be a driver problem, I once had such sound problems after a kernel update and after the next update they were gone.

I've had this popping sound on various distro's and various kernels.


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#10 2011-06-05 14:20:24

einhard
Member
From: Poland
Registered: 2010-01-05
Posts: 89

Re: [Solved] Popping sound when laptop is on battery

Unia wrote:

EDIT: Seems like your solution worked. However, I had the popping sound from a Compiz standalone session and I'm now working from subtle. I'll log into Compiz some time later and check again, so I won't add [Solved] just yet.

So what have worked? Model adjustment? There are many types of intel-hda audio codecs and they are often causing problems regardless of operating system.

I have one more idea, Could you mute every channel and check if this "popping" happens? Do you store your mixer settings (alsa in rc.conf and /var/lib/alsa/asound.state)? This may be related to initialization of alsa.

I you don't necessary need alsa you can check OSS4, in my opinion it shouldn't have this kind of problems and it's superior to alsa in many ways (at least on supported cards)

Offline

#11 2011-06-05 14:20:52

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

Nope, on Compiz I still have it.. Gonna check on subtle now to make sure if it's related to the compiz session.

EDIT: weird.. on subtle I don't have the popping sound. That would somehow make it related to the compiz session only. Any ideas?

EDIT2: It's probably related to gnome-power-manager and whatever services that runs. I do use that in Compiz, but didn't launch it in subtle. When I launch it in subtle, the popping sound plays on subtle too. I think this might then be related to the package gnome-settings-daemon-nopulse that I installed via the AUR. This package doesn't have pulseaudio as a dependency so I can install the GNOME3 stuff without having to use pulseaudio. I'll remove gnome-power-manager from my Compiz autostart file and check from the Compiz session again.

EDIT:3 So launching the Compiz session without gnome-power-manager didn't work, the popping sound is still there. I do launch gnome-settings-daemon however, so that might be it. Will install the official gnome-settings-daemon with pulseaudio now and check again.

EDIT4: Nope, that didn't solve it either. Still have it with pulseaudio and the official gnome-settings-daemon. I'm clueless as for what to do next. Anyone?

Last edited by Unia (2011-06-05 14:40:20)


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#12 2011-06-05 14:50:06

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

einhard wrote:
Unia wrote:

EDIT: Seems like your solution worked. However, I had the popping sound from a Compiz standalone session and I'm now working from subtle. I'll log into Compiz some time later and check again, so I won't add [Solved] just yet.

So what have worked? Model adjustment? There are many types of intel-hda audio codecs and they are often causing problems regardless of operating system.

I have one more idea, Could you mute every channel and check if this "popping" happens? Do you store your mixer settings (alsa in rc.conf and /var/lib/alsa/asound.state)? This may be related to initialization of alsa.

I you don't necessary need alsa you can check OSS4, in my opinion it shouldn't have this kind of problems and it's superior to alsa in many ways (at least on supported cards)

Muting every channel didn't work either and adding the model type to modprobe.conf didn't work either after all. It's something with my Compiz session (and I think something GNOME related) that brings up the popping, because when I reboot into subtle I don't have it.


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

#13 2011-06-16 17:19:57

Unia
Member
From: Stockholm, Sweden
Registered: 2010-03-30
Posts: 2,486
Website

Re: [Solved] Popping sound when laptop is on battery

Just performed a complete reinstall with as little gnome dependencies as possible. The popping sound when on battery is now gone. Still haven't figured out what package caused it, but I'm happy I don't have it anymore smile


If you can't sit by a cozy fire with your code in hand enjoying its simplicity and clarity, it needs more work. --Carlos Torres

Offline

Board footer

Powered by FluxBB