aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlexey Dokuchaev <danfe@FreeBSD.org>2023-03-01 10:19:30 +0000
committerAlexey Dokuchaev <danfe@FreeBSD.org>2023-03-01 10:19:30 +0000
commita09185f8b66c462d3bc1d1d7526d667770319aaf (patch)
tree99fe62da7257e0a3a0cfa0140c3d8d18883b71a0
parent470aaa77c1eb987c1c2e93ddc89f09eda0a31f88 (diff)
downloadports-a09185f8.tar.gz
ports-a09185f8.zip
x11/nvidia-driver: reword the pkg-message to reflect modern reality
Try to reduce readers' confusion by specifying exactly which nVidia kernel module users should be loading these days. PR: 269626
-rw-r--r--x11/nvidia-driver/Makefile11
-rw-r--r--x11/nvidia-driver/files/pkg-message.in20
2 files changed, 12 insertions, 19 deletions
diff --git a/x11/nvidia-driver/Makefile b/x11/nvidia-driver/Makefile
index 44ad13ae53a3..f236e95abf80 100644
--- a/x11/nvidia-driver/Makefile
+++ b/x11/nvidia-driver/Makefile
@@ -1,12 +1,11 @@
-#
# For those wondering why this port is not under `x11-drivers' category,
# have a look at https://bugs.freebsd.org/bugzilla/show_bug.cgi?id=121930.
#
# Starting with version 1.0-7667, NVidia has dropped support for numerous
# "legacy" GPUs. Consult NVidia README (the Appendix) to find out whether
# you need to use legacy driver version and install one of corresponding
-# slave ports instead (`x11/nvidia-driver-390', `x11/nvidia-driver-340',
-# or `x11/nvidia-driver-304').
+# slave ports instead (`x11/nvidia-driver-470', `x11/nvidia-driver-390',
+# `x11/nvidia-driver-340', or `x11/nvidia-driver-304').
#
# To simplify testing of new feature branches and beta driver versions,
# the port aims to support building against arbitrary DISTVERSION, i.e.
@@ -88,6 +87,12 @@ NVSRC= .
NVSRC= nvidia
.endif
+.if ${NVVERSION} < 358.009
+SUB_LIST+= KLDNAME=nvidia
+.else
+SUB_LIST+= KLDNAME=nvidia-modeset
+.endif
+
.if ${NVVERSION} < 460.039
. if ${NVVERSION} >= 358.009
EXTRA_PATCHES+= ${FILESDIR}/extra-patch-src_nvidia-modeset_nvidia-modeset-freebsd.c
diff --git a/x11/nvidia-driver/files/pkg-message.in b/x11/nvidia-driver/files/pkg-message.in
index 7041d306e72c..7987b59d3463 100644
--- a/x11/nvidia-driver/files/pkg-message.in
+++ b/x11/nvidia-driver/files/pkg-message.in
@@ -4,13 +4,12 @@
To use these drivers, make sure that you have loaded the NVidia kernel
module, by running
- # kldload nvidia (or nvidia-modeset, see below)
+ # kldload %%KLDNAME%%
-on the command line, or by putting ``nvidia'' (or ``nvidia-modeset'',
-see below again) on ``kld_list'' variable in /etc/rc.conf, either manually
-or by running
+on the command line, or by putting ``%%KLDNAME%%'' on the ``kld_list''
+variable in /etc/rc.conf, either manually or by running
- # sysrc kld_list+=nvidia (or nvidia-modeset, see below)
+ # sysrc kld_list+=%%KLDNAME%%
If you build this port with FreeBSD AGP GART driver, make sure you have
agp.ko kernel module installed and loaded, since nvidia.ko will depend
@@ -33,17 +32,6 @@ If X.org cannot start and reports
in /var/log/Xorg.0.log while actually you have ``options SYSVSHM''
enabled in kernel, the sysctl ``kern.ipc.shmall'' should be increased.
-Starting with version 358.09, some important functionality of the driver
-has been broken out into a separate kernel module, nvidia-modeset.ko.
-Users that experience hangs when starting X11 server, or observe
-
- (II) NVIDIA(0): Validated MetaModes:
- (II) NVIDIA(0): "NULL"
-
-in /var/log/Xorg.0.log should replace ``nvidia'' with ``nvidia-modeset''
-in their /boot/loader.conf or /etc/rc.conf configuration files, depending
-on how they prefer to load NVidia driver kernel module.
-
See %%DOCSDIR%%/README for more information.
EOM
}