2024年4月18日

HYEOS

随事而为

Gentoo xorg.conf

1 min read

Gentoo我的xorg.conf配置文档,双显卡:INTEL核显+NVIDIA独显

Section "ServerLayout"
    Identifier "layout"
    Screen 0 "nvidia"
    Inactive "intel"
EndSection

Section "Device"
    Identifier "nvidia"
    Driver "nvidia"
    BusID "01:00:0"
    Option "RegistryDwords" "EnableBrightnessControl=1"
EndSection

Section "Screen"
    Identifier "nvidia"
    Device "nvidia"
    Option "AllowEmptyInitialConfiguration"
EndSection

Section "Device"
    Identifier "intel"
    Driver "modesetting"
    BusID "00:02:0"
EndSection

Section "Screen"
    Identifier "intel"
    Device "intel"
EndSection

设置xorg.conf后使用sddm启动不一定能启动桌面,设置另一配置文档,

//修改startx或DM的启动脚本
//用的DM是SDDM,需要修改/usr/share/sddm/scripts/Xsetup文件,在该文件末尾添加以下内容:
xrandr --setprovideroutputsource modesetting NVIDIA-0
xrandr --auto

//如果用的是startx,在~/.xinitrc中启动DE或WM的命令之前添加

xrandr --setprovideroutputsource modesetting NVIDIA-0
xrandr --auto

 

 

 

发表回复

您的电子邮箱地址不会被公开。 必填项已用 * 标注