[Lenovo ThinkPad X61s] Speaker volume mutes itself in random intervals after upgrade to 14.04

Bug #1324384 reported by Alexander Fedora
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Ubuntu)
Triaged
Medium
Unassigned

Bug Description

I've upgraded from ubuntu 13.10 and sound stopped working properly. It works in general. But mutes itself for small period of time in random intervals. I've looked at alsamixer and it shown what once in a while some of the parameters got to the lowest level and then returning to normal after some time. It is reproing on Speaker. But also Internal Mic Boost jumps from 100% to 0% and then back to 100%.
BTW, when sound mutes on speaker, headphones are still working. So looks like alsamixer reports volumes correctly. I've also tried to purge pulseaudio and alsa-base packages and re-installing them again.

But I was able to find workaround. Audio works just fine with old kernels. I've tried with 3.5.0-15 and 3.5.0-27. It works with both kernels. I've also tried newest kernel from next ubuntu version. 3.15.0-031500rc5 - audio is not working in new kernel.

$ amixer -c 0 scontents > normal.txt
SEE Attachment.
$ amixer -c 0 scontents > muted.txt
SEE Attachment.
$ amixer -c 0 scontents > normalagain.txt
SEE Attachment.

ProblemType: Bug
DistroRelease: Ubuntu 14.04
Package: linux-image-3.13.0-27-generic 3.13.0-27.50
ProcVersionSignature: Ubuntu 3.13.0-27.50-generic 3.13.11
Uname: Linux 3.13.0-27-generic x86_64
ApportVersion: 2.14.1-0ubuntu3.2
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: ghisguth 2519 F.... pulseaudio
                      ghisguth 3906 F.... pulseaudio
                      ghisguth 15548 F.... alsamixer
Date: Wed May 28 22:50:29 2014
HibernationDevice: RESUME=UUID=78076f7a-8340-428e-894b-ce095d0d278e
InstallationDate: Installed on 2010-04-19 (1501 days ago)
InstallationMedia: Kubuntu 10.04 "Lucid Lynx" - Beta amd64 (20100406.1)
MachineType: LENOVO 76693JG
PccardctlIdent:
 Socket 0:
   no product info available
PccardctlStatus:
 Socket 0:
   no card
ProcEnviron:
 TERM=xterm
 PATH=(custom, no user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/vmlinuz-3.13.0-27-generic root=/dev/mapper/ubuntu-root ro quiet splash crashkernel=384M-:128M
PulseList:
 Error: command ['pacmd', 'list'] failed with exit code 1: Home directory not accessible: Permission denied
 No PulseAudio daemon running, or not running as session daemon.
RelatedPackageVersions:
 linux-restricted-modules-3.13.0-27-generic N/A
 linux-backports-modules-3.13.0-27-generic N/A
 linux-firmware 1.127.2
RfKill:
 0: phy0: Wireless LAN
  Soft blocked: no
  Hard blocked: no
SourcePackage: linux
UpgradeStatus: Upgraded to trusty on 2014-04-25 (33 days ago)
dmi.bios.date: 10/22/2007
dmi.bios.vendor: LENOVO
dmi.bios.version: 7NET29WW (1.10 )
dmi.board.name: 76693JG
dmi.board.vendor: LENOVO
dmi.board.version: Not Available
dmi.chassis.asset.tag: No Asset Information
dmi.chassis.type: 10
dmi.chassis.vendor: LENOVO
dmi.chassis.version: Not Available
dmi.modalias: dmi:bvnLENOVO:bvr7NET29WW(1.10):bd10/22/2007:svnLENOVO:pn76693JG:pvrThinkPadX61s:rvnLENOVO:rn76693JG:rvrNotAvailable:cvnLENOVO:ct10:cvrNotAvailable:
dmi.product.name: 76693JG
dmi.product.version: ThinkPad X61s
dmi.sys.vendor: LENOVO

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :
Revision history for this message
Brad Figg (brad-figg) wrote : Status changed to Confirmed

This change was made by a bot.

Changed in linux (Ubuntu):
status: New → Confirmed
Revision history for this message
Joseph Salisbury (jsalisbury) wrote : Re: Speaker volume mutes itself in random intervals after upgrade to 14.04

Did this issue occur in a previous version of Ubuntu, or is this a new issue?

Would it be possible for you to test the latest upstream kernel? Refer to https://wiki.ubuntu.com/KernelMainlineBuilds . Please test the latest v3.15 kernel[0].

If this bug is fixed in the mainline kernel, please add the following tag 'kernel-fixed-upstream'.

If the mainline kernel does not fix this bug, please add the tag: 'kernel-bug-exists-upstream'.

If you are unable to test the mainline kernel, for example it will not boot, please add the tag: 'kernel-unable-to-test-upstream'.
Once testing of the upstream kernel is complete, please mark this bug as "Confirmed".

Thanks in advance.

[0] http://kernel.ubuntu.com/~kernel-ppa/mainline/v3.15-rc7-utopic/

Changed in linux (Ubuntu):
importance: Undecided → Medium
status: Confirmed → Incomplete
penalvch (penalvch)
description: updated
tags: added: bios-outdated-2.22
summary: - Speaker volume mutes itself in random intervals after upgrade to 14.04
+ [Lenovo ThinkPad X61s] Speaker volume mutes itself in random intervals
+ after upgrade to 14.04
Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

Confirmed bug exists in the latest upstream kernel:

Linux x61s 3.15.0-031500rc7-generic #201405251935 SMP Sun May 25 23:36:23 UTC 2014 x86_64 x86_64 x86_64 GNU/Linux

No, I didn't saw this bug in previous versions of ubuntu.

I've also stumbled upon very similar issue on askubuntu site: http://askubuntu.com/questions/450102/pulseaudio-randomly-mute-itself-without-a-reason. Citation: "I recently installed fresh Ubuntu 14.04. I've got external audio card Audiotrak Maya U5. It always worked fine until new Ubuntu. Music randomly get muted and there's no visible changes in sound settings or anything." Looks like the same issue.

tags: added: kernel-bug-exists-upstream
Changed in linux (Ubuntu):
status: Incomplete → Confirmed
penalvch (penalvch)
Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

I've updated bios. It didn't solve the problem. Speaker still not working properly.

sudo dmidecode -s bios-version && sudo dmidecode -s bios-release-date
7NETC2WW (2.22 )
03/22/2011

Changed in linux (Ubuntu):
status: Incomplete → Confirmed
tags: removed: bios-outdated-2.22
Revision history for this message
penalvch (penalvch) wrote :

Alexander Fedora, the next step is to fully commit bisect the kernel in order to identify the offending commit. Could you please do this following https://wiki.ubuntu.com/Kernel/KernelBisection ?

tags: added: kernel-bug-exists-upstream-3.15-rc7 latest-bios-2.22 needs-bisect regression-release
removed: kernel-bug-exists-upstream
Changed in linux (Ubuntu):
status: Confirmed → Incomplete
Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

Regression introduced between Ubuntu-3.11.0-12.19 and Ubuntu-3.12.0-1.3 versions. Diff contains 12147 commits. May take a while to do commit bisection.

Revision history for this message
Raymond (superquad-vortex2) wrote :

independent headphone should be disabled on notebook

analog device and alternate analog device must use different audio output 0x03 and 0x04

Node 0x03 [Audio Output] wcaps 0x405: Stereo Amp-Out
  Control: name="Headphone Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Device: name="AD1984 Analog", type="Audio", device=0
  Device: name="AD1984 Alt Analog", type="Audio", device=2
  Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=0
  Amp-Out vals: [0x1d 0x1d]
  Converter: stream=0, channel=0
  Power states: D0 D3
  Power: setting=D0, actual=D0

Node 0x04 [Audio Output] wcaps 0x405: Stereo Amp-Out
  Control: name="Speaker Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=0
  Amp-Out vals: [0x00 0x00]
  Converter: stream=0, channel=0
  Power states: D0 D3
  Power: setting=D0, actual=D0

Revision history for this message
Raymond (superquad-vortex2) wrote :

APLAY

**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: AD1984 Analog [AD1984 Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0
card 0: Intel [HDA Intel], device 2: AD1984 Alt Analog [AD1984 Alt Analog]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

Revision history for this message
Raymond (superquad-vortex2) wrote :

seem missing dock headphone/line out if there is dock mic

241.617003] autoconfig: line_outs=1 (0x12/0x0/0x0/0x0/0x0) type:speaker
[ 241.617008] speaker_outs=0 (0x0/0x0/0x0/0x0/0x0)
[ 241.617011] hp_outs=1 (0x11/0x0/0x0/0x0/0x0)
[ 241.617013] mono: mono_out=0x0
[ 241.617015] inputs:
[ 241.617018] Internal Mic=0x15
[ 241.617021] Dock Mic=0x1c
[ 241.617023] Mic=0x14

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

I'm still doing bisection. Taking a lot of time. Meanwhile I've collected some logs from good kernel:

APLAY:

**** List of PLAYBACK Hardware Devices ****
card 0: Intel [HDA Intel], device 0: AD198x Analog [AD198x Analog]
  Subdevices: 0/1
  Subdevice #0: subdevice #0
card 0: Intel [HDA Intel], device 1: AD198x Digital [AD198x Digital]
  Subdevices: 1/1
  Subdevice #0: subdevice #0

ALSA:

Node 0x02 [Audio Output] wcaps 0x30311: Stereo Digital
  Control: name="IEC958 Playback Con Mask", index=0, device=0
  Control: name="IEC958 Playback Pro Mask", index=0, device=0
  Control: name="IEC958 Playback Default", index=0, device=0
  Control: name="IEC958 Playback Switch", index=0, device=0
  Control: name="IEC958 Default PCM Playback Switch", index=0, device=0
  Control: name="IEC958 Playback Source", index=0, device=0
  Device: name="AD198x Digital", type="SPDIF", device=1
  Converter: stream=8, channel=0
  Digital:
  Digital category: 0x0
  IEC Coding Type: 0x0
  PCM:
    rates [0x7e0]: 44100 48000 88200 96000 176400 192000
    bits [0xe]: 16 20 24
    formats [0x5]: PCM AC3
  Delay: 3 samples
  Connection: 3
     0x01* 0x08 0x09
Node 0x03 [Audio Output] wcaps 0x405: Stereo Amp-Out
  Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=0
  Amp-Out vals: [0x00 0x00]
  Converter: stream=0, channel=0
  Power states: D0 D3
  Power: setting=D0, actual=D0
Node 0x04 [Audio Output] wcaps 0x405: Stereo Amp-Out
  Control: name="PCM Playback Volume", index=0, device=0
    ControlAmp: chs=3, dir=Out, idx=0, ofs=0
  Device: name="AD198x Analog", type="Audio", device=0
  Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=0
  Amp-Out vals: [0x27 0x27]
  Converter: stream=8, channel=0
  Power states: D0 D3
  Power: setting=D0, actual=D0

Two things to note:

New kernel shows second device as "AD1984 Alt Analog", bot good kernel shows it as "AD198x Digital".

New kernel shows two controls "Headphone Playback Volume" and "Speaker Playback Volume". But old one shows single control "PCM Playback Volume".

Revision history for this message
Raymond (superquad-vortex2) wrote :

https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_analog.c?id=6a699bec88d5755c0f1be4e967649b3cfeac0205

use hdajackretask or early patching to fix the pin default if spdif node 0x1b from[n/a] to jack

https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/tree/Documentation/sound/alsa/HD-Audio.txt

Node 0x1b [Pin Complex] wcaps 0x40030d: Stereo Digital Amp-Out
  Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=1
  Amp-Out vals: [0xa7 0xa7]
  Pincap 0x00000010: OUT
  Pin Default 0x614411f0: [N/A] SPDIF Out at Sep Rear
    Conn = RCA, Color = Black
    DefAssociation = 0xf, Sequence = 0x0
    Misc = NO_PRESENCE
  Pin-ctls: 0x40: OUT
  Connection: 1
     0x02

Revision history for this message
Raymond (superquad-vortex2) wrote :

https://git.kernel.org/cgit/linux/kernel/git/tiwai/sound.git/commit/sound/pci/hda/patch_analog.c?id=5ccc618fee67f0f0b2122dd4b32a02fd2b6a1569

this is the patch which drop static model and use auto probe

you have to fixup missing pin and any regression of this patch

Revision history for this message
Raymond (superquad-vortex2) wrote :

case AD1984_THINKPAD:
- if (codec->subsystem_id == 0x17aa20fb) {
- /* Thinpad X300 does not have the ability to do SPDIF,
- or attach to docking station to use SPDIF */
- spec->multiout.dig_out_nid = 0;
- } else
- spec->multiout.dig_out_nid = AD1884_SPDIF_OUT;

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

Thank you Raymond, I will look into patching it. I have no experience working with kernel or audio driver. Will need to read the code and documentation. It may take some time. But I could quickly confirm what 5ccc618fee67f0f0b2122dd4b32a02fd2b6a1569 is the commit, which causing the problem.

Revision history for this message
penalvch (penalvch) wrote :

Alexander Fedora, the issue you are reporting is an upstream one. Could you please report this problem through the appropriate channel by following the instructions _verbatim_ at https://wiki.ubuntu.com/Bugs/Upstream/kernel ?

Please provide a direct URL to your e-mail to the mailing list once you have made it so that it may be tracked.

Thank you for your understanding.

tags: added: bisect-done
removed: needs-bisect
Changed in linux (Ubuntu):
status: Incomplete → Triaged
Revision history for this message
Raymond (superquad-vortex2) wrote :

the easy way is

diff -u workingalsainfo nonworkingalsainfo

you can use early patching to disable independent headphone by hint and fixup spdif pin

since stereo mix is disalbed as it conflict with auto Mic selection

-/*
- * Lenovo Thinkpad T61/X61
- */
-static const struct hda_input_mux ad1984_thinkpad_capture_source = {
- .num_items = 4,
- .items = {
- { "Mic", 0x0 },
- { "Internal Mic", 0x1 },
- { "Mix", 0x3 },
- { "Dock Mic", 0x4 },
- },
-};

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :
Download full text (29.3 KiB)

Please look at the diff below. I won't have much time till Tuesday. Will read how to try to use early patching then. Thanks.

I've also send bug report to the <email address hidden>. It waits approval from moderators. Will post the link to email as soon as it will be approved.

--- alsa-info-3.10-rc7-358-gaa95d61-generic.txt 2014-05-31 22:51:48.464325741 -0700
+++ alsa-info-3.10-rc7-359-g5ccc618-generic.txt 2014-05-31 19:58:01.352099733 -0700
@@ -3,7 +3,7 @@
 !!ALSA Information Script v 0.4.60
 !!################################

-!!Script ran on: Sun Jun 1 05:51:12 UTC 2014
+!!Script ran on: Sun Jun 1 02:56:49 UTC 2014

 !!Linux Distribution
@@ -23,7 +23,7 @@
 !!Kernel Information
 !!------------------

-Kernel release: 3.10-rc7-358-gaa95d61-generic
+Kernel release: 3.10-rc7-359-g5ccc618-generic
 Operating System: GNU/Linux
 Architecture: x86_64
 Processor: x86_64
@@ -33,7 +33,7 @@
 !!ALSA Version
 !!------------

-Driver version: k3.10-rc7-358-gaa95d61-generic
+Driver version: k3.10-rc7-359-g5ccc618-generic
 Library version: 1.0.27.2
 Utilities version: 1.0.27.2

@@ -57,7 +57,7 @@
 !!-----------------------------

  0 [Intel ]: HDA-Intel - HDA Intel
- HDA Intel at 0xf8220000 irq 45
+ HDA Intel at 0xf8220000 irq 46
  4 [ThinkPadEC ]: ThinkPad EC - ThinkPad Console Audio Control
                       ThinkPad Console Audio Control at EC reg 0x30, fw 7MHT25WW-1.03

@@ -153,18 +153,11 @@
   Power states: D0 D3
   Power: setting=D0, actual=D0
 GPIO: io=3, o=0, i=0, unsolicited=1, wake=0
- IO[0]: enable=0, dir=0, wake=0, sticky=0, data=1, unsol=0
+ IO[0]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
   IO[1]: enable=1, dir=0, wake=0, sticky=0, data=0, unsol=0
   IO[2]: enable=0, dir=0, wake=0, sticky=0, data=0, unsol=0
 Node 0x02 [Audio Output] wcaps 0x30311: Stereo Digital
- Control: name="IEC958 Playback Con Mask", index=0, device=0
- Control: name="IEC958 Playback Pro Mask", index=0, device=0
- Control: name="IEC958 Playback Default", index=0, device=0
- Control: name="IEC958 Playback Switch", index=0, device=0
- Control: name="IEC958 Default PCM Playback Switch", index=0, device=0
- Control: name="IEC958 Playback Source", index=0, device=0
- Device: name="AD198x Digital", type="SPDIF", device=1
- Converter: stream=8, channel=0
+ Converter: stream=0, channel=0
   Digital:
   Digital category: 0x0
   IEC Coding Type: 0x0
@@ -176,18 +169,21 @@
   Connection: 3
      0x01* 0x08 0x09
 Node 0x03 [Audio Output] wcaps 0x405: Stereo Amp-Out
+ Control: name="Headphone Playback Volume", index=0, device=0
+ ControlAmp: chs=3, dir=Out, idx=0, ofs=0
+ Device: name="AD1984 Analog", type="Audio", device=0
+ Device: name="AD1984 Alt Analog", type="Audio", device=2
   Amp-Out caps: ofs=0x27, nsteps=0x27, stepsize=0x05, mute=0
- Amp-Out vals: [0x00 0x00]
+ Amp-Out vals: [0x27 0x27]
   Converter: stream=0, channel=0
   Power states: D0 D3
   Power: setting=D0, actual=D0
 Node 0x04 [Audio Output] wcaps 0x405: Stereo Amp-Out
- Control: name="PCM Playback Volume", index=0, device=0
+ Control: name="Speaker Playback Volume", index=0,...

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

Sorry, just realized the message was too long. Attached diff between alsa info for working and broken kernels as file.

Revision history for this message
Alexander Fedora (alexander-fedora) wrote :

Link to the bug report: http://mailman.alsa-project.org/pipermail/alsa-devel/2014-June/077340.html

It seems like the issue can be solved by removing pulseaudio.

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.