System keeps briefly freezing with kernel errors "snd_hda_intel 0000:01:00.1: Disabling via vga_switcheroo" and "snd_hda_intel 0000:01:00.1: Cannot lock devices!"

Bug #1775126 reported by Pepijn de Vos
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
linux (Fedora)
Unknown
Unknown
linux (Ubuntu)
Incomplete
Undecided
Unassigned

Bug Description

When using Wayland, I observe sub-second freezes a couple of times per minute.
It just freezes the mouse and everything for a split second, and continues as if nothing happened.
When using Xorg, everything runs smoothly. (hence I did not pick Xorg in ubuntu-bug)

I suspect this is a GPU issue.
My laptop has a hybrid GPU, and dmesg is filled with vga_switcheroo messages

[ 2640.943598] snd_hda_intel 0000:01:00.1: Disabling via vga_switcheroo
[ 2641.243870] snd_hda_intel 0000:01:00.1: Cannot lock devices!
[ 2641.260536] ACPI: \_SB_.PCI0.PEG0.VID_: failed to evaluate _DSM
[ 2658.996392] snd_hda_intel 0000:01:00.1: Enabling via vga_switcheroo

I tried to manually switch to the dedicated graphics card, and that completely froze my session.
Now I can't even log in using Wayland anymore, as it straight up crashes and goes back to the login screen.
Xorg is still fine...

Now there are other weird messages such as
[ 2777.002437] nouveau 0000:01:00.0: gr: DATA_ERROR 0000009c [] ch 8 [001f998000 systemd-logind[855]] subc 0 class 9297 mthd 0d78 data 00000004
[ 2889.648718] snd_hda_codec_hdmi hdaudioC1D0: out of range cmd 0:5:707:ffffffff

And I suppose these are from the crash that I caused myself (not sure if related to the short freezes)
[ 2551.513519] gnome-shell[5179]: segfault at 128 ip 00007f409effeab0 sp 00007ffcf4af1148 error 4 in libmutter-clutter-2.so[7f409efba000+161000]
[ 2570.239129] Chrome_~dThread[6018]: segfault at 0 ip 00007ff90a3494cd sp 00007ff9086c9b00 error 6 in libxul.so[7ff90958f000+6111000]
[ 2628.443468] gnome-shell[6348]: segfault at 0 ip 00007f6349eb6c90 sp 00007ffe5acd8bc8 error 4 in libgbm.so.1.0.0[7f6349eb4000+c000]
[ 2777.424194] gnome-shell[6913]: segfault at 0 ip 00007ff1e8550c90 sp 00007ffe6cddb228 error 4 in libgbm.so.1.0.0[7ff1e854e000+c000]

ProblemType: Bug
DistroRelease: Ubuntu 18.04
Package: gnome-shell 3.28.1-0ubuntu2
ProcVersionSignature: Ubuntu 4.15.0-22.24-generic 4.15.17
Uname: Linux 4.15.0-22-generic x86_64
ApportVersion: 2.20.9-0ubuntu7.1
Architecture: amd64
CurrentDesktop: ubuntu:GNOME
Date: Tue Jun 5 08:14:17 2018
DisplayManager: gdm3
GsettingsChanges:
 b'org.gnome.shell' b'command-history' redacted by apport
 b'org.gnome.shell' b'app-picker-view' b'uint32 1'
 b'org.gnome.shell' b'favorite-apps' redacted by apport
 b'org.gnome.desktop.interface' b'gtk-im-module' b"'gtk-im-context-simple'"
InstallationDate: Installed on 2018-04-27 (38 days ago)
InstallationMedia: Ubuntu 18.04 LTS "Bionic Beaver" - Release amd64 (20180426)
SourcePackage: gnome-shell
UpgradeStatus: No upgrade log present (probably fresh install)
---
ApportVersion: 2.20.9-0ubuntu7.1
Architecture: amd64
AudioDevicesInUse:
 USER PID ACCESS COMMAND
 /dev/snd/controlC0: pepijn 1259 F.... pulseaudio
CurrentDesktop: ubuntu:GNOME
DistroRelease: Ubuntu 18.04
InstallationDate: Installed on 2018-04-27 (38 days ago)
InstallationMedia: Ubuntu 18.04 LTS "Bionic Beaver" - Release amd64 (20180426)
MachineType: Dell Inc. Latitude E6420
Package: linux (not installed)
ProcFB: 0 inteldrmfb
ProcKernelCmdLine: BOOT_IMAGE=/boot/vmlinuz-4.15.0-22-generic root=UUID=0bfd26c3-7ff7-4c73-8c5b-aaeca648e5f3 ro quiet splash vt.handoff=1
ProcVersionSignature: Ubuntu 4.15.0-22.24-generic 4.15.17
RelatedPackageVersions:
 linux-restricted-modules-4.15.0-22-generic N/A
 linux-backports-modules-4.15.0-22-generic N/A
 linux-firmware 1.173.1
Tags: bionic
Uname: Linux 4.15.0-22-generic x86_64
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dialout dip lpadmin plugdev sambashare sudo
_MarkForUpload: True
dmi.bios.date: 01/04/2016
dmi.bios.vendor: Dell Inc.
dmi.bios.version: A23
dmi.board.name: 032T9K
dmi.board.vendor: Dell Inc.
dmi.board.version: A01
dmi.chassis.type: 9
dmi.chassis.vendor: Dell Inc.
dmi.modalias: dmi:bvnDellInc.:bvrA23:bd01/04/2016:svnDellInc.:pnLatitudeE6420:pvr01:rvnDellInc.:rn032T9K:rvrA01:cvnDellInc.:ct9:cvr:
dmi.product.name: Latitude E6420
dmi.product.version: 01
dmi.sys.vendor: Dell Inc.

Revision history for this message
Pepijn de Vos (pepijndevos) wrote :
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

The mouse movement in Wayland sessions is quite different to Xorg sessions, and less efficient as it seems to incur screen redraws.

I have not debugged the issue any deeper yet but it's already being tracked in bug 1690719, and upstream in https://bugzilla.gnome.org/show_bug.cgi?id=745032.

Please report your crashes and other issues in separate bugs.

Revision history for this message
Pepijn de Vos (pepijndevos) wrote :

Thank you. I do think this is a different issue though.

After all my messing around I now have the same freeze in an Xorg session occasionally, with dmesg displaying the following at the exact time of the freeze.

[ 6129.055500] snd_hda_intel 0000:01:00.1: Disabling via vga_switcheroo
[ 6129.356301] snd_hda_intel 0000:01:00.1: Cannot lock devices!
[ 6129.367439] ACPI: \_SB_.PCI0.PEG0.VID_: failed to evaluate _DSM
[ 6131.624451] snd_hda_intel 0000:01:00.1: Enabling via vga_switcheroo
[ 6136.991846] snd_hda_intel 0000:01:00.1: Disabling via vga_switcheroo
[ 6137.292773] snd_hda_intel 0000:01:00.1: Cannot lock devices!
[ 6137.308345] ACPI: \_SB_.PCI0.PEG0.VID_: failed to evaluate _DSM
[ 6139.433018] snd_hda_intel 0000:01:00.1: Enabling via vga_switcheroo

So while it initially manifested in Wayland, I believe it relates to the GPU switching.
Probably the title/component needs to be changed.

Revision history for this message
Pepijn de Vos (pepijndevos) wrote :

It seems this bug is actually related to this one: https://bugzilla.redhat.com/show_bug.cgi?id=1564908

Revision history for this message
Pepijn de Vos (pepijndevos) wrote :

After disabling the HDMI sound card, I only get this line, accompanied by a short freeze.

[ 323.836831] ACPI: \_SB_.PCI0.PEG0.VID_: failed to evaluate _DSM

Any idea how to go about debugging this?

Revision history for this message
Ubuntu Kernel Bot (ubuntu-kernel-bot) wrote : Missing required logs.

This bug is missing log files that will aid in diagnosing the problem. While running an Ubuntu kernel (not a mainline or third-party kernel) please enter the following command in a terminal window:

apport-collect 1775126

and then change the status of the bug to 'Confirmed'.

If, due to the nature of the issue you have encountered, you are unable to run this command, please add a comment stating that fact and change the bug status to 'Confirmed'.

This change has been made by an automated script, maintained by the Ubuntu Kernel Team.

Changed in linux (Ubuntu):
status: New → Incomplete
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

OK. This is now a kernel bug.

no longer affects: gnome-shell (Ubuntu)
summary: - Short freezes in Wayland session
+ System keeps briefly freezing with kernel errors "snd_hda_intel
+ 0000:01:00.1: Disabling via vga_switcheroo" and "snd_hda_intel
+ 0000:01:00.1: Cannot lock devices!"
Revision history for this message
Pepijn de Vos (pepijndevos) wrote : AlsaInfo.txt

apport information

tags: added: apport-collected
description: updated
Revision history for this message
Pepijn de Vos (pepijndevos) wrote : CRDA.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : CurrentDmesg.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : IwConfig.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : Lspci.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : Lsusb.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : ProcCpuinfo.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : ProcCpuinfoMinimal.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : ProcEnviron.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : ProcInterrupts.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : ProcModules.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : PulseList.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : RfKill.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : UdevDb.txt

apport information

Revision history for this message
Pepijn de Vos (pepijndevos) wrote : WifiSyslog.txt

apport information

Revision history for this message
Kai-Heng Feng (kaihengfeng) wrote :

The warning message isn't harmful and should not cause hang. This should be a pure Gnome bug.

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.