FS#73720 - [linux-zen] using new DRM based Linux fb driver instead legacy fbdev driver as Fedora do
Attached to Project:
Arch Linux
Opened by Celeste (Coelacanthus) - Thursday, 10 February 2022, 15:18 GMT
Last edited by Toolybird (Toolybird) - Monday, 25 September 2023, 06:05 GMT
Opened by Celeste (Coelacanthus) - Thursday, 10 February 2022, 15:18 GMT
Last edited by Toolybird (Toolybird) - Monday, 25 September 2023, 06:05 GMT
|
Details
Since 5.14, linux kernel provide new DRM fbdev emulate
layer.
As Fedora said, a well-maintained modern driver is better than an old driver, which is even leak maintained. So I suggest linux-zen enable this new driver as Fedora do. Fedora also lists some benefits in link below. https://fedoraproject.org/wiki/Changes/ReplaceFbdevDrivers |
This task depends upon
Closed by Toolybird (Toolybird)
Monday, 25 September 2023, 06:05 GMT
Reason for closing: Implemented
Monday, 25 September 2023, 06:05 GMT
Reason for closing: Implemented
FS#72645They will go even further in Fedora 39:
https://fedoraproject.org/wiki/Changes/LegacyXorgDriverRemoval
What a shame NVIDIA.
https://bugzilla.redhat.com/show_bug.cgi?id=2161104#c83
525 nvidia driver (both open and closed) now support simpledrm?
FS#77603.FS#77603was with 525.89.02.525.105.17 release notes:
"Added support for console restoration when using simpledrm."
https://www.nvidia.com/download/driverResults.aspx/202504/
Who knows...
https://gitlab.com/cki-project/kernel-ark/-/commit/811fe0e4dcfd86a0db5135d3bfef4936794efdb6
(buried here: https://src.fedoraproject.org/rpms/kernel/blob/f38/f/patch-6.4-redhat.patch )
@marcosfrm, please see
FS#79306(even though it looks like a hyprland crash, maybe this kernel config option is the cause?). Any comments?After upgrading my kernel from 6.4.7.arch1-3 to 6.4.8.arch1-1 and 6.4.9.arch1 GDM cannot start Wayland nor X anymore due to segfault (see attachment)
I do not have nvidia-drm.modeset=1 in kernel cmdline, but do in /etc/modprobe.d/nvidia-drm.conf:
➜ cat /etc/modprobe.d/nvidia-drm.conf
options nvidia_drm modeset=1
I tried to add nvidia modules to initrd and move nvidia_drm modeset=1 to kernel cmdline, but got no effect
When using 6.4.7.arch1-3 kernel I'm able to run both X and Wayland sessions:
➜ echo $XDG_SESSION_TYPE
wayland
With nvidia-drm.modeset=1 in kernel cmdline, even without nvidia modules in initrd, X/Wayland starts normally.
If nvidia-drm.modeset=1 kernel options is absent, nvidia driver starts to segfault even if modeset is enabled using /etc/modprobe.d/.
My current cmdline is "init=/usr/lib/systemd/systemd quiet loglevel=3 rd.systemd.show_status=auto rd.udev.log_priority=3 modules-load=nvidia nvidia-drm.modeset=1"
My misconfigured cmdline was "init=/usr/lib/systemd/systemd quiet loglevel=3 rd.systemd.show_status=auto rd.udev.log_priority=3 modules-load=nvidia"
Great.
We should mention in the Wiki nvidia-drm.modeset=1 is required now. Btw, the option is wrong there:
https://wiki.archlinux.org/title/NVIDIA#DRM_kernel_mode_setting
# env = GBM_BACKEND,nvidia-drm
(which was set in hyprland.conf) (this could have been set .bashrc/.bash_profile)
I also have
> cat /etc/modprobe.d/nvidia.conf
options nvidia_drm modeset=1
Also have this
> cat /proc/cmdline
BOOT_IMAGE=/vmlinuz-linux root=UUID=223628a8-299a-4e2b-84b8-e6ea139ffa49 rw loglevel=3 quiet
I did not have the GRUB_CMDLINE_DEFAULT option set.
Although Hyprland updated wiki has the kernel command line option as ;
"...
For people using systemd-boot you can do this adding nvidia_drm.modeset=1 to the end of /boot/loader/entries/arch.conf. For people using grub you can do this by adding nvidia_drm.modeset=1 to the end of GRUB_CMDLINE_LINUX_DEFAULT= in /etc/default/grub, then run # grub-mkconfig -o /boot/grub/grub.cfg
..."
I thought this might help too.
@salimp2009 starting with 6.4.8.arch1-1 and 6.4.8.zen1-1, if you do not set nvidia-drm.modeset=1, simpledrm *will* activate. Nvidia added some code to support it in 525 branch with mixed success reports. Maybe it is working for you...
Btw, openSUSE kernels have the same patch.
So I guess misunderstood prev comment about nvidia-drm.modeset=1 is needed in kernel cmdline
https://github.com/NVIDIA/open-gpu-kernel-modules/blob/535.98/kernel-open/nvidia-drm/nvidia-drm-linux.c#L46
Fedora patch uses early_param() therefore will work with both. Hence the Wiki is ok.