Git Product home page Git Product logo

freebsd-nvidia-optimus's Introduction

FreeBSD Nvidia Optimus Driver

This is a modified version of the x11/nvidia-driver that works with Nvidia optimus (muxless) laptops. This package also provides utilities to make it easier to run programs on the Nvidia GPU.

Install

You can install this in 2 ways, one way is to grab the binaries from releases. and then install using pkg:

pkg install nvidia-optimus-driver-430.34.txz

or

pkg install nvidia-optimus-driver-390-390.116.txz

Please note these binaries are built on FreeBSD 12.

To build this on your system, you should clone this repo (or download the source) then do:

make install

or

make package

and then install using pkg.

Using

To use Nvidia optimus driver, you need to start the optimus service. To do that, you can add

optimus_enable="YES"

to /etc/rc.conf

Alternatively you can do

service optimus onestart

The optimus service provides a few configurable options:

optimus_manage_kld: allow optimus to manage kldload/unload of
                    the Nvidia kernel modules (default="YES")
optimus_modeset:    load Nvidia modeset kernel driver
                    (default="YES")
optimus_screen:     Screen number for running the optimus X
                    server (default="8")
optimus_x_conf:     Config file to use for X. If this doesn't
                    exist it will be generated automatically.
                    You should probably check the PCI address
                    specified in the generated config file as
                    it is extracted from pciconf automatically.
                    (default="/usr/local/etc/X11/optimus.x.conf")
optimus_x_flags:    optimus X server flags
                    (default="-sharevts -noreset")

If you don't want optimus manage your kldload/unloads, you must load nvidia.ko and/or nvidia-modeset.ko yourself. Refer to x11/nvidia-driver for more info about this.

After you have the service running, you can use the provided optirun command to run your programs on the Nvidia GPU:

optirun glxgears

freebsd-nvidia-optimus's People

Contributors

pouya-eghbali avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.