Nvidia driver isn't compatible with simpledrm so boot output and TTYs are blank

Hi,

I run Fedora 37 and using nvidia proprietary drivers I cannot access any of my TTYs, and the kernel out during boot (disabling rghb quiet in grub) is blank once the driver gets loaded. As far as I can tell, this was caused by a change in Fedora 36 where fbdev (drivers?) were replaced with CONFIG_DRM and CONFIG_SYSFB_SIMPLEFB. On my gentoo install running the latest nvidia drivers, I can run CONFIG_FB_SIMPLE on my kernel (which I can’t on Fedora because it’s prebuilt) without an issue and I can access my TTYs and watch the boot process on my RTX3070.

There was a bug raised against Fedora for this, where a workaround was implemented: 2071209 – Laptop display is not turning on with simpledrm driver in kernel and Nvidia driver - but the underlying issue is that the nvidia driver currently relies on having the EFIFB driver loaded, and isn’t compatible with simpledrm, so it would be nice if nvidia were to add support for using the simpledrm framebuffer instead.

The workaround for Fedora >= 36 is to have nvidia-drm.modeset=1 be added to the kernel command line (e.g. edit GRUB_CMDLINE_LINUX in /etc/default/grub and regenerate grub config) which will trigger the workaround and should allow everything to work as it did before.

Unfortunately, I already have nvidia-drm.modeset=1 to have Wayland work. My motherboard is old enough that it doesn’t come with an EFI, so what can I do now?

Ah right - well - the patch linked from the bugzilla was supposed to also use the VESAFB when not in UEFI mode, but I’m guessing something there doesn’t quite work for you - not sure if anyone tested the non-UEFI boot mode I’m afraid. I suggest replying to that bugzilla to see what other info you could provide to help understand what’s going on for you.

On my gentoo install running the latest nvidia drivers, I can run CONFIG_FB_SIMPLE on my kernel (which I can’t on Fedora because it’s prebuilt) without an issue and I can access my TTYs and watch the boot process on my RTX3070.

can you explain a little more this?

is kernel 6.x?

greetings

EDIT: apply this patch as “upported” to kernel 6 and add nvidia-drm.modeset=1 to kernel commandline. not works for me :(

diff --git a/drivers/firmware/sysfb.c b/drivers/firmware/sysfb.c
index 2bfbb05f7d896912712679b9999060a2b04e4685..a504f7234f35289fa8b577f10b570ce25dbf28f3 100644
--- a/drivers/firmware/sysfb.c
+++ b/drivers/firmware/sysfb.c
@@ -34,6 +34,22 @@
 #include <linux/screen_info.h>
 #include <linux/sysfb.h>
 
+static int skip_simpledrm;
+
+static int __init simpledrm_disable(char *opt)
+{
+	if (!opt)
+                return -EINVAL;
+
+	get_option(&opt, &skip_simpledrm);
+
+	if (skip_simpledrm)
+		pr_info("The simpledrm driver will not be probed\n");
+
+	return 0;
+}
+early_param("nvidia-drm.modeset", simpledrm_disable);
+
 static __init int sysfb_init(void)
 {
 	struct screen_info *si = &screen_info;
@@ -45,7 +61,7 @@ static __init int sysfb_init(void)
 
 	/* try to create a simple-framebuffer device */
 	compatible = sysfb_parse_mode(si, &mode);
-	if (compatible) {
+	if (compatible && !skip_simpledrm) {
 		pd = sysfb_create_simplefb(si, &mode);
 		if (!IS_ERR(pd))
 			goto unlock_mutex;

(CONFIG_DRM_SIMPLEDRM=y, CONFIG_FB_VESA=y and CONFIG_FB_EFI=y is enabled by default in my kernel (based/used Archlinux package)

EDIT2:
ok. thansks to this Legacy framebuffer broken since 5.18.13 · Issue #341 · NVIDIA/open-gpu-kernel-modules · GitHub the TTY with nvidia and kernel6 is back!!