[PC-BSD Commits] r19425 - pcbsd/current/overlays/install-overlay/etc

svn at pcbsd.org svn at pcbsd.org
Thu Sep 20 08:16:29 PDT 2012


Author: kris
Date: 2012-09-20 15:16:29 +0000 (Thu, 20 Sep 2012)
New Revision: 19425

Added:
   pcbsd/current/overlays/install-overlay/etc/pcbsd-video.sh
Modified:
   pcbsd/current/overlays/install-overlay/etc/SetupInstall.sh
   pcbsd/current/overlays/install-overlay/etc/SetupLive.sh
Log:

Add detection for NVIDIA Optimus systems. If found, we skip loading the
nvidia driver and default to intel graphics. If a vanilla NVIDIA is found
we can safely kldload the nvidia driver. 



Modified: pcbsd/current/overlays/install-overlay/etc/SetupInstall.sh
===================================================================
--- pcbsd/current/overlays/install-overlay/etc/SetupInstall.sh	2012-09-20 13:30:46 UTC (rev 19424)
+++ pcbsd/current/overlays/install-overlay/etc/SetupInstall.sh	2012-09-20 15:16:29 UTC (rev 19425)
@@ -34,19 +34,15 @@
   # End of loading if we have > 512MB ram
 fi
 
+PATH="${PATH}:/usr/bin"
+export PATH
 
 # Load the extra klds we need
 /etc/rc.d/kld start
 
-# Check if we should load the nvidia driver
-/usr/sbin/pciconf -lv | grep -q -e "nVidia" -e "NVIDIA" -e "nvidia"
-if [ $? -eq 0 ] ; then
-  kldload nvidia
-fi
+# Check for optimus / video drivers
+/etc/pcbsd-video.sh
 
-PATH="${PATH}:/usr/bin"
-export PATH
-
 # See if we have install / meta pkgs for the front-end to use
 if [ -e "/dist/no-meta-pkgs" ] ; then touch /tmp/no-meta-pkgs ; fi
 if [ -e "/dist/no-install-pkgs" ] ; then touch /tmp/no-install-pkgs ; fi

Modified: pcbsd/current/overlays/install-overlay/etc/SetupLive.sh
===================================================================
--- pcbsd/current/overlays/install-overlay/etc/SetupLive.sh	2012-09-20 13:30:46 UTC (rev 19424)
+++ pcbsd/current/overlays/install-overlay/etc/SetupLive.sh	2012-09-20 15:16:29 UTC (rev 19425)
@@ -45,11 +45,8 @@
 # Load the extra klds we need
 /etc/rc.d/kld start
 
-# Check if we should load the nvidia driver
-/usr/sbin/pciconf -lv | grep -q -e "nVidia" -e "NVIDIA" -e "nvidia"
-if [ $? -eq 0 ] ; then
-  kldload nvidia
-fi
+# Check for optimus / video drivers
+/etc/pcbsd-video.sh
 
 # See if we have install / meta pkgs for the front-end to use 
 if [ -e "/dist/no-meta-pkgs" ] ; then touch /tmp/no-meta-pkgs ; fi

Index: pcbsd/current/overlays/install-overlay/etc/pcbsd-video.sh
===================================================================
--- pcbsd/current/overlays/install-overlay/etc/pcbsd-video.sh	2012-09-20 13:30:46 UTC (rev 19424)
+++ pcbsd/current/overlays/install-overlay/etc/pcbsd-video.sh	2012-09-20 15:16:29 UTC (rev 19425)

Property changes on: pcbsd/current/overlays/install-overlay/etc/pcbsd-video.sh
___________________________________________________________________
Added: svn:executable
## -0,0 +1 ##
+*


More information about the Commits mailing list