Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 5 Apr 2021 21:12:34 GMT
From:      Warner Losh <imp@FreeBSD.org>
To:        doc-committers@FreeBSD.org, dev-commits-doc-all@FreeBSD.org
Subject:   git: 9068516015 - main - x11: document the latest best advice about graphics
Message-ID:  <202104052112.135LCYYV048711@gitrepo.freebsd.org>

next in thread | raw e-mail | index | archive | help
The branch main has been updated by imp:

URL: https://cgit.FreeBSD.org/doc/commit/?id=906851601568d15595e6c181bae741805d4fb3d6

commit 906851601568d15595e6c181bae741805d4fb3d6
Author:     Warner Losh <imp@FreeBSD.org>
AuthorDate: 2021-04-05 21:10:43 +0000
Commit:     Warner Losh <imp@FreeBSD.org>
CommitDate: 2021-04-05 21:11:18 +0000

    x11: document the latest best advice about graphics
    
    Recommend PORTS_MODULES for drm and nvidia ports. Remove pkg suggestion because
    it doesn't work in too many cases. Provide example for make.conf.
    
    Comments from: adridg@, Juan Molina, rpokala@, greg at unrelenting technology, khng,
            and others on sparc64 and twitter
    Differential Revision:  https://reviews.freebsd.org/D29479
---
 .../content/en/books/handbook/x11/_index.adoc      | 33 +++++++++++++++++++++-
 1 file changed, 32 insertions(+), 1 deletion(-)

diff --git a/documentation/content/en/books/handbook/x11/_index.adoc b/documentation/content/en/books/handbook/x11/_index.adoc
index f420bc9e54..b481c18773 100644
--- a/documentation/content/en/books/handbook/x11/_index.adoc
+++ b/documentation/content/en/books/handbook/x11/_index.adoc
@@ -205,7 +205,28 @@ The traditional single [.filename]#xorg.conf# still works, but is neither as cle
 [[x-config-video-cards]]
 === Video Cards
 
-Because of changes made in recent versions of FreeBSD, it is now possible to use graphics drivers provided by the Ports framework or as packages. As such, users can use one of the following drivers available from package:graphics/drm-kmod[].
+The Ports framework provides the drm graphics drivers necessary for X11 operation on recent hardware.
+Users can use one of the following drivers available from package:graphics/drm-kmod[].
+These drivers use interfaces in the kernel that are normally private.
+As such, it is strongly recommended that the drivers be built via the ports system via the `PORTS_MODULES` variable.
+With `PORTS_MODULES`, every time you build the kernel, the corresponding port(s) containing kernel modules are re-built against the updated sources.
+This ensures the kernel module stays in-sync with the kernel itself.
+The kernel and ports trees should be updated together for maximum compatibility.
+You can add `PORTS_MODULES` to your [.filename]#/etc/make.conf# file to ensure all kernels you build rebuild this module.
+Advanced users can add it to their kernel config files with the `makeoptions` directive.
+If you run GENERIC and use freebsd-update, you can just build the [.filename]#graphics/drm-kmod# or [.filename]#x11/nvidia-driver# port after each `freebsd-update install` invocation.
+
+[example]
+====
+[.filename]#/etc/make.conf#
+
+[.programlisting]
+....
+SYSDIR=path/to/src/sys
+PORTS_MODULES=graphics/drm-kmod x11/nvidia-driver
+....
+This will rebuild everything, but can select one or the other depending on which GPU / graphics card you have.
+====
 
 [[x-config-video-cards-ports]]
 Intel KMS driver, Radeon KMS driver, AMD KMS driver::
@@ -244,6 +265,16 @@ NVIDIA::
 Several NVIDIA drivers are available in the [.filename]#x11# category of the Ports Collection. Install the driver that matches the video card.
 +
 For reference, see https://en.wikipedia.org/wiki/List_of_Nvidia_graphics_processing_units[].
++
+Kernel support for NVIDIA cards is found in either the [.filename]#x11/nvidia-driver# port or the [.filename]#x11/nvidia-driver-xxx# port.
+Modern cards use the former.
+Legacy cards use the -xxx ports, where xxx is one of 304, 340 or 390 indicating the version of the driver.
+For those, fill in the `-xxx` using the http://download.nvidia.com/XFree86/FreeBSD-x86_64/465.19.01/README/[ Supported NvIDIA GPU Products ] page.
+This page lists the devices supported by different versions of the driver.
+Legacy drivers run on both i386 and amd64.
+The current driver only supports amd64.
+Read http://download.nvidia.com/XFree86/FreeBSD-x86_64/465.19.01/README/[installation and configuration of NVIDIA driver] for details.
+While we recommend this driver be rebuilt with each kernel rebuild for maximum safety, it uses almost no private kernel interfaces and is usually safe across kernel updates.
 
 [[x-config-video-cards-hybrid]]
 Hybrid Combination Graphics::



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?202104052112.135LCYYV048711>