USB audio devices are sometimes muted after resume from suspend to ram

Bug #665314 reported by Stephen Wassell
66
This bug affects 13 people
Affects Status Importance Assigned to Milestone
pulseaudio (Ubuntu)
Fix Released
Medium
David Henningsson
Declined for Precise by David Henningsson
Quantal
Fix Released
Medium
David Henningsson

Bug Description

Binary package hint: pulseaudio

When I open pulseaudio volume control that one output device is muted. If I unmute it's fine, until the next time I suspend and resume.

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: pulseaudio 1:0.9.22~0.9.21+stable-queue-32-g8478-0ubuntu21.1
ProcVersionSignature: Ubuntu 2.6.35-22.35-generic 2.6.35.4
Uname: Linux 2.6.35-22-generic x86_64
NonfreeKernelModules: talpa_vfshook talpa_pedconnector talpa_pedevice talpa_vcdevice talpa_core talpa_linux talpa_syscallhook wl fglrx
AlsaVersion: Advanced Linux Sound Architecture Driver Version 1.0.23.
Architecture: amd64
Card0.Amixer.info:
 Card hw:0 'Intel'/'HDA Intel at 0xfc500000 irq 46'
   Mixer name : 'IDT 92HD73C1X5'
   Components : 'HDA:111d7675,102802a0,00100103'
   Controls : 16
   Simple ctrls : 10
Card1.Amixer.info:
 Card hw:1 'HDMI'/'HDA ATI HDMI at 0xfc010000 irq 47'
   Mixer name : 'ATI R6xx HDMI'
   Components : 'HDA:1002aa01,00aa0100,00100000'
   Controls : 4
   Simple ctrls : 1
Card1.Amixer.values:
 Simple mixer control 'IEC958',0
   Capabilities: pswitch pswitch-joined penum
   Playback channels: Mono
   Mono: Playback [on]
Card2.Amixer.info:
 Card hw:2 'default'/'Burr-Brown from TI USB Audio CODEC at usb-0000:00:1d.7-3.3, full'
   Mixer name : 'USB Mixer'
   Components : 'USB08bb:2902'
   Controls : 2
   Simple ctrls : 1
Date: Fri Oct 22 20:43:47 2010
ProcEnviron:
 PATH=(custom, user)
 LANG=en_GB.utf8
 SHELL=/bin/bash
SelectedCard: 2 default USB-Audio - USB Audio CODEC
SourcePackage: pulseaudio
Symptom: audio
Title: [USB-Audio - USB Audio CODEC ] pactl stat failed to find default card
UserAsoundrc:
 # ALSA library configuration file

 # Include settings that are under the control of asoundconf(1).
 # (To disable these settings, comment out this line.)
 </home/steve/.asoundrc.asoundconf>
dmi.bios.date: 02/11/2009
dmi.bios.vendor: Dell Inc.
dmi.bios.version: A05
dmi.board.name: 0P786H
dmi.board.vendor: Dell Inc.
dmi.board.version: A05
dmi.chassis.type: 8
dmi.chassis.vendor: Dell Inc.
dmi.chassis.version: A05
dmi.modalias: dmi:bvnDellInc.:bvrA05:bd02/11/2009:svnDellInc.:pnStudio1737:pvrA05:rvnDellInc.:rn0P786H:rvrA05:cvnDellInc.:ct8:cvrA05:
dmi.product.name: Studio 1737
dmi.product.version: A05
dmi.sys.vendor: Dell Inc.

Related branches

Revision history for this message
Stephen Wassell (steve-nerv) wrote :
Revision history for this message
Rüdiger Kupper (ruediger.kupper) wrote :

I confirm this problem using a Behringer UCA202 audio interface with maverick.
The audio interface reports as "Bus 004 Device 003: ID 08bb:2902 Texas Instruments Japan PCM2902 Audio Codec"

Changed in pulseaudio (Ubuntu):
status: New → Confirmed
Revision history for this message
Rüdiger Kupper (ruediger.kupper) wrote :

May bug #569526 be related?

Revision history for this message
filzstift (filzstift) wrote :

have exactly the same problem here. behringer uca202 and 10.10 maverick
anyone knows if this is fixed in 11.04??

Revision history for this message
James Tunnicliffe (dooferlad) wrote :

Can confirm with my USB sound card (a "Zero DAC Head Amp" - http://www.ebay.co.uk/itm/09-NEW-VERSION-ZERO-24-192KHZ-DAC-HEAD-AMP-USB-OPA2604-/110606578667?pt=LH_DefaultDomain_0&hash=item19c0aa73eb#ht_8674wt_1165). It isn't anything fancy in the USB department - just a USB -> SPDIF chip (lsusb says: Bus 001 Device 010: ID 08bb:2704 Texas Instruments Japan). I think it happened with my old USB sound card as well (Lexicon Alpha). Can check if you like.

Just upgraded to 12.04 and have the same problem.

I don't think bug #569526 is the same problem since I only have one instance of Pulse running:
ps aux | grep pulse
1000 2139 1.6 0.0 631444 7788 ? Sl 17:01 0:28 /usr/bin/pulseaudio --start --log-target=syslog
1000 2146 0.0 0.0 95992 2988 ? S 17:01 0:00 /usr/lib/pulseaudio/pulse/gconf-helper

Revision history for this message
kapetr (kapetr) wrote :

I can confirm it in U12.04.

I have solved it this way:

------------------------------------------------------------------
/etc/pm/sleep.d/90_usbaudio :

#! /bin/sh

case $1 in
     suspend|suspend_hybrid|hibernate)
              true
        ;;
     resume|thaw)
              sleep 1; sudo -u inet /home/inet/prog/usbaudio.sh
        ;;
esac
---------------------------------------------------------------------
 /home/inet/prog/usbaudio.sh :

#!/bin/bash

# After resume from SUSPEND is USB sound card muted and not default ->

pacmd set-default-sink alsa_output.usb-0d8c_C-Media_USB_Headphone_Set-00-Set.analog-stereo
pacmd set-default-source alsa_input.usb-0d8c_C-Media_USB_Headphone_Set-00-Set.analog-mono
pacmd set-sink-mute alsa_output.usb-0d8c_C-Media_USB_Headphone_Set-00-Set.analog-stereo 0
pacmd set-source-mute alsa_input.usb-0d8c_C-Media_USB_Headphone_Set-00-Set.analog-mono 0

---------------------------------------------------------------------

It works for me. You must modify sink/source names of course. Do not use indexes - use names!

Note: user "inet" is the only one possible

Hope it helps you :-)

--kapetr

P.S. I had to do hack with my USB mouse too to wakeup (Exactly - it is ps/2 mouse on <ps/2 to usb> adapter

Revision history for this message
David Henningsson (diwic) wrote :

Hello everyone,

There is a suspend/resume script for PulseAudio that might be a part of this problem:

/usr/lib/pm-utils/sleep.d/01PulseAudio

If you remove this file (preferably, back it up somewhere in your home directory or somewhere), will that resolve your problem?

Changed in pulseaudio (Ubuntu):
status: Confirmed → Incomplete
tags: added: precise
Revision history for this message
Rüdiger Kupper (ruediger.kupper) wrote :

Hello everyone,

first I confirm that this problem is still present in precise.

Second: I frequently have multiple users (at least two) graphically logged into Ubuntu when I suspend the machine. There is a bug that is about how default sinks get muted after suspend, when more than one process of pulseaudio are running: Bug #569526. I suspect that it's related to our problem.

Can someone with a little more knowledge than me (I'm sorry I don't understand enough of the internals) have a look at Bug #569526 and confirm that it's related?

Revision history for this message
CruelAngel (hendricha) wrote :

@diwic: Suprisingly yes, removing 01PulseAudio from sleep.d fixes the problem for me.

Revision history for this message
David Henningsson (diwic) wrote : Re: USB and bluetooth audio devices are sometimes muted after resume from suspend to ram

Ok, thanks. I'm going to remove this script from Ubuntu 12.10. I believe it has become obsolete anyway.

summary: - USB audio device is always muted after resume from suspend to ram
+ USB and bluetooth audio devices are sometimes muted after resume from
+ suspend to ram
Changed in pulseaudio (Ubuntu):
assignee: nobody → David Henningsson (diwic)
importance: Undecided → Medium
status: Incomplete → In Progress
Changed in pulseaudio (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
billstei (billstei) wrote :

I have an EMU Tracker Pre USB audio interface and was experiencing the muted audio after suspend in Ubuntu 12.04, and after removing /usr/lib/pm-utils/sleep.d/01PulseAudio the interface would crash (all lights on) and the computer would hang coming out of suspend until the interface was disconnected from USB.

Revision history for this message
David Henningsson (diwic) wrote :

@billstei, ouch, thanks for the heads up. Ideally I guess we should try to see if this bug is also present in quantal, and try to fix the root cause for this bug.

Revision history for this message
billstei (billstei) wrote :

Since the EMU Tracker Pre USB is an external device, I have two sound "card" devices, the other being built in to the motherboard. I mention this because in additon to the mute-after-suspend problem, the default sound card selected in the Unity sound indicator changes intermittently after waking from suspend. Even more interesting is that this additional bug seems to have gone away now, and the indicator shows an "X" after suspend and the first menu choice is "Unmute", neither of which were present always before the 01PusleAudio file removal and replacement (or possibly a software update changed this behavior). Selecting "Unmute" does in fact unmute the sound.

Revision history for this message
billstei (billstei) wrote :

I have now had an occurence of the EMU Tracker Pre locking up with all lights on when the 01PulseAudio file is present, and this event produced no audio devices/outputs listed in System Settings -> Sound -> Ouput (there should be at least 5 between the built-in and external audio devices). This is not to say that 01PulseAudio is not needed, but that this interface may need something more to guarantee a clean wake from suspend. Rebooting the computer did not reset the EMU Tracker Pre, and the BIOS hung at Initialising USB Devices, and I unpluged the USB cable (this device is also USB powered) in order to get everything running normally, and then when I logged in, the audio was (still) muted.

Revision history for this message
David Henningsson (diwic) wrote :

@billstei, ok, thanks for the update. Yeah, I think the right thing to do here is see the EMU Tracker Pre specific stuff as a separate bug. There have been some rewrites of the USB streaming in kernel 3.5, maybe that will help...

tags: added: blocks-hwcert-enablement
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package pulseaudio - 1:2.1-0ubuntu1

---------------
pulseaudio (1:2.1-0ubuntu1) quantal; urgency=low

  [ David Henningsson ]
  * Remove the old 01PulseAudio pm-utils script, since it
    causes (LP: #665314) and is not recommended by upstream.

  [ Luke Yelavich ]
  * New upstream release.
  * Dropped patches, applied upstream:
    - 0621-Add-special-profiles-for-some-laptops-missing-speake.patch
 -- Luke Yelavich <email address hidden> Mon, 13 Aug 2012 15:05:52 +1000

Changed in pulseaudio (Ubuntu Quantal):
status: Fix Committed → Fix Released
Revision history for this message
David Henningsson (diwic) wrote :

Hi Anthony,

I'm attaching a version that would stop the muting of bluetooth devices only, with no other devices affected. Let's resync on IRC tomorrow about SRUing this version of the patch.

Revision history for this message
David Henningsson (diwic) wrote :

I'm splitting them up again, so that bluetooth gets its own bug 1038084. This is because only bluetooth devices get SRUed, after the regression mentioned in comment 11 of this bug.

summary: - USB and bluetooth audio devices are sometimes muted after resume from
- suspend to ram
+ USB audio devices are sometimes muted after resume from suspend to ram
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.