Add NVIDIA driver to built-in Xorg configuration?

Arto Pekkanen isoa at kapsi.fi
Tue Jul 19 18:26:02 UTC 2016


Kris Moore kirjoitti 19.07.2016 18:09:
> On 07/19/2016 10:32, Tobias Kortkamp wrote:
>> Hi,
>> 
>> would it be possible to include the following patch in
>> x11-servers/xorg-server?  It adds the NVIDIA driver to the built-in X
>> configuration.  It would remove the need to have an xorg.conf on 
>> systems
>> with an NVIDIA GPU which have to use x11/nvidia-driver.  I think it's 
>> a
>> source of unnecessary friction that doesn't really need to be there.  
>> It
>> was deceptively simple to add, so I'm sure I'm missing something. ;-)
>> 
>> Thanks,
>> Tobias
>> 
>> https://cgit.freedesktop.org/xorg/xserver/tree/hw/xfree86/common/xf86pciBus.c?id=xorg-server-1.17.4#n1187
>> ===================================================================
>> --- files/patch-hw_xfree86_common_xf86pciBus.c  (nonexistent)
>> +++ files/patch-hw_xfree86_common_xf86pciBus.c  (working copy)
>> @@ -0,0 +1,10 @@
>> +--- hw/xfree86/common/xf86pciBus.c.orig        2016-07-19
>> 15:37:53.698794484 +0200
>> ++++ hw/xfree86/common/xf86pciBus.c     2016-07-19 15:37:26.000000000
>> +0200
>> +@@ -1192,6 +1192,7 @@
>> + #ifdef __linux__
>> +         driverList[idx++] = "nouveau";
>> + #endif
>> ++        driverList[idx++] = "nvidia";
>> +         driverList[idx++] = "nv";
>> +         break;
>> +     }
>> _______________________________________________
>> freebsd-x11 at freebsd.org mailing list
>> https://lists.freebsd.org/mailman/listinfo/freebsd-x11
>> To unsubscribe, send any mail to "freebsd-x11-unsubscribe at freebsd.org"
> 
> Ohh, we've been bit by that a bunch. I'm going to include this in 
> PC-BSD
> also. Thanks!

Bad idea, since nVidia driver is proprietary and must be installed 
separately. Thus it is only logical to have it configured separately. 
This is important to maintain a distiction between the bundled X.org 
drivers vs. 3rd party drivers.

Also, currently the nVidia driver is broken on many FreeBSD versions due 
to KMS/DRM integration or lack thereof. Having X.org load nVidia 
automatically is just gonna cause a lot of trouble for the end user.

And then there's the problem with nVidia Optimus laptops, where by 
default only the Intel driver works since the nVidia chip is not wired 
to any of the standard video outputs. Having nVidia auto loaded is just 
yet another problem waiting to happen.

Why would PC-BSD even benefit from having nVidia auto loaded? The 
integration scripts should suggest enabling nVidia driver if compatible 
hardware is detected (ie. non-Optimus nVidia hardware, or Optimus where 
IGP outpus have been rewired to nVidia via BIOS). If the nVidia driver 
does not work, then the end user would actually realize, from context, 
that it was the nVidia driver that had problems. In case of problems if 
nVidia gets auto loaded without any notification to the user about it, 
then the user will be totally in the dark regarding why X.org won't 
start.

Not even Linux distros auto load the proprietary nVidia driver. And for 
a good reason.

-- 
Arto Pekkanen


More information about the freebsd-x11 mailing list