Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
Crispy, crackling, distorted, terrible sound (if any at all)
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Multimedia
View previous topic :: View next topic  
Author Message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Sat Apr 25, 2015 11:40 pm    Post subject: Crispy, crackling, distorted, terrible sound (if any at all) Reply with quote

Hi....

I have been beating my head against this so long now I cannot see straight. The sound on my PC will not work right. Instead of playing normal audio, all I hear are crispy, cracking sounds where the music or sounds spike. If the music or sounds have no high point (db historgram), then I just don't hear anything.

I have been looking all over the place in the gentoo forums and all over the Internet, and I've tried a million different options... my head is spinning.

My system has 3 sound devices, and all of them use snd-hda-intel -- making this more complicated. I would happily disable two of them if I only knew how. Blacklisting won't work, because they all use the same module. I don't know if the cracking has something to do with the fact that this module is shared with 3 cards, or if it is something else -- but just to simplify things, I think it would be best if I could just disable 2 of them.

I don't think this is a pulse issue. I think it is an alsa issue. I seem to get the cracking even on the command line using speaker-test.

/proc/asound/cards:
Code:
 0 [HDMI           ]: HDA-Intel - HDA Intel HDMI
                      HDA Intel HDMI at 0xf7914000 irq 29
 1 [PCH            ]: HDA-Intel - HDA Intel PCH
                      HDA Intel PCH at 0xf7910000 irq 30
 2 [NVidia         ]: HDA-Intel - HDA NVidia
                      HDA NVidia at 0xf7080000 irq 31


/etc/modules.d/alsa.conf:
Code:
alias char-major-116 snd
alias char-major-14 soundcore


alias sound-service-0-0 snd-mixer-oss
alias sound-service-0-1 snd-seq-oss
alias sound-service-0-3 snd-pcm-oss
alias sound-service-0-8 snd-seq-oss
alias sound-service-0-12 snd-pcm-oss

alias /dev/mixer snd-mixer-oss
alias /dev/dsp snd-pcm-oss
alias /dev/midi snd-seq-oss

options snd cards_limit=3
options snd-hda-intel enable=0 index=0 model=auto vid=8086 pid=8c20
options snd-hda-intel enable=0 index=0 model=auto vid=8086 pid=8ca0
options snd-hda-intel enable=1 index=0 model=auto vid=10de pid=0fbb

/etc/asound.conf
Code:
pcm.!default {
        type hw
        card 1
}

ctl.!default {
        type hw
        card 1
}


My user's .asoundrc:
Code:
defaults.ctl.card 1
defaults.pcm.card 1
defaults.pcm.device 0


And for good measure, my lspci:
Code:
01:00.1 Audio device: NVIDIA Corporation Device 0fbb (rev a1)
        Subsystem: Gigabyte Technology Co., Ltd Device 3683
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin B routed to IRQ 31
        Region 0: Memory at f7080000 (32-bit, non-prefetchable) [size=16K]
        Capabilities: [60] Power Management version 3
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst+ PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [68] MSI: Enable+ Count=1/1 Maskable- 64bit+
                Address: 00000000feeff00c  Data: 4182
        Capabilities: [78] Express (v2) Endpoint, MSI 00
                DevCap: MaxPayload 256 bytes, PhantFunc 0, Latency L0s unlimited, L1 <64us
                        ExtTag+ AttnBtn- AttnInd- PwrInd- RBE+ FLReset-
                DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
                        RlxdOrd- ExtTag+ PhantFunc- AuxPwr- NoSnoop+
                        MaxPayload 256 bytes, MaxReadReq 512 bytes
                DevSta: CorrErr+ UncorrErr- FatalErr- UnsuppReq- AuxPwr- TransPend-
                LnkCap: Port #0, Speed 8GT/s, Width x16, ASPM L0s L1, Latency L0 <1us, L1 <4us
                        ClockPM+ Surprise- LLActRep- BwNot-
                LnkCtl: ASPM Disabled; RCB 64 bytes Disabled- Retrain- CommClk+
                        ExtSynch- ClockPM+ AutWidDis- BWInt- AutBWInt-
                LnkSta: Speed 8GT/s, Width x16, TrErr- Train- SlotClk+ DLActive- BWMgmt- ABWMgmt-
                DevCap2: Completion Timeout: Range AB, TimeoutDis+, LTR+, OBFF Via message
                DevCtl2: Completion Timeout: 50us to 50ms, TimeoutDis-, LTR-, OBFF Disabled
                LnkSta2: Current De-emphasis Level: -3.5dB, EqualizationComplete-, EqualizationPhase1-
                         EqualizationPhase2-, EqualizationPhase3-, LinkEqualizationRequest-
        Kernel driver in use: snd_hda_intel
        Kernel modules: snd_hda_intel
