Skip to content

Add a separate config file for loading nvidia modules #2166

@Daemonratte

Description

@Daemonratte

Describe the feature

Some repos or installers will overwrite 10-nvidia.conf, resulting in broken glx for the xlibre session.
An example would be installing the proprietary nvidia driver from the xanmod repo.

Someone noted here that he had to symlink nvidia_drv.so into the xlibre module path for it to work and my guess is it's because of a driver installer overwriting /usr/share/X11/xorg.conf.d/10-nvidia.conf

My proposal:
add a separate config for loading the necessary modules.
/usr/share/X11/xorg.conf.d/11-nvidia-modules.conf

Section "OutputClass"
    Identifier "nvidia-modules"
    MatchDriver "nvidia-drm"
    Module "glx"
    Module "glxserver_nvidia"
    ModulePath "/usr/lib/x86_64-linux-gnu/nvidia/xorg"
EndSection

/usr/share/X11/xorg.conf.d/10-nvidia.conf can be left as is (it will be overwritten anyways)

Section "OutputClass"
    Identifier "nvidia"
    MatchDriver "nvidia-drm"
    Driver "nvidia"
    Option "AllowEmptyInitialConfiguration"
    ModulePath "/usr/lib/x86_64-linux-gnu/nvidia/xorg"
EndSection

This way the setup will (hopefully) be more bulletproof

It should be implemented because

Xlibre just won't work with any hardwareaccelaration without this fix on some setups.
Having a separate config prevents errors caused by installers overwriting 10-nvidia.conf.
Also prevents issues when updating nvidia drivers (could also overwrite 10-nvidia.conf)

What are the alternatives?

Symlinking everything in /usr/lib/x86_64-linux-gnu/nvidia/xorg to /usr/lib/xorg/modules lol

Additional context

Someone noted an issue here: https://github.com/X11Libre/xserver/wiki/Graphics-devices-&-drivers#nvidia
This might also be related to it: xlibre-debian/devuan#10

Extra fields

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestneeds-triageThis needs to be reviewed and categorized.

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions