Black screen when switching to Xorg console with nvidia driver 545 or newer

Hello,
When I switch to Xorg console from text console or other Xorg with Ctrl-Alt-FN I often get black screen with mouse cursor only.

Video card: nVidia 2060 Super
OS: Fedora 39

The problem appeared after upgrading kernel 6.5 to 6.6 and nvidia driver 535.129.03 to 545.29.06. Now I use kernel 6.7.9 and driver 550.54.14 with the same problem. It happens about 9 of 10 times.

Steps to reproduce:

  1. Install nvidia driver 545 or newer.
  2. Start Xorg session.
  3. Switch to text virtual console with Ctrl-Alt-FN (always works fine).
  4. Switch back to Xorg console with Alt-FN.
  5. Repeat steps 3 and 4 many times.

Actual results: black screen with mouse cursor on Xorg console.

Expected results: fully functional Xorg console.

nvidia-bug-report.log.gz (439.1 KB)

Remove these obsolete/alien options from the boot cmdline

initcall_blacklist=simpledrm_platform_driver_init nvidia-drm.modeset=1

They are harmful to the default I set in the rpmfusion driver (both disable simpledrm).

Removed them. But nothing has changed after reboot.

nvidia-bug-report.log.gz (467.0 KB)

If you want to use efifb, you need to set.
Try adding these options.

nvidia-drm.modeset=1 nvidia-drm.fbdev=0

1: nvidia-drm.modeset=1 added to the cmdline disables simpledrm in fedora kernel
2: nvidia-drm.fbdev=0 disables the new nvidia framebuffer

Thanks! The problem is partially solved. Now console switching works much better. About first 15 times switching to text console and back to Xorg have completed without any problems. Then I’ve got black screen with mouse cursor again. But the screen is restored after ~20 seconds.

What about efifb. I don’t want to use exactly efifb. And don’t know which is better: efifb or nvidia fbdev. I just want switching between console works as it should be. I’m guessing nvidia fbdev is a new driver feature that doesn’t work properly yet or requires some tuning.

nvidia-bug-report.log.gz (697.2 KB)

And switching between two Xorg consoles still doesn’t work. First Xorg is always ok. Second Xorg is always black screen.

Any ideas on how to fix the black screen when switching between two Xorg consoles? This is reproduced for me 100% of the time.

I have now installed 550.78 driver, but the problem remains. I also tried uninstalling the current driver, clearing everything related to nvidia and installing driver 550.78 without any tuning. The problem still exists.

Can anyone reproduce the issue? Or it only affects my specific installation.

If you set nvidia-drm.fbdev to 0 which is the default value, the simpledrmfb driver will be loaded even if nvidia-drm.modeset is set to 1. You have to set nvidia-drm.modeset=1 and nvidia-drm.fbdev=1 to replace simpledrmfb by nvidia-drmfb.

I’ve tried all 4 combinations of nvidia-drm.modeset and nvidia-drm.fbdev. It has no effect on the described problem.

Do you have the same problem on Wayland sessions ?
Note: You have to put the nvidia-drm.modeset=1 kernel command line in order to use Wayland.

I use XFCE that doesn’t support Wayland.

I’ve discovered that the problem is related to the compatibility of the 545+ driver with compositing in XFCE. The problem goes away if compositing is disabled (Settings → Window Manager Tweaks → Compositor → Enable display compositing). This option is enabled by default.

And one more strange feature: if you delete <property name="use_compositing" type="bool" value="..."/> from ~/.config/xfce4/xfconf/xfce-perchannel-xml/xfwm4.xml and then start xfce session, the problem does not occur with compositing enabled. But if you turn compositing off and on, the problem returns.