You are not logged in.
Recently got new Razer Blade 16 with RTX 5090 and been struggling with Xorg. I made it work at first but then decided to run some games via lutris and Xorg stopped running probably after I somehow messed up the configuration. Now I just want it to work, I will play on Windows.
I did everything according to the guide: https://github.com/korvahannu/arch-nvid … tion-guide. Optimus manager service is disabled. I would like the whole graphical session run on RTX GPU.
Xorg log from ~/.local/share/xorg/Xorg.0.log: https://termbin.com/j37s
All installed packages: https://termbin.com/3iuv
journalctl -b: https://termbin.com/10ym
My ~/.xinitrc:
exec i3
Contents of /etc/X11:
/etc/X11
├── xinit
│ ├── xinitrc
│ ├── xinitrc.d
│ │ ├── 40-libcanberra-gtk-module.sh
│ │ ├── 50-systemd-user.sh
│ │ └── 80xapp-gtk3-module.sh
│ └── xserverrc
└── xorg.conf.d
4 directories, 5 files
lspci -nnk | grep -A3 VGA:
c5:00.0 VGA compatible controller [0300]: NVIDIA Corporation GB203M / GN22-X11 [GeForce RTX 5090 Max-Q / Mobile] [10de:2c58] (rev a1)
Subsystem: Razer USA Ltd. Device [1a58:300e]
Kernel modules: nouveau, nvidia_drm, nvidia
c5:00.1 Audio device [0403]: NVIDIA Corporation Device [10de:22e9] (rev a1)
sudo dmesg | grep -i nvidia:
[ 0.000000] Command line: initrd=\initramfs-linux.img root=PARTUUID=c6e41ffd-99cc-4cb2-9b50-d4158180790f zswap.enabled=0 rw rootfstype=ext4 nvidia-drm.modeset=1 nvidia-drm.fbdev=1
[ 0.041063] Kernel command line: initrd=\initramfs-linux.img root=PARTUUID=c6e41ffd-99cc-4cb2-9b50-d4158180790f zswap.enabled=0 rw rootfstype=ext4 nvidia-drm.modeset=1 nvidia-drm.fbdev=1
[ 4.115434] input: HDA NVidia HDMI/DP,pcm=3 as /devices/pci0000:00/0000:00:03.1/0000:c5:00.1/sound/card0/input17
[ 309.694204] nvidia: loading out-of-tree module taints kernel.
[ 309.694219] nvidia: module verification failed: signature and/or required key missing - tainting kernel
[ 309.794701] nvidia-nvlink: Nvlink Core is being initialized, major device number 234
[ 309.797795] nvidia 0000:c5:00.0: enabling device (0000 -> 0003)
[ 309.798186] nvidia 0000:c5:00.0: vgaarb: VGA decodes changed: olddecodes=io+mem,decodes=none:owns=none
[ 309.808511] NVRM: loading NVIDIA UNIX Open Kernel Module for x86_64 575.64 Release Build (root@)
[ 310.415951] nvidia 0000:c5:00.0: Enabling HDA controller
nvidia-smi:
Thu Jun 26 10:58:24 2025
+-----------------------------------------------------------------------------------------+
| NVIDIA-SMI 575.64 Driver Version: 575.64 CUDA Version: 12.9 |
|-----------------------------------------+------------------------+----------------------+
| GPU Name Persistence-M | Bus-Id Disp.A | Volatile Uncorr. ECC |
| Fan Temp Perf Pwr:Usage/Cap | Memory-Usage | GPU-Util Compute M. |
| | | MIG M. |
|=========================================+========================+======================|
| 0 NVIDIA GeForce RTX 5090 ... Off | 00000000:C5:00.0 Off | N/A |
| N/A 45C P4 19W / 50W | 0MiB / 24463MiB | 2% Default |
| | | N/A |
+-----------------------------------------+------------------------+----------------------+
+-----------------------------------------------------------------------------------------+
| Processes: |
| GPU GI CI PID Type Process name GPU Memory |
| ID ID Usage |
|=========================================================================================|
| No running processes found |
+-----------------------------------------------------------------------------------------+
systemd-boot config at /boot/loader/entries/***.conf
# Created by: archinstall
# Created on: 2025-06-11_09-50-15
title Arch Linux (linux)
linux /vmlinuz-linux
initrd /initramfs-linux.img
options root=PARTUUID=c6e41ffd-99cc-4cb2-9b50-d4158180790f zswap.enabled=0 rw rootfstype=ext4 nvidia-drm.modeset=1 nvidia-drm.fbdev=1
/etc/mkinitcpio.conf:
# vim:set ft=sh
# MODULES
# The following modules are loaded before any boot hooks are
# run. Advanced users may wish to specify all system modules
# in this array. For instance:
# MODULES=(usbhid xhci_hcd)
MODULES=(nvidia nvidia_modeset nvidia_uvm nvidia_drm)
# BINARIES
# This setting includes any additional binaries a given user may
# wish into the CPIO image. This is run last, so it may be used to
# override the actual binaries included by a given hook
# BINARIES are dependency parsed, so you may safely ignore libraries
BINARIES=()
# FILES
# This setting is similar to BINARIES above, however, files are added
# as-is and are not parsed in any way. This is useful for config files.
FILES=()
# HOOKS
# This is the most important setting in this file. The HOOKS control the
# modules and scripts added to the image, and what happens at boot time.
# Order is important, and it is recommended that you do not change the
# order in which HOOKS are added. Run 'mkinitcpio -H <hook name>' for
# help on a given hook.
# 'base' is _required_ unless you know precisely what you are doing.
# 'udev' is _required_ in order to automatically load modules
# 'filesystems' is _required_ unless you specify your fs modules in MODULES
# Examples:
## This setup specifies all modules in the MODULES setting above.
## No RAID, lvm2, or encrypted root is needed.
# HOOKS=(base)
#
## This setup will autodetect all modules for your system and should
## work as a sane default
# HOOKS=(base udev autodetect modconf block filesystems fsck)
#
## This setup will generate a 'full' image which supports most systems.
## No autodetection is done.
# HOOKS=(base udev modconf block filesystems fsck)
#
## This setup assembles a mdadm array with an encrypted root file system.
## Note: See 'mkinitcpio -H mdadm_udev' for more information on RAID devices.
# HOOKS=(base udev modconf keyboard keymap consolefont block mdadm_udev encrypt filesystems fsck)
#
## This setup loads an lvm2 volume group.
# HOOKS=(base udev modconf block lvm2 filesystems fsck)
#
## This will create a systemd based initramfs which loads an encrypted root filesystem.
# HOOKS=(base systemd autodetect modconf kms keyboard sd-vconsole sd-encrypt block filesystems fsck)
#
## NOTE: If you have /usr on a separate partition, you MUST include the
# usr and fsck hooks.
HOOKS=(base udev autodetect microcode modconf keyboard keymap consolefont block filesystems fsck)
# COMPRESSION
# Use this to compress the initramfs image. By default, zstd compression
# is used for Linux ≥ 5.9 and gzip compression is used for Linux < 5.9.
# Use 'cat' to create an uncompressed image.
#COMPRESSION="zstd"
#COMPRESSION="gzip"
#COMPRESSION="bzip2"
#COMPRESSION="lzma"
#COMPRESSION="xz"
#COMPRESSION="lzop"
#COMPRESSION="lz4"
# COMPRESSION_OPTIONS
# Additional options for the compressor
#COMPRESSION_OPTIONS=()
# MODULES_DECOMPRESS
# Decompress loadable kernel modules and their firmware during initramfs
# creation. Switch (yes/no).
# Enable to allow further decreasing image size when using high compression
# (e.g. xz -9e or zstd --long --ultra -22) at the expense of increased RAM usage
# at early boot.
# Note that any compressed files will be placed in the uncompressed early CPIO
# to avoid double compression.
#MODULES_DECOMPRESS="no"
modprobe -c | grep -v alias | grep nvidia:
blacklist nvidia_drm
blacklist nvidia_uvm
blacklist nvidia_modeset
blacklist nvidia
options nvidia NVreg_PreserveVideoMemoryAllocations=1
options nvidia NVreg_TemporaryFilePath=/var/tmp
options nvidia_drm modeset=1
options nvidia_drm fbdev=1
System info:
OS: Arch Linux x86_64
Host: Blade 16 - RZ09-0528 (11.04)
Kernel: Linux 6.15.3-arch1-1
Shell: zsh 5.9
Display (SDC41AE): 2560x1600 @ 240 Hz in 16" [Built-in]
CPU: AMD Ryzen AI 9 HX 370 (24) @ 5.16 GHz
GPU 1: AMD Radeon 890M Graphics [Integrated]
GPU 2: NVIDIA GeForce RTX 5090 Max-Q / Mobile [Discrete]
Locale: en_US.UTF-8
Last edited by furiousteabag (2025-06-27 13:42:26)
Offline
Jun 26 10:53:14 furiouspc kernel: Linux version 6.15.3-arch1-1 (linux@archlinux) (gcc (GCC) 15.1.1 20250425, GNU ld (GNU Binutils) 2.44.0) #1 SMP PREEMPT_DYNAMIC Thu, 19 Jun 2025 14:41:19 +0000
…
Jun 26 10:54:42 furiouspc sudo[1419]: furiousteabag : TTY=pts/0 ; PWD=/home/furiousteabag ; USER=root ; COMMAND=/usr/bin/pacman -Qs
Jun 26 10:54:42 furiouspc sudo[1419]: pam_unix(sudo:session): session opened for user root(uid=0) by furiousteabag(uid=1000)
Jun 26 10:54:42 furiouspc sudo[1419]: pam_unix(sudo:session): session closed for user root
Jun 26 10:58:20 furiouspc kernel: nvidia: loading out-of-tree module taints kernel.
Jun 26 10:58:20 furiouspc kernel: nvidia: module verification failed: signature and/or required key missing - tainting kernel
Jun 26 10:58:20 furiouspc kernel: nvidia-nvlink: Nvlink Core is being initialized, major device number 234
Jun 26 10:58:20 furiouspc kernel:
Jun 26 10:58:20 furiouspc kernel: nvidia 0000:c5:00.0: enabling device (0000 -> 0003)
The nvidia module loads very late and maybe only explicitly. nvidia_uvm is certainly blacklisted
modprobe -c | grep -v alias | grep nvidia
Might relate to optimus-manager?
Offline
I've edited the initial post to add that the optimus-manager service is disabled. Also there are no config files left from it. Maybe it may affect the setup in some other way unknown to me.
modprobe -c | grep -v alias | grep nvidia:
blacklist nvidia_drm
blacklist nvidia_uvm
blacklist nvidia_modeset
blacklist nvidia
options nvidia NVreg_PreserveVideoMemoryAllocations=1
options nvidia NVreg_TemporaryFilePath=/var/tmp
options nvidia_drm modeset=1
options nvidia_drm fbdev=1
Last edited by furiousteabag (2025-06-26 08:47:29)
Offline
Yeah, there's the blacklist.
grep -r nvidia /etc/modprobe.d
Might also be a stale entry in the initramfs, so re-run mkinitcpio.
Offline
I've regenerated initramfs with
sudo mkinitcpio -P
but it didn't affect the blacklist from the above.
grep -r nvidia /etc/modprobe.d
is empty
Offline
Did you reboot afterwards? Otherwise the new initramfs won't apply.
Offline
I did reboot and it didn't change anything, BUT after I've removed optimus-manager-git package completely (not just disable), I am able to load the X session (but it shows only the black screen).
Modules seem to be load correctly, not blacklisted (modprobe -c | grep -v alias | grep nvidia):
options nvidia NVreg_PreserveVideoMemoryAllocations=1
options nvidia NVreg_TemporaryFilePath=/var/tmp
options nvidia_drm modeset=1
options nvidia_drm fbdev=1
Regarding the black screen, here's the new Xorg log (black screen one): https://termbin.com/e12ai
Edit 1: Another piece of useful info might be that if I connect external monitor over HDMI, it loads the X session on the monitor correctly. I am also able to switch monitor to the build-in one using xrandr after the session was loaded on the external monitor. I'd like the session to open on a build-in monitor, without needing to connect external one in advance.
Edit 2: Seems like if I add
xrandr --output eDP-1-1 --auto
to the .xinitrc it loads the X session on the build-in monitor correctly. Wondering if it is how it is supposed to be working!
Last edited by furiousteabag (2025-06-26 09:09:38)
Offline
Your nvidia card is the default but doesn't seem to have a monitor connected to it.
Does the (uefi.bios) firmware allow you to choose between internal and external gpu ?
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Lone_Wolf, see my edits to the last reply. I managed to make it work, but just not sure if it is the right way to specify output screen right in the .xinitrc
Offline
It's not supposed to be needed.
Your laptop appears to be using a hybrid grapics setup.
In such setups the built-in monitor is typically connected to the primary gpu and the secondary gpu can only use it through the primary.
The symptoms match with hw & X treating things differently .
Your hw seems to have the amd as primary and nvidia as secondary while X sees them in reverse .
Adjusting the hw setup to use nvidia as primary is the simplest/stablest method to solve that. Unfortunately not all firmware expose that option to the user.
P.S. your ~/.xinitrc is broken , see https://wiki.archlinux.org/title/Xinit#xinitrc
Disliking systemd intensely, but not satisfied with alternatives so focusing on taming systemd.
clean chroot building not flexible enough ?
Try clean chroot manager by graysky
Offline
Thanks for pointing out that my ~/.xinitrc is broken, I've prepended the default setup code to my .xinitrc
In my Bios settings in the Chipset -> GPU MODE I have two options:
1. NVIDIA(R) Dynamic Display Switch (currently selected)
2. Dedicated GPU only
I am not sure what is better for me and what is generally considered better.
Edit 1: seems like you were right when you said about hw/xorg gpu's priorities. When I changed from 1 to 2 in Bios then I am not getting black screen anymore on the build-in monitor on login (after removal of output selection via xrandr in the ~/.xinitrc)
Edit 2: now I am wondering if it is a generally good setup? Say I have a GPU intensive app (e.g. LLM running), does it mean that now my whole X session will lag because of that? How do I defend against that? Running X session on the integrated GPU and explicitly launching GPU-intensive applications on the dedicated one?
Last edited by furiousteabag (2025-06-26 10:44:58)
Offline
The normal setup is to run the session on the integrated chip and prime-run superturboturkeypuncher³ for the highest frag-rate.
If you constantly run on the GPU, it's advisable to disable the IGP in the BIOS (option 2) as that will cut unnecessary complexity and overhead, but you'll still use up more battery than just running on the IGP (w/ occasional GPU for games etc)
The server likely trips over the extremely uncommon bus configuration (197:0:0 & 198:0:0) so you'll have to steer it towards the AMD GPU:
https://wiki.archlinux.org/title/PRIME#Configuration
Section "ServerLayout"
Identifier "layout"
Screen 0 "amdgpu"
Inactive "nvidia"
Option "AllowNVIDIAGPUScreens"
EndSection
Section "Device"
Identifier "nvidia"
Driver "nvidia"
EndSection
Section "Screen"
Identifier "nvidia"
Device "nvidia"
EndSection
Section "Device"
Identifier "amdgpu"
Driver "modesetting"
BusID "PCI:198:0:0"
EndSection
Section "Screen"
Identifier "amdgpu"
Device "amdgpu"
EndSection
This will hopefully get you the normal layout and the ability to "prime-run superturboturkeypuncher³" on the nvidia GPU.
You can verify this w/
glxinfo -B; prime-run glxinfo -B
Offline
I enabled back option 1 in the BIOS (NVIDIA(R) Dynamic Display Switch) and used the config that you've provided. Everything seems to work as you've described now, huge thanks!
glxinfo -B:
name of display: :0
display: :0 screen: 0
direct rendering: Yes
Extended renderer info (GLX_MESA_query_renderer):
Vendor: AMD (0x1002)
Device: AMD Radeon 890M Graphics (radeonsi, gfx1150, LLVM 20.1.6, DRM 3.63, 6.15.3-arch1-1) (0x150e)
Version: 25.1.4
Accelerated: yes
Video memory: 512MB
Unified memory: no
Preferred profile: core (0x1)
Max core profile version: 4.6
Max compat profile version: 4.6
Max GLES1 profile version: 1.1
Max GLES[23] profile version: 3.2
Memory info (GL_ATI_meminfo):
VBO free memory - total: 56 MB, largest block: 56 MB
VBO free aux. memory - total: 31469 MB, largest block: 31469 MB
Texture free memory - total: 56 MB, largest block: 56 MB
Texture free aux. memory - total: 31469 MB, largest block: 31469 MB
Renderbuffer free memory - total: 56 MB, largest block: 56 MB
Renderbuffer free aux. memory - total: 31469 MB, largest block: 31469 MB
Memory info (GL_NVX_gpu_memory_info):
Dedicated video memory: 512 MB
Total available memory: 32212 MB
Currently available dedicated video memory: 56 MB
OpenGL vendor string: AMD
OpenGL renderer string: AMD Radeon 890M Graphics (radeonsi, gfx1150, LLVM 20.1.6, DRM 3.63, 6.15.3-arch1-1)
OpenGL core profile version string: 4.6 (Core Profile) Mesa 25.1.4-arch1.1
OpenGL core profile shading language version string: 4.60
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL version string: 4.6 (Compatibility Profile) Mesa 25.1.4-arch1.1
OpenGL shading language version string: 4.60
OpenGL context flags: (none)
OpenGL profile mask: compatibility profile
OpenGL ES profile version string: OpenGL ES 3.2 Mesa 25.1.4-arch1.1
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20
prime-run glxinfo -B:
name of display: :0
display: :0 screen: 0
direct rendering: Yes
Memory info (GL_NVX_gpu_memory_info):
Dedicated video memory: 24463 MB
Total available memory: 24463 MB
Currently available dedicated video memory: 22957 MB
OpenGL vendor string: NVIDIA Corporation
OpenGL renderer string: NVIDIA GeForce RTX 5090 Laptop GPU/PCIe/SSE2
OpenGL core profile version string: 4.6.0 NVIDIA 575.64
OpenGL core profile shading language version string: 4.60 NVIDIA
OpenGL core profile context flags: (none)
OpenGL core profile profile mask: core profile
OpenGL version string: 4.6.0 NVIDIA 575.64
OpenGL shading language version string: 4.60 NVIDIA
OpenGL context flags: (none)
OpenGL profile mask: (none)
OpenGL ES profile version string: OpenGL ES 3.2 NVIDIA 575.64
OpenGL ES profile shading language version string: OpenGL ES GLSL ES 3.20
One question though. In the wiki page you've pointed to, they are searching for bus id via
lspci -d ::03xx
which in my case is:
c5:00.0 VGA compatible controller: NVIDIA Corporation GB203M / GN22-X11 [GeForce RTX 5090 Max-Q / Mobile] (rev a1)
c6:00.0 Display controller: Advanced Micro Devices, Inc. [AMD/ATI] Strix [Radeon 880M / 890M] (rev c1)
Why we are specifying "PCI:198:0:0" in the config?
Answered myself: c6 is in the hexadecimal format. In the decimal format it is 198.
Offline