Bug 505010 - PulseAudio does not work with EMU10K1X
PulseAudio does not work with EMU10K1X
Status: CLOSED CURRENTRELEASE
Product: Fedora
Classification: Fedora
Component: kernel (Show other bugs)
11
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Kernel Maintainer List
Fedora Extras Quality Assurance
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2009-06-10 07:18 EDT by Michael Chapman
Modified: 2009-12-17 10:26 EST (History)
10 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2009-12-17 10:26:07 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
"pulseaudio -vvvv" log (57.97 KB, text/plain)
2009-06-10 07:18 EDT, Michael Chapman
no flags Details
"alsa-info" output (27.77 KB, text/plain)
2009-06-10 07:19 EDT, Michael Chapman
no flags Details
pulseaudio -vvvv log (25.21 KB, text/plain)
2009-07-08 18:21 EDT, Richard Jolly
no flags Details
alsa-info output (20.50 KB, text/plain)
2009-07-08 18:22 EDT, Richard Jolly
no flags Details
pulseaudio -vvvv output for tsched=0 (50.84 KB, text/plain)
2009-09-09 08:21 EDT, Hans Otten
no flags Details
pulseaudio -vvvv output for tsched=1 (57.40 KB, text/plain)
2009-09-09 08:23 EDT, Hans Otten
no flags Details
{alsa,pulseaudio,kernel} package versions (922 bytes, text/plain)
2009-09-09 08:26 EDT, Hans Otten
no flags Details
output of alsa-info (20.99 KB, text/plain)
2009-09-09 08:27 EDT, Hans Otten
no flags Details

  None (edit)
Description Michael Chapman 2009-06-10 07:18:32 EDT
Created attachment 347201 [details]
"pulseaudio -vvvv" log

Description of problem:

After upgrading to F11, PulseAudio no longer works properly with my SB Live Value sound card, which uses the snd-emu10k1x driver. The symptoms are that when PulseAudio clients connect to the server, they either hang or immediately drop their connection. No audio is produced.

The card and driver functions correctly when ALSA is used directly.

Version-Release number of selected component (if applicable):

pulseaudio-0.9.15-11.fc11.i586
kernel-2.6.29.4-167.fc11.i586

How reproducible: Always.

Additional info:

I've attached two log files.

pulseaudio-debug.txt is the output from "pulseaudio -vvvv". During this test run I used paplay to play a WAV file twice. With the first connection paplay hung and had to be killed. With the second connection paplay exited immediately.

alsa-info.txt is the output from "alsa-info".
Comment 1 Michael Chapman 2009-06-10 07:19:27 EDT
Created attachment 347202 [details]
"alsa-info" output
Comment 2 Richard Jolly 2009-07-08 18:12:46 EDT
Can I also add that I have a similar problem. The only difference appears that pulseaudio believes it is working - when I run rhythmbox the mp3 songs appear they are playing - but no sound. Running the Pulseaudio manager indicates that the default sink is "auto_null".

My PC has been like this since I did a fresh install of F11. Previously Pulseaudio on F10 worked perfectly. No Hardware has changed. Like Michael I will upload the same attachments for my machine. The only difference is that pulseaudio does not crash - I stop it because it does produce any sound!!!

This is very frustrating

kernel-2.6.29.5-191.fc11.i686.PAE
pulseaudio-0.9.15-14.fc11.i586

lsmod - snd_emu10k1x loaded
Comment 3 Richard Jolly 2009-07-08 18:21:37 EDT
Created attachment 350997 [details]
pulseaudio -vvvv log
Comment 4 Richard Jolly 2009-07-08 18:22:23 EDT
Created attachment 350998 [details]
alsa-info output
Comment 5 Hans Otten 2009-07-19 10:39:10 EDT
Here is a 'me too'. I have a Dell 4550 (Pentium 4 2.40 GHz / 1GB RAM / Dell Sound Blaster Live! Value (aka EMU10K1X)).

I've tried adding the "tsched=0" setting to the "load-module module-hal-detect" line in default.pa as mentioned here: <http://pulseaudio.org/wiki/BrokenSoundDrivers>, but this gives me the behaviour Richard Jolly describes above: for some reason no SINK is created for the sound card (but a SOURCE is!). At the end of startup PulseAudio determines that no SINKs have been created and subsequently creates the NULL SINK.

When I use the "tsched=1" setting I get the behaviour reported by Michael Chapman above: looping sounds. As an added bonus when I change the "Output volume" setting in the "Sound Preferences" dialog/applet/whatever I can skip forward through the loops being played and at some volume settings playback even completes although the sound output is now scratchy instead of loopy ;-)

Judging from some comments I've seen on the web the PulseAudio maintainer seems to be of the opinion that the sound driver is broken and that it is the fault of ALSA. While this may be true for "tsched=1" this isn't true for "tsched=0". In that case the fault lies entirely with PulseAudio IMHO.

OK, now I've got that off my chest: if there is anything I can do to help, please let me know.
Comment 6 Michael Wiktowy 2009-07-28 16:40:19 EDT
I get this same problem on one of my Dell Optiplex boxes too. The sound card also identifies itself as a Sound Blaster Live! Value using EMU10K1X module.
Comment 7 Richard Jolly 2009-08-05 10:44:27 EDT
It comes as no surprise that my PC is a Dell (4500 Dimension). Same sound-card on the Dimensions and Optiplex ranges?
Comment 8 Hans Otten 2009-08-30 08:23:08 EDT
I just finished some additional testing and the results suggest the problem does indeed lie with ALSA and not PulseAudio. 

I compared playing back a sound file through PulseAudio and through native ALSA. Both can be done with the help of the 'aplay' command which is part of the alsa-utils package.

When I playback the sound using PulseAudio I get:

[hans@random ~]$ time aplay -D pulse ~/tmp/desktop-login.wav 
Playing WAVE '/home/hans/tmp/desktop-login.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo

real	0m1.439s
user	0m0.021s
sys	0m0.020s

(and the sound is chopped up BTW)

When I playback using native ALSA I get:

[hans@random ~]$ pulseaudio -k ; time aplay -D plug:front ~/tmp/desktop-login.wav 
Playing WAVE '/home/hans/tmp/desktop-login.wav' : Signed 16 bit Little Endian, Rate 44100 Hz, Stereo
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.511 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.508 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.510 ms long)
underrun!!! (at least 8.511 ms long)
underrun!!! (at least 8.509 ms long)
underrun!!! (at least 8.510 ms long)

real	0m1.689s
user	0m0.022s
sys	0m0.010s

(and the sound is also chopped up. 'pulseaudio -k' is needed to free up the sound device)

BTW: the file desktop-login.wav is the desktop-login.ogg file from /usr/share/sounds/freedesktop/stereo converted to wav (aplay doesn't understand ogg files). Also note that file is supposed to take about 4 seconds to playback, not 1.7s.

My machine was updated yesterday which means the relevant packages have the following versions:
pulseaudio-libs-0.9.15-14.fc11.i586
pulseaudio-libs-glib2-0.9.15-14.fc11.i586
alsa-lib-1.0.20-1.fc11.i586
pulseaudio-utils-0.9.15-14.fc11.i586
kerneloops-0.12-5.fc11.i586
alsa-utils-1.0.20-3.fc11.i586
alsa-lib-devel-1.0.20-1.fc11.i586
pulseaudio-0.9.15-14.fc11.i586
pulseaudio-module-x11-0.9.15-14.fc11.i586
pulseaudio-module-gconf-0.9.15-14.fc11.i586
pulseaudio-esound-compat-0.9.15-14.fc11.i586
xine-lib-pulseaudio-1.1.16.3-2.fc11.i586
alsa-plugins-pulseaudio-1.0.20-2.fc11.i586
kernel-devel-2.6.29.6-217.2.3.fc11.i586
kernel-2.6.29.6-217.2.3.fc11.i586
pulseaudio-libs-zeroconf-0.9.15-14.fc11.i586
pulseaudio-libs-devel-0.9.15-14.fc11.i586
bluez-alsa-4.42-3.fc11.i586
kernel-devel-2.6.29.6-217.2.8.fc11.i586
kernel-2.6.29.6-217.2.8.fc11.i586
kernel-firmware-2.6.29.6-217.2.16.fc11.noarch
kernel-devel-2.6.29.6-217.2.16.fc11.i586
kernel-headers-2.6.29.6-217.2.16.fc11.i586
kernel-doc-2.6.29.6-217.2.16.fc11.noarch
kernel-2.6.29.6-217.2.16.fc11.i586

So, can somebody please close this bug and redirect it to ALSA?
Comment 9 Hans Otten 2009-09-09 08:20:03 EDT
Well, I just updated the software on my computer and was delighted to see updates for ALSA, PulseAudio and the Linux kernel come rolling in. So I thought: let's perform the test I did for comment #8 again.

The result this time is that ALSA plays back the sound correctly while playback through PulseAudio is chopped up when using tsched=1. When using tsched=0 creation of a playback device through the hardware fails for some reason and the Null output device is used.

I'll create attachments for the following:
1. pulseaudio -vvvv output with tsched=0
2. pulseaudio -vvvv output with tsched=1
3. version information for all packages with alsa, pulseaudio or kernel in the package name
4. output of alsa-info
Comment 10 Hans Otten 2009-09-09 08:21:14 EDT
Created attachment 360198 [details]
pulseaudio -vvvv output for tsched=0
Comment 11 Hans Otten 2009-09-09 08:23:10 EDT
Created attachment 360199 [details]
pulseaudio -vvvv output for tsched=1
Comment 12 Hans Otten 2009-09-09 08:26:42 EDT
Created attachment 360200 [details]
{alsa,pulseaudio,kernel} package versions
Comment 13 Hans Otten 2009-09-09 08:27:08 EDT
Created attachment 360201 [details]
output of alsa-info
Comment 14 Adam Williamson 2009-10-20 14:27:58 EDT
Is this still happening with current F11 kernels? Also, could you check how it behaves in Fedora 12 Beta, released today? Just trying with the live CD would be fine. That'll help us tell whether it got fixed in more recent kernel / ALSA releases.

-- 
Fedora Bugzappers volunteer triage team
https://fedoraproject.org/wiki/BugZappers
Comment 15 Hans Otten 2009-10-31 08:46:23 EDT
In response to comment #14: yes, for me it is still happening with current F11 kernels. However, it does seem to be fixed in the F12 releases. Just tested F12 Beta (i686-Live) and sound is coming through OK.
Comment 16 Adam Williamson 2009-10-31 15:20:01 EDT
Thanks - so, Jaroslav, looks like this is fixed in later ALSA, if you have time to backport a fix to F11 it'd be good. We'd also get this fix for free if F11 ever moves to 2.6.31.

-- 
Fedora Bugzappers volunteer triage team
https://fedoraproject.org/wiki/BugZappers
Comment 17 Hans Otten 2009-11-08 12:02:35 EST
Today I updated my machine to the most recent package versions. Just for the heck of it I checked if sound output had improved: it hadn't. Note that I was using 'tsched=1' because in the past using 'tsched=0' would not create a valid sink through the sound card and resulted in the creation of an 'auto_null' sink.

Frustrated by the result I Googled for "fedora 11 disable pulseaudio" and came upon the following link:

http://forums.fedoraforum.org/showthread.php?t=225660

This thread shows a step by step procedure to get pulseaudio running. I noticed the fact that it was using 'tsched=0' but thought I'd give it a try anyway. To my complete amazement it worked! Somewhere along the line 'tsched=0' had been fixed! It's that or it has to do with some of the other settings that have been changed.
Comment 18 Michael Chapman 2009-11-29 06:53:08 EST
I can confirm that upgrading to F12 appears to have resolved all the issues in my initial post.
Comment 19 Lennart Poettering 2009-12-17 10:26:07 EST
Closing then.

Note You need to log in before you can comment on or make changes to this bug.