advancingu / XPS13Linux

Public collection of issues with running Linux on a Dell XPS 13 (2015 edition)
131 stars 3 forks source link

Headphone base noise level is very high #11

Closed gaborkr closed 9 years ago

gaborkr commented 9 years ago

On kernel 3.19, the soundcard has a very high level of base noise on the headphone output - much higher than anything I can compare it to. The noise is gone if I mute the output. I can play with alsamixer and change the microphone levels - if I mute the mic, the noise becomes even worse, with added intermittent chirping. The noise is the same regardless of the headphone type (headphone only / headset with mic).

This issue looks similar - maybe it can be fixed with a different configuration of the sound card. However, the background noise is present in Windows too. Correction: I can no longer detect the extra noise in Windows.

advancingu commented 9 years ago

Is this with the 2015 edition?

gaborkr commented 9 years ago

Yes, of course.

advancingu commented 9 years ago

I don't have this on my machine at all with stock Ubuntu 15.04 and BIOS A03.

dchambers commented 9 years ago

Could we add a Fixed in 15.04 label if it's definitely fixed in that release, so others looking to see the state of play with this laptop can more quickly see how things stand?

advancingu commented 9 years ago

@butabeka Which distribution and release is this occurring on?

gaborkr commented 9 years ago

Ubuntu 15.04 (3.19.0-16) with PulseAudio installed. BIOS A03. Just to make sure that this is a Linux problem, I rebooted to Windows (2x cold boot) and started playing "Dancing with the Moonlit Knight", which starts with Peter Gabriel singing, without any other instruments in the background. It played fine. Then rebooted to Linux (2x cold boot), started playing the same song. First there was no output, I had to open the volume controls and click on some tabs, then suddenly the sound was unmuted, and Peter Gabriel was singing again, with a very noticeable white noise in the background. I played around alsamixer and pulseaudio a lot, believe me, tried to change all possible mixer settings, but no luck.

advancingu commented 9 years ago

Are these headphones with an integrated microphone? Which type of connector/plug do your headphones use?

gaborkr commented 9 years ago

Both headphone (3-way jack connector) and headset (with a mic, 4-way connector) exhibit this behaviour. If I stop playing the song the noise remains, until I mute the output altogether (so it's not a player error - eg. wrong decoding of mp3 or too much amplification). I also have an external USB DAC which works just fine.

gaborkr commented 9 years ago

OK, this is funny: I think I found the fix. This is it.: Download and run this script (the alsa-tools package needs to be installed).

The funny part is that it is a fix for the previous version of the XPS 13... Also, it is for pre-3.16 kernels - I'm on 3.19... Now I'm scratching my head...

advancingu commented 9 years ago

Thanks for updating with a link to the fix. Good to hear you were able to resolve the issue. I'll close this for now.

dchambers commented 9 years ago

Good work @butabeka. Out of interest, did you upgrade to 15.04 or are you a fresh install?

gaborkr commented 9 years ago

@dchambers I experimented with Fedora 21 (beta?) and Ubuntu 14.04/14.10 about a month ago, then installed 15.04 as soon as it got released. I used Windows in the meantime.

dchambers commented 9 years ago

Right, but was it a fresh install rather an a dist upgrade from an earlier installation?

gaborkr commented 9 years ago

Fresh install. I also get the same behaviour when running from a Live USB.

soren121 commented 9 years ago

For what it's worth, I have the 2015 XPS 13 (9343) running Arch with kernel 4.0, and the above Python script fixes my audio. The white noise is greatly reduced and it removes the annoying oscillating noise.

I noticed that the kernel patch for the 9333 model is a quirk that specifically targets the ALC668 sound card used in that machine. Perhaps applying the same fix for the 9343's ALC288 chipset would work as well. I'm going to experiment with that.

webloem commented 9 years ago

I have the same problem. I ran the script, it (mostly) fixes the problem. After reboot the problem is back though, so will need to run this script on boot. A more permanent fix would be nice.

gaborkr commented 9 years ago

I started using powertop, and unfortunately, a side effect of turning the audio card on and off for power saving results in the noise coming back every time. This is really annoying...

soren121 commented 9 years ago

There's a patch available here: https://bugzilla.kernel.org/show_bug.cgi?id=99851

It fixed the noise issue for me, but I'd like for a few other people to test it as well to ensure it's resolved.

soren121 commented 9 years ago

Update: the patch is now queued for 4.1. Here's the commit.

gaborkr commented 9 years ago

This is great news and thank you for being proactive - I should have reported this a long time ago. I'm still on 3.19, waiting for 4.1 to be released (I hope it works with the XPS13 reasonably well now).

soren121 commented 9 years ago

Good news: it does. I've been running 4.1-rc6 for a while now with almost no problems. A bunch of driver patches made it in that fix audio, touchpad, and WiFi issues. The only outstanding problem is the H-sync loss when switching TTYs...it was fixed a few days ago but I don't think it'll be merged until the 4.2 window opens. There's a workaround, though-- check the Arch Wiki.

I've been having some trouble lately with suspend-on-lid-close and some oddities with right-clicking, but I'm not certain those are kernel-related. I need to look into those more.

-----Original Message----- From: "haspok" notifications@github.com Sent: ‎6/‎16/‎2015 4:06 AM To: "advancingu/XPS13Linux" XPS13Linux@noreply.github.com Cc: "Nicholas Narsing" soren121@sorenstudios.com Subject: Re: [XPS13Linux] Headphone base noise level is very high (#11)

This is great news and thank you for being proactive - I should have reported this a long time ago. I'm still on 3.19, waiting for 4.1 to be released (I hope it works with the XPS13 reasonably well now). — Reply to this email directly or view it on GitHub.

dchambers commented 9 years ago

A bunch of driver patches made it in that fix audio, touchpad, and WiFi issues.

Hi @soren121, are you able to provide more details regarding the touchpad and WiFI fixes in 4.1 that affect the XPS 13? Do you know if there's anything for the palm detection bug for example?

soren121 commented 9 years ago

Two notable bugs that were fixed:

https://bugs.freedesktop.org/show_bug.cgi?id=88903 https://bugzilla.kernel.org/show_bug.cgi?id=95941

EDIT: Regarding palm detection, this looks promising: https://bugzilla.kernel.org/show_bug.cgi?id=77161#c20

dchambers commented 9 years ago

Thanks @soren121, this is really helpful information. It's great to see how the community are helping to keep Dell's promises regarding Linux compatibility.

gaborkr commented 9 years ago

And the fix made it into 4.1, in the last minute: http://lkml.iu.edu/hypermail/linux/kernel/1506.2/04143.html

Takashi Iwai (3): (...) ALSA: hda - Fix noisy outputs on Dell XPS13 (2015 model)

gaborkr commented 9 years ago

4.1 status: microphone input is gone silent. @soren121 do you have the same problem?

(Removed: Also, with a headset (with a 4-way jack) the left output channel is much quieter than the right channel. Interestingly, stereo is fine when a normal headphone is plugged in. -> This might have been due to a broken headset...)

soren121 commented 9 years ago

Yes, I have the same problem. I'll take the blame for it, I was the one who tested the patch...

Someone else has reported the regression upstream on the same bug report, so hopefully we'll get another patch soon.

gaborkr commented 9 years ago

FYI 4.1.3 at last seems to have the mic patch applied (https://www.kernel.org/pub/linux/kernel/v4.x/ChangeLog-4.1.3 - "ALSA: hda - restore the MIC FIXUP for some Dell machines").

So if you want sound fully working but do not want to patch and compile a kernel for yourself you can now fetch 4.1.3 binary (or, if you are feeling lucky, any of the 4.2 RC versions...). 4.1 has been stable and problem free for me so far.