[Jaunty] Assertion 'err != -11' failed at modules/module-alsa-source.c:221, function try_recover(). Aborting.

Bug #350829 reported by Ludovico Cavedon on 2009-03-29
14
This bug affects 1 person
Affects Status Importance Assigned to Milestone
bluez (Ubuntu)
Undecided
Unassigned
pulseaudio (Ubuntu)
Undecided
Unassigned

Bug Description

Binary package hint: pulseaudio

I am unable to add the alsa source for the bluetooth headset. It worked under hardy and intrepid.

Adding the sink works.

Log:
$ pulseaudio
I: caps.c: Limited capabilities successfully to CAP_SYS_NICE.
I: caps.c: Dropping root privileges.
I: caps.c: Limited capabilities successfully to CAP_SYS_NICE.
N: main.c: Called SUID root and real-time and/or high-priority scheduling was requested in the configuration. However, we lack the necessary privileges:
N: main.c: We are not in group 'pulse-rt', PolicyKit refuse to grant us the requested privileges and we have no increase RLIMIT_NICE/RLIMIT_RTPRIO resource limits.
N: main.c: For enabling real-time/high-priority scheduling please acquire the appropriate PolicyKit privileges, or become a member of 'pulse-rt', or increase the RLIMIT_NICE/RLIMIT_RTPRIO resource limits for this user.
W: alsa-util.c: Device front:0 doesn't support 44100 Hz, changed to 48000 Hz.
W: alsa-util.c: Device front:0 doesn't support 44100 Hz, changed to 48000 Hz.
W: alsa-util.c: Cannot find fallback mixer control "Mic" or mixer control is no combination of switch/volume.

$ pactl load-module module-alsa-sink device=headset
14

W: alsa-util.c: Device headset doesn't support 44100 Hz, changed to 8000 Hz.
W: alsa-util.c: Device headset doesn't support 2 channels, changed to 1.
W: alsa-util.c: Unable to load mixer: Protocol not available

$ pactl load-module module-alsa-source device=headset
Connection failure: Connection terminated

W: alsa-util.c: Device headset doesn't support 44100 Hz, changed to 8000 Hz.
W: alsa-util.c: Device headset doesn't support 2 channels, changed to 1.
W: alsa-util.c: Unable to load mixer: Protocol not available
W: alsa-util.c: Device headset doesn't support 44100 Hz, changed to 8000 Hz.
W: alsa-util.c: Device headset doesn't support 2 channels, changed to 1.
W: alsa-util.c: Unable to load mixer: Protocol not available
E: module-alsa-source.c: Assertion 'err != -11' failed at modules/module-alsa-source.c:221, function try_recover(). Aborting.
Aborted

$ aplay -l
**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: CONEXANT Analog [CONEXANT Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: Intel [HDA Intel], device 1: Conexant Digital [Conexant Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

$ aplay -L
front:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    Front speakers
surround40:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    4.0 Surround output to Front and Rear speakers
surround41:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    4.1 Surround output to Front, Rear and Subwoofer speakers
surround50:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    5.0 Surround output to Front, Center and Rear speakers
surround51:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    5.1 Surround output to Front, Center, Rear and Subwoofer speakers
surround71:CARD=Intel,DEV=0
    HDA Intel, CONEXANT Analog
    7.1 Surround output to Front, Center, Side, Rear and Woofer speakers
iec958:CARD=Intel,DEV=0
    HDA Intel, Conexant Digital
    IEC958 (S/PDIF) Digital Audio Output
null
    Discard all samples (playback) or generate zero samples (capture)

$ pactl list
*** Module #0 ***
Name: module-gconf
Argument:
Usage counter: n/a
Auto unload: no

*** Module #1 ***
Name: module-suspend-on-idle
Argument:
Usage counter: n/a
Auto unload: no

*** Module #2 ***
Name: module-device-restore
Argument:
Usage counter: n/a
Auto unload: no

*** Module #3 ***
Name: module-stream-restore
Argument:
Usage counter: n/a
Auto unload: no

*** Module #4 ***
Name: module-alsa-sink
Argument: device_id=0 sink_name=alsa_output.pci_8086_284b_sound_card_0_alsa_playback_0 tsched=0
Usage counter: n/a
Auto unload: no

*** Module #5 ***
Name: module-alsa-source
Argument: device_id=0 source_name=alsa_input.pci_8086_284b_sound_card_0_alsa_capture_0 tsched=0
Usage counter: n/a
Auto unload: no

*** Module #6 ***
Name: module-hal-detect
Argument: tsched=0
Usage counter: n/a
Auto unload: no

*** Module #7 ***
Name: module-esound-protocol-unix
Argument:
Usage counter: n/a
Auto unload: no

*** Module #8 ***
Name: module-native-protocol-unix
Argument:
Usage counter: n/a
Auto unload: no

*** Module #9 ***
Name: module-default-device-restore
Argument:
Usage counter: n/a
Auto unload: no

*** Module #10 ***
Name: module-rescue-streams
Argument:
Usage counter: n/a
Auto unload: no

*** Module #11 ***
Name: module-always-sink
Argument:
Usage counter: n/a
Auto unload: no

*** Module #12 ***
Name: module-console-kit
Argument:
Usage counter: n/a
Auto unload: no

*** Module #13 ***
Name: module-position-event-sounds
Argument:
Usage counter: n/a
Auto unload: no

*** Sink #0 ***
Name: alsa_output.pci_8086_284b_sound_card_0_alsa_playback_0
Driver: modules/module-alsa-sink.c
Sample Specification: s16le 2ch 48000Hz
Channel Map: front-left,front-right
Owner Module: 4
Volume: 0: 47% 1: 47%
Monitor Source: alsa_output.pci_8086_284b_sound_card_0_alsa_playback_0.monitor
Latency: 0 usec, configured 0 usec
Flags: HARDWARE HW_MUTE_CTRL HW_VOLUME_CTRL DECIBEL_VOLUME LATENCY
Properties:
device.api = "alsa"
device.class = "sound"
alsa.class = "generic"
alsa.subclass = "generic-mix"
alsa.name = "CONEXANT Analog"
alsa.id = "CONEXANT Analog"
alsa.subdevice = "0"
alsa.subdevice_name = "subdevice #0"
alsa.device = "0"
alsa.card = "0"
alsa.card_name = "HDA Intel"
alsa.long_card_name = "HDA Intel at 0xf4500000 irq 22"
device.description = "HDA Intel - CONEXANT Analog"
device.string = "front:0"
device.buffering.buffer_size = "15360"
device.buffering.fragment_size = "1920"
device.access_mode = "mmap"

*** Source #0 ***
Name: alsa_output.pci_8086_284b_sound_card_0_alsa_playback_0.monitor
Driver: modules/module-alsa-sink.c
Sample Specification: s16le 2ch 48000Hz
Channel Map: front-left,front-right
Owner Module: 4
Volume: 0: 100% 1: 100%
Monitor of Sink: alsa_output.pci_8086_284b_sound_card_0_alsa_playback_0
Latency: 0 usec, configured 0 usec
Flags: DECIBEL_VOLUME LATENCY
Properties:
device.description = "Monitor of HDA Intel - CONEXANT Analog"
device.class = "monitor"

*** Source #1 ***
Name: alsa_input.pci_8086_284b_sound_card_0_alsa_capture_0
Driver: modules/module-alsa-source.c
Sample Specification: s16le 2ch 48000Hz
Channel Map: front-left,front-right
Owner Module: 5
Volume: 0: 100% 1: 100%
Monitor of Sink: n/a
Latency: 0 usec, configured 0 usec
Flags: HARDWARE DECIBEL_VOLUME LATENCY
Properties:
device.api = "alsa"
device.class = "sound"
alsa.class = "generic"
alsa.subclass = "generic-mix"
alsa.name = "CONEXANT Analog"
alsa.id = "CONEXANT Analog"
alsa.subdevice = "0"
alsa.subdevice_name = "subdevice #0"
alsa.device = "0"
alsa.card = "0"
alsa.card_name = "HDA Intel"
alsa.long_card_name = "HDA Intel at 0xf4500000 irq 22"
device.description = "HDA Intel - CONEXANT Analog"
device.string = "front:0"
device.buffering.buffer_size = "15360"
device.buffering.fragment_size = "1920"
device.access_mode = "mmap"

*** Client #0 ***
Driver: modules/module-console-kit.c
Owner Module: n/a
Properties:
application.name = "ConsoleKit Session /org/freedesktop/ConsoleKit/Session1"
console-kit.session = "/org/freedesktop/ConsoleKit/Session1"

*** Client #3 ***
Driver: pulsecore/protocol-native.c
Owner Module: 8
Properties:
application.name = "pactl"
native-protocol.peer = "UNIX socket client"
native-protocol.version = "14"
application.process.id = "5255"
application.process.user = "cavedon"
application.process.host = "cavedon-laptop"
application.process.binary = "pactl"
application.language = "en_US.UTF-8"

[... Samples...]

ProblemType: Bug
Architecture: amd64
DistroRelease: Ubuntu 9.04
Package: pulseaudio 0.9.14-0ubuntu14
ProcEnviron:
 SHELL=/bin/bash
 LANG=en_US.UTF-8
SourcePackage: pulseaudio
Uname: Linux 2.6.28-11-generic x86_64

Ludovico Cavedon (cavedon) wrote :
Ludovico Cavedon (cavedon) wrote :

log of running:
$ PULSE_LOG=5 pulseaudio
$ pactl load-module module-alsa-source device=headset

Ludovico Cavedon (cavedon) wrote :

log of running:
$ PULSE_LOG=5 pulseaudio
$ pactl load-module module-alsa-sink device=headset
$ pactl load-module module-alsa-source device=headset

Ludovico Cavedon (cavedon) wrote :

The problem is that the with the alsa blutooth plugin, snd_pcm_update_avail() is returning EAGAIN instead of 0 when no data is available. And pulseaudio expect snd_pcm_update_avail() to never return EAGAIN.

According to ALSA developers, the bluetooth plugin is doing the wrong thing:
http://thread.gmane.org/gmane.linux.alsa.devel/61365/focus=61366

Here is a patch for bluez package to fix this problem.
I also uploaded a fixed version to my ppa: https://edge.launchpad.net/~cavedon/+archive/ppa

Ludovico Cavedon (cavedon) wrote :
Ludovico Cavedon (cavedon) wrote :

IMHO, however, pulseaudio should not fail, and handle EAGAIN as if were 0. See attached patch.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:0.9.22~0.9.21+341-g62bf-0ubuntu1

---------------
pulseaudio (1:0.9.22~0.9.21+341-g62bf-0ubuntu1) lucid; urgency=low

  * New snapshot based on stable-queue git branch (testing requested
    specifically by upstream)
    - LP: #164745, #173212, #201391, #204536, #207796, #210016, #221038,
    - LP: #226342, #230408, #236423, #237443, #250059, #269585, #274304,
    - LP: #274577, #275474, #277532, #277566, #277932, #278025, #280534,
    - LP: #283049, #286816, #287036, #292732, #298011, #298301, #300290,
    - LP: #302038, #311497, #311853, #324062, #339448, #344057, #348979,
    - LP: #350829, #356206, #367379, #367544, #369822, #371897, #374846,
    - LP: #375570, #381801, #399515, #402950, #403786, #408169, #409322,
    - LP: #409723, #410326, #410446, #417695, #417976, #419271, #421072,
    - LP: #422774, #423979, #424655, #425028, #427016, #431072, #432660,
    - LP: #437640, #437996, #442191, #443306, #443389, #446719, #449762,
    - LP: #455417, #461532, #464652, #483191, #497537, #503780
  * debian/patches/:
    + add: 0099-change-configure-git-version-tag.patch: Match released
           upstream 0.9.21 for shlibs and LIBPULSE_VERSION_INFO
    - drop: 0004-set-tsched0.patch (no longer relevant)
            0050-revert-pacmd-poll-argv.patch (no longer relevant)
            0056-dont-bail-on-sound-class-modem.patch (merged)
            0056-ignore-sound-class-modem.patch (merged)
            0058-Backport-4c793.patch (merged)
            0059-Backport-978d3.patch (merged)
            0060-fix-implicit-func-decl-cpu-arm.patch (merged)
            0061-Backport-c5fdb.patch (merged)
            0070-dont-bail-on-sound-class-modem-devs.patch (merged)
    + refresh: 0001-change-resample-and-buffering.patch
               0090-disable-flat-volumes.patch
               0091-dont-load-cork-music-on-phone.patch
               0057-load-module-x11-bell.patch
 -- Daniel T Chen <email address hidden> Thu, 14 Jan 2010 20:33:05 -0500

Changed in pulseaudio (Ubuntu):
status: New → Fix Released
Changed in bluez (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Duplicates of this bug

Other bug subscribers