00:1b.0 Audio device: Intel Corporation 9 Series Chipset Family HD Audio Controller
        Subsystem: Gigabyte Technology Co., Ltd Device a0b2
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin A routed to IRQ 30
        Region 0: Memory at f7910000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: [50] Power Management version 2
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=55mA PME(D0+,D1-,D2-,D3hot+,D3cold+)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [60] MSI: Enable+ Count=1/1 Maskable- 64bit+
                Address: 00000000feeff00c  Data: 4162
        Capabilities: [70] Express (v1) Root Complex Integrated Endpoint, MSI 00
                DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s <64ns, L1 <1us
                        ExtTag- RBE- FLReset+
                DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
                        RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop+
                        MaxPayload 128 bytes, MaxReadReq 128 bytes
                DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr+ TransPend-
                LnkCap: Port #0, Speed unknown, Width x0, ASPM unknown, Latency L0 <64ns, L1 <1us
                        ClockPM- Surprise- LLActRep- BwNot-
                LnkCtl: ASPM Disabled; Disabled- Retrain- CommClk-
                        ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
                LnkSta: Speed unknown, Width x0, TrErr- Train- SlotClk- DLActive- BWMgmt- ABWMgmt-
        Capabilities: [100 v1] Virtual Channel
                Caps:   LPEVC=0 RefClk=100ns PATEntryBits=1
                Arb:    Fixed- WRR32- WRR64- WRR128-
                Ctrl:   ArbSelect=Fixed
                Status: InProgress-
                VC0:    Caps:   PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
                        Arb:    Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
                        Ctrl:   Enable+ ID=0 ArbSelect=Fixed TC/VC=01
                        Status: NegoPending- InProgress-
                VC1:    Caps:   PATOffset=00 MaxTimeSlots=1 RejSnoopTrans-
                        Arb:    Fixed- WRR32- WRR64- WRR128- TWRR128- WRR256-
                        Ctrl:   Enable+ ID=2 ArbSelect=Fixed TC/VC=04
                        Status: NegoPending- InProgress-
        Kernel driver in use: snd_hda_intel
        Kernel modules: snd_hda_intel

00:03.0 Audio device: Intel Corporation Xeon E3-1200 v3/4th Gen Core Processor HD Audio Controller (rev 06)
        Subsystem: Intel Corporation Device 2010
        Control: I/O- Mem+ BusMaster+ SpecCycle- MemWINV- VGASnoop- ParErr- Stepping- SERR- FastB2B- DisINTx+
        Status: Cap+ 66MHz- UDF- FastB2B- ParErr- DEVSEL=fast >TAbort- <TAbort- <MAbort- >SERR- <PERR- INTx-
        Latency: 0, Cache Line Size: 64 bytes
        Interrupt: pin A routed to IRQ 29
        Region 0: Memory at f7914000 (64-bit, non-prefetchable) [size=16K]
        Capabilities: [50] Power Management version 2
                Flags: PMEClk- DSI- D1- D2- AuxCurrent=0mA PME(D0-,D1-,D2-,D3hot-,D3cold-)
                Status: D0 NoSoftRst- PME-Enable- DSel=0 DScale=0 PME-
        Capabilities: [60] MSI: Enable+ Count=1/1 Maskable- 64bit-
                Address: feeff00c  Data: 4142
        Capabilities: [70] Express (v1) Root Complex Integrated Endpoint, MSI 00
                DevCap: MaxPayload 128 bytes, PhantFunc 0, Latency L0s unlimited, L1 unlimited
                        ExtTag- RBE- FLReset+
                DevCtl: Report errors: Correctable- Non-Fatal- Fatal- Unsupported-
                        RlxdOrd- ExtTag- PhantFunc- AuxPwr- NoSnoop+
                        MaxPayload 128 bytes, MaxReadReq 128 bytes
                DevSta: CorrErr- UncorrErr- FatalErr- UnsuppReq- AuxPwr- TransPend-
                LnkCap: Port #0, Speed unknown, Width x0, ASPM unknown, Latency L0 <64ns, L1 <1us
                        ClockPM- Surprise- LLActRep- BwNot-
                LnkCtl: ASPM Disabled; Disabled- Retrain- CommClk-
                        ExtSynch- ClockPM- AutWidDis- BWInt- AutBWInt-
                LnkSta: Speed unknown, Width x0, TrErr- Train- SlotClk- DLActive- BWMgmt- ABWMgmt-
        Kernel driver in use: snd_hda_intel
        Kernel modules: snd_hda_intel




I have tried a million permutations in all of the files. For a while, it even seemed to be working... but for no explicable reason. I turned on the PC today, and the sound sucks again. I made absolutely no changes in configuration between when it last worked, and this morning. The only thing I can think of is that I plugged a set of USB headphones in for a couple minutes...

I would have assumed that this was soft support in the kernel, or even bad hardware... but I know the hardware is good, because it works under Windows (dual boot system). I know the sound can work under linux, because it did for a few weeks there.

If anyone can offer any advice on how to simplify, troubleshoot (and if there is a God), fix this, I'd be most appreciative.

Thank you.

G
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
haarp
Guru
Guru


Joined: 31 Oct 2007
Posts: 535

PostPosted: Sun May 31, 2015 2:40 pm    Post subject: Re: Crispy, crackling, distorted, terrible sound (if any at Reply with quote

grooveman wrote:
I don't think this is a pulse issue. I think it is an alsa issue. I seem to get the cracking even on the command line using speaker-test.

speaker-test still uses pulse if available, as pulse provides an alsa wrapper.

To make sure: chmod -x /usr/bin/pulseaudio; killall pulseaudio, then try again. It should directly be using ALSA now.
Back to top
View user's profile Send private message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Sun May 31, 2015 5:41 pm    Post subject: Re: Crispy, crackling, distorted, terrible sound (if any at Reply with quote

haarp wrote:

speaker-test still uses pulse if available, as pulse provides an alsa wrapper.

To make sure: chmod -x /usr/bin/pulseaudio; killall pulseaudio, then try again. It should directly be using ALSA now.


Thank you. I will give that a try... sound is miraculously working again for the time being... though I don't know for how long... I will keep this trick in mind for the next time it goes wonky on me.

Thanks.

G
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
haarp
Guru
Guru


Joined: 31 Oct 2007
Posts: 535

PostPosted: Sun May 31, 2015 5:44 pm    Post subject: Reply with quote

I actually found this thread because I had a similar problem. Crackly sound that appeared randomly after a reboot. It only happened through Pulseaudio, hence the suggestion of trying without if you get this problem again.

For me, it also randomly disappeared again. Hell knows what that was :/ Pulseaudio, eh...
Back to top
View user's profile Send private message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Sun May 31, 2015 5:49 pm    Post subject: Reply with quote

I really think it is related to multiple sound cards of the same type.... I wish I knew how to turn them off. I only need one. But I cannot seem to find any help with that either. It is easy if they use a different driver, but when they use the same driver... I don't know. I have tried different suggestions I found from googling, but they never worked.
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
tclover
Guru
Guru


Joined: 10 Apr 2011
Posts: 516

PostPosted: Sun May 31, 2015 8:19 pm    Post subject: Reply with quote

First, the last options in alsa.conf are not reliable at all even if one can find theme anywhere. I tried to set card order and such with that and got no sound in return.
Second, I did not know the `defaults' keyword nor that maner to set up device/card with `.card' suffix. Again try something simpler and common for this kind of issue. Again, try to group everything in ~/.asoundrc and output directy to specific device with an app to test everything beforehand without any fancy option. Lastly using`type hw; card PCH' would reliably select a card without any uncertainty.
_________________
home/:mkinitramfs-ll/:supervision/:e-gtk-theme/:overlay/
Back to top
View user's profile Send private message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Wed Jun 03, 2015 12:08 am    Post subject: Re: Crispy, crackling, distorted, terrible sound (if any at Reply with quote

haarp wrote:
grooveman wrote:
I don't think this is a pulse issue. I think it is an alsa issue. I seem to get the cracking even on the command line using speaker-test.

speaker-test still uses pulse if available, as pulse provides an alsa wrapper.

To make sure: chmod -x /usr/bin/pulseaudio; killall pulseaudio, then try again. It should directly be using ALSA now.


OK. I tried this, and ruled out pulse. Still not working.

tclover, I'm not sure I follow you... can you give me an example?

Thanks.

G
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
tclover
Guru
Guru


Joined: 10 Apr 2011
Posts: 516

PostPosted: Thu Jun 04, 2015 8:26 am    Post subject: Re: Crispy, crackling, distorted, terrible sound (if any at Reply with quote

grooveman wrote:
tclover, I'm not sure I follow you... can you give me an example?

Well, first your `/etc/modprobe.d/alsa.conf' could be faulty here because of the last line: setting card order like that is not reliable (at least I had issues in the past.)

Second, your ~/.asoundrc uses line like `defaults.ctl.card 1' which I did not know... nor the `defaults' keyword. (Is this a new way to configure sound cards?)
Anyway, your might use some sanitized/legacy-syntax to configure the sound card first; and second, use a simple and single file to do so (~/.asoundrc) to be able to debug.

Third, you can use card name instead of id to be keep a consistent setting even if the order of card change with `type hw; card PCH' syntax.

Lastly, as it seems you have the same integrated audio chip as what I use, you could grab my `~/.asoundrc' and set the default to DMixer instead... by following my sig./dotfiles for the sake of using something tested (with JACK/DMix/Zita...) everything works with Intel-HDA audio card--just choose a default: DMixer for you.

Last resort approach is to switch to OSSv4 (an ebuild is available in sig./bar-overlay or the intertubes (search in gpo.zugaina.org).)
_________________
home/:mkinitramfs-ll/:supervision/:e-gtk-theme/:overlay/
Back to top
View user's profile Send private message
VoidMage
Watchman
Watchman


Joined: 14 Oct 2006
Posts: 6196

PostPosted: Thu Jun 04, 2015 11:22 am    Post subject: Re: Crispy, crackling, distorted, terrible sound (if any at Reply with quote

tclover wrote:
Second, your ~/.asoundrc uses line like `defaults.ctl.card 1' which I did not know... nor the `defaults' keyword. (Is this a new way to configure sound cards?)
Anyway, your might use some sanitized/legacy-syntax to configure the sound card first; and second, use a simple and single file to do so (~/.asoundrc) to be able to debug.


It's not a new one, it's actually the far more sane one than that cargo-culted snippet in /etc/asound.conf (though I'm not sure if defaults.pcm.device line is needed).

I kind of wonder if all of those option lines in /etc/modules.d/alsa.conf are getting applied or is it simply that the last one wins...
Did you try without that /etc/asound.conf snippet ?
Back to top
View user's profile Send private message
grooveman
Veteran
Veteran


Joined: 24 Feb 2003
Posts: 1217

PostPosted: Sat Jun 27, 2015 1:19 pm    Post subject: Reply with quote

Ok... something weird is going on here, but at least I have learned that there is a pattern here.

The sound problems only occur when I boot to my windows 8 partition, then reboot (soft boot) into linux. If I'm using windows and do s full shutdown, then restart the computer, this problem does not occur. How weird is that?
_________________
To look without without looking within is like looking without without looking at all.
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Multimedia All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum