Bug 102319 - Crashes and freezes when switching VTs
Summary: Crashes and freezes when switching VTs
Alias: None
Product: DRI
Classification: Unclassified
Component: General (show other bugs)
Version: XOrg git
Hardware: Other All
: medium normal
Assignee: Default DRI bug account
QA Contact:
Depends on:
Reported: 2017-08-20 12:19 UTC by Marcin Mielniczuk
Modified: 2019-10-14 13:20 UTC (History)
0 users

See Also:
i915 platform:
i915 features:

dmesg with nouveau.modeset=0 (53.70 KB, text/x-log)
2017-08-23 16:03 UTC, Marcin Mielniczuk
no flags Details
journal with nouveau.modeset=0 (97.75 KB, text/x-log)
2017-08-23 16:04 UTC, Marcin Mielniczuk
no flags Details

Description Marcin Mielniczuk 2017-08-20 12:19:23 UTC
I have a weird problem while switching vts

I have a dual-GPU setup: intel i5-5200U as the default OpenGL renderer and GeForce 940M as the discrete card. I'm using the intel modesetting driver for the Intel graphics and xf86-video-nouveau for DRI_PRIME.

If I run SDDM/LXDM as my display manager (on Arch Linux), then switch the TTY to tty2, then switch back to tty7 (DM), I get only a blinking cursor.
If I run LightDM as my display manager, it survives a tty switch, but if I start an X server in tty2 and then switch directly to tty7, LightDM crashes.
If I switch tty2 -> tty3 (no x server) -> tty7, on the other hand, the DM does *not* crash.

The whole problem doesn't occur when using the `nomodeset` kernel option, (i.e. when my DE runs in software rendering mode)

Whenever I switch the ttys or when I launch the DM I get the following output in the dmesg log: https://pastebin.com/FgzZLEGg

I asked about it on #nouveau and I was told that since the intel driver takes care of the rendering, it is the one to blame here.

On the intel side, the problem occurs with both xf86-video-intel and the modesetting driver

The problem only occurs with the X server that is launched by a DM. If I run startx directly from the tty on both vts, everything works correctly.

It is not observed on a machine without nvidia graphics and with intel i5-7500K as the CPU/integrated GPU, with fairly same software stack.

OS: Arch Linux, DE: Cinnamon
Comment 1 Ilia Mirkin 2017-08-20 16:41:43 UTC
Try booting with nouveau.modeset=0 to rule out any nouveau interaction in your problem.

But perhaps the issue lies in the fact that nouveau suspends the GPU and intel is waiting on some fence to complete?
Comment 2 Marcin Mielniczuk 2017-08-23 16:03:07 UTC
With nouveau.modeset=0 I get a black screen in the tty the DM is running in. Attaching the journal and dmesg.
Comment 3 Marcin Mielniczuk 2017-08-23 16:03:43 UTC
Created attachment 133717 [details]
dmesg with nouveau.modeset=0
Comment 4 Marcin Mielniczuk 2017-08-23 16:04:04 UTC
Created attachment 133718 [details]
journal with nouveau.modeset=0
Comment 5 Marcin Mielniczuk 2017-08-23 16:07:00 UTC
As for suspending the Nvidia GPU - I ran 


inside my DM manager to make sure that the Nvidia GPU remains powered on. The problem persists even then.
Comment 6 Martin Peres 2019-10-14 13:20:17 UTC

Freedesktop's Bugzilla instance is EOLed and open bugs are about to be migrated to http://gitlab.freedesktop.org.

To avoid migrating out of date bugs, I am now closing all the bugs that did not see any activity in the past year. If the issue is still happening, please create a new bug in the relevant project at https://gitlab.freedesktop.org/drm (use misc by default).

Sorry about the noise!

Use of freedesktop.org services, including Bugzilla, is subject to our Code of Conduct. How we collect and use information is described in our Privacy Policy.