http://bugzilla.opensuse.org/show_bug.cgi?id=980750
Bug ID: 980750 Summary: Plymouth prevents loading DRM/KMS driver for newly installed graphics card Classification: openSUSE Product: openSUSE Distribution Version: Leap 42.1 Hardware: All OS: Other Status: NEW Severity: Normal Priority: P5 - None Component: Basesystem Assignee: bnc-team-screening@forge.provo.novell.com Reporter: maximilian.staudt@suse.com QA Contact: qa-bugs@suse.de Found By: --- Blocker: ---
When changing a VGA card in an already installed system, Plymouth will prevent its modern (DRM/KMS) kernel mode driver to be loaded.
Example:
1. Install Leap 42.1 in QEMU using the emulated Cirrus card (-vga cirrus). 2. The system boots up with a splash screen. 3. Shut down the system. 4. Start the VM, this time with the Bochs VGA card (-vga std). 5. A splash screen will be shown, but then X falls back to the VESA driver.
As a bonus, switching to a text VT (Ctrl-Alt-F1) only gives a blinking cursor. The VT works just fine and is usable, except the user has to operate it blindly as no video is shown.
http://bugzilla.opensuse.org/show_bug.cgi?id=980750 http://bugzilla.opensuse.org/show_bug.cgi?id=980750#c1
Max Staudt maximilian.staudt@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|NEW |CONFIRMED CC| |maximilian.staudt@suse.com, | |xorg-maintainer-bugs@forge. | |provo.novell.com
--- Comment #1 from Max Staudt maximilian.staudt@suse.com --- This bug occurs because the DRM driver for the new graphics card is not in the initrd.
Plymouth waits for udev to clear its queue, assuming that this means "all devices in the system have been detected and initialized". When booting the system with the "plymouth:debug" kernel option, Plymouth's log in /var/log/plymouth-debug.log shows this as "udev coldplug complete".
As discussed in the thread referenced in upstream bug https://bugs.freedesktop.org/show_bug.cgi?id=95356 this situation happens when switching root from the initrd to the real root.
At this point, Plymouth will start displaying the splash screen on the graphics devices existing at that time. If the DRM driver for the graphics card is included in the initrd, it will have been loaded and replaced any vesafb/efifb used at early boot time. If, however, the DRM driver is *not* in the initrd, Plymouth will display its splash screen via vesafb/efifb.
Next, the system will find the DRM driver for the new card on disk, after switching to the real root. It will attempt to load it, and in the usual case it will replace vesafb/efifb (see do_remove_conflicting_framebuffers() in the Linux kernel). However, since Plymouth has opened /dev/fb0 from userspace, the driver will be unloaded, but the memory region will not be freed. Thus, the DRM driver cannot reserve all of the card's VRAM, and will error out:
[ 10.375907] fb: switching to bochsdrmfb from EFI VGA [ 10.375929] Console: switching to colour dummy device 80x25 [ 10.377266] bochs-drm 0000:00:02.0: BAR 0: can't reserve [mem 0xfc000000-0xfdffffff pref] [ 10.377269] [drm:bochs_hw_init [bochs_drm]] *ERROR* Cannot request framebuffer [ 10.377275] Trying to free nonexistent resource <00000000fc000000-00000000fdffffff> [ 10.377753] bochs-drm: probe of 0000:00:02.0 failed with error -16
The result is a system where X accesses the GPU directly using the VESA driver, and the kernel is unable to display its VTs as /dev/fb0 is already gone.
As a workaround, the system can be booted once with "plymouth.enable=0", and then the initrd can be rebuilt with "mkinitrd". On the next boot, everything should be working as expected.
http://bugzilla.opensuse.org/show_bug.cgi?id=980750 http://bugzilla.opensuse.org/show_bug.cgi?id=980750#c5
--- Comment #5 from Max Staudt mstaudt@suse.com --- (In reply to Ismail Donmez from comment #3)
The upstream "fix" here is just adding a timeout which is well hacky at best. I don't know what would be the right fix here. Any ideas?
I suggest dropping framebuffer support in Plymouth.
Almost nobody should see a difference: All modern x86 systems have DRM driver support as far as I can see, and newer ARM devices are also switching to it. Everybody else will still see a text splash.
Since this is not currently a ./configure option in Plymouth, I suggest simply not packaging /usr/lib64/plymouth/renderers/frame-buffer.so .
http://bugzilla.opensuse.org/show_bug.cgi?id=980750 http://bugzilla.opensuse.org/show_bug.cgi?id=980750#c6
Ismail Donmez idonmez@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |eich@suse.com Flags| |needinfo?(eich@suse.com)
--- Comment #6 from Ismail Donmez idonmez@suse.com --- (In reply to Max Staudt from comment #5)
(In reply to Ismail Donmez from comment #3)
The upstream "fix" here is just adding a timeout which is well hacky at best. I don't know what would be the right fix here. Any ideas?
I suggest dropping framebuffer support in Plymouth.
Almost nobody should see a difference: All modern x86 systems have DRM driver support as far as I can see, and newer ARM devices are also switching to it. Everybody else will still see a text splash.
Since this is not currently a ./configure option in Plymouth, I suggest simply not packaging /usr/lib64/plymouth/renderers/frame-buffer.so .
This is ok for me, let's get Egbert's opinion on this.
http://bugzilla.opensuse.org/show_bug.cgi?id=980750 http://bugzilla.opensuse.org/show_bug.cgi?id=980750#c7
Egbert Eich eich@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Flags|needinfo?(eich@suse.com) |
--- Comment #7 from Egbert Eich eich@suse.com --- I'd prefer a real solution but since this will likely require too much time and effort to implement (we'd have to do it and post it upstream - not wait for upstream to do something), I'm not objecting.
http://bugzilla.opensuse.org/show_bug.cgi?id=980750
Max Staudt mstaudt@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |mmarek@suse.com
http://bugzilla.opensuse.org/show_bug.cgi?id=980750
Ismail Donmez idonmez@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- CC| |sreeves@suse.com Assignee|idonmez@suse.com |qzhao@suse.com
http://bugzilla.opensuse.org/show_bug.cgi?id=980750
Cliff Zhao qzhao@suse.com changed:
What |Removed |Added ---------------------------------------------------------------------------- Status|REOPENED |RESOLVED Resolution|--- |FIXED