git: 5d2db30fd29d - main - graphics/gpu-firmware-gpu-intel: Add new port

From: Emmanuel Vadot <manu_at_FreeBSD.org>
Date: Sun, 01 May 2022 17:24:28 UTC
The branch main has been updated by manu:

URL: https://cgit.FreeBSD.org/ports/commit/?id=5d2db30fd29d65c6c4914408c0cfa3d556ae772f

commit 5d2db30fd29d65c6c4914408c0cfa3d556ae772f
Author:     Emmanuel Vadot <manu@FreeBSD.org>
AuthorDate: 2021-10-14 13:09:18 +0000
Commit:     Emmanuel Vadot <manu@FreeBSD.org>
CommitDate: 2022-05-01 17:23:26 +0000

    graphics/gpu-firmware-gpu-intel: Add new port
    
    This is a port with the firmware for all and only Intel GPUs.
    Each generation is a flavor so one can just install the needed
    firmware.
    
    Sponsored by:   Beckhoff Automation GmbH & Co. KG
---
 graphics/Makefile                          |  1 +
 graphics/gpu-firmware-intel-kmod/Makefile  | 44 ++++++++++++++++++++++++++++++
 graphics/gpu-firmware-intel-kmod/distinfo  |  3 ++
 graphics/gpu-firmware-intel-kmod/pkg-descr |  5 ++++
 graphics/gpu-firmware-intel-kmod/pkg-plist | 34 +++++++++++++++++++++++
 5 files changed, 87 insertions(+)

diff --git a/graphics/Makefile b/graphics/Makefile
index c696b3170dfa..63f7a5837ef5 100644
--- a/graphics/Makefile
+++ b/graphics/Makefile
@@ -296,6 +296,7 @@
     SUBDIR += gpicview
     SUBDIR += gpsmanshp
     SUBDIR += gpu-firmware-kmod
+    SUBDIR += gpu-firmware-intel-kmod
     SUBDIR += gpxsee
     SUBDIR += gracula
     SUBDIR += grads
diff --git a/graphics/gpu-firmware-intel-kmod/Makefile b/graphics/gpu-firmware-intel-kmod/Makefile
new file mode 100644
index 000000000000..49758b7d1016
--- /dev/null
+++ b/graphics/gpu-firmware-intel-kmod/Makefile
@@ -0,0 +1,44 @@
+# Created by: Emmanuel Vadot <manu@FreeBSD.org>
+
+PORTNAME=	gpu-firmware-intel-kmod
+PORTVERSION=	20211014
+CATEGORIES=	graphics
+
+MAINTAINER=	x11@FreeBSD.org
+COMMENT=	Firmware modules for ${FLAVOR} Intel GPUs
+
+LICENSE=	INTEL
+LICENSE_NAME=	Intel firmware license (i915)
+LICENSE_FILE=	${WRKSRC}/LICENSE.i915
+LICENSE_PERMS=	dist-mirror no-dist-sell pkg-mirror no-pkg-sell auto-accept
+
+ONLY_FOR_ARCHS=		amd64 i386
+ONLY_FOR_ARCHS_REASON=	Intel GPUs are only available on x86
+
+PKGNAMESUFFIX=	-${FLAVOR:C/_/-/g}
+FLAVORS=	skylake \
+		broxton \
+		kabylake \
+		geminilake \
+		coffeelake \
+		icelake \
+		elkhartlake \
+		tigerlake
+FLAVOR?=	skylake
+
+USES=		kmod uidfix
+
+USE_GITHUB=	yes
+GH_ACCOUNT=	freebsd
+GH_PROJECT=	drm-kmod-firmware
+GH_TAGNAME=	20211014_1
+
+MAKE_ENV=	KMODS="i915kmsfw"
+MAKE_ENV+=	I915KMODS="${FLAVOR}"
+
+.include <bsd.port.pre.mk>
+
+PLIST_SUB+=	${FLAVORS:N${FLAVOR}:@v@${v:tu}="\@comment "@}
+PLIST_SUB+=	${FLAVOR:tu}=""
+
+.include <bsd.port.post.mk>
diff --git a/graphics/gpu-firmware-intel-kmod/distinfo b/graphics/gpu-firmware-intel-kmod/distinfo
new file mode 100644
index 000000000000..ca5604496e14
--- /dev/null
+++ b/graphics/gpu-firmware-intel-kmod/distinfo
@@ -0,0 +1,3 @@
+TIMESTAMP = 1634226398
+SHA256 (freebsd-drm-kmod-firmware-20211014-20211014_1_GH0.tar.gz) = cf39652b616579f6461d56af21d6827f666a75c5e3193a8fb69747bb49d4cdad
+SIZE (freebsd-drm-kmod-firmware-20211014-20211014_1_GH0.tar.gz) = 19953773
diff --git a/graphics/gpu-firmware-intel-kmod/pkg-descr b/graphics/gpu-firmware-intel-kmod/pkg-descr
new file mode 100644
index 000000000000..26af2d0e0b0c
--- /dev/null
+++ b/graphics/gpu-firmware-intel-kmod/pkg-descr
@@ -0,0 +1,5 @@
+Firmware modules for the drm-kmod drivers.
+
+Firmware files for Intel GPUs supported by the i915kms driver.
+
+WWW: https://github.com/freebsd/drm-kmod-firmware
diff --git a/graphics/gpu-firmware-intel-kmod/pkg-plist b/graphics/gpu-firmware-intel-kmod/pkg-plist
new file mode 100644
index 000000000000..619855e699dd
--- /dev/null
+++ b/graphics/gpu-firmware-intel-kmod/pkg-plist
@@ -0,0 +1,34 @@
+%%SKYLAKE%%/%%KMODDIR%%/i915_skl_dmc_ver1_27_bin.ko
+%%SKYLAKE%%/%%KMODDIR%%/i915_skl_guc_33_0_0_bin.ko
+%%SKYLAKE%%/%%KMODDIR%%/i915_skl_guc_ver9_33_bin.ko
+%%SKYLAKE%%/%%KMODDIR%%/i915_skl_huc_2_0_0_bin.ko
+%%SKYLAKE%%/%%KMODDIR%%/i915_skl_huc_ver01_07_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_dmc_ver1_07_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_guc_33_0_0_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_guc_ver9_29_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_huc_2_0_0_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_huc_ver01_07_bin.ko
+%%BROXTON%%/%%KMODDIR%%/i915_bxt_huc_ver01_8_bin.ko
+%%KABYLAKE%%/%%KMODDIR%%/i915_kbl_dmc_ver1_04_bin.ko
+%%KABYLAKE%%/%%KMODDIR%%/i915_kbl_guc_33_0_0_bin.ko
+%%KABYLAKE%%/%%KMODDIR%%/i915_kbl_guc_ver9_39_bin.ko
+%%KABYLAKE%%/%%KMODDIR%%/i915_kbl_huc_4_0_0_bin.ko
+%%KABYLAKE%%/%%KMODDIR%%/i915_kbl_huc_ver02_00_bin.ko
+%%GEMINILAKE%%/%%KMODDIR%%/i915_glk_dmc_ver1_04_bin.ko
+%%GEMINILAKE%%/%%KMODDIR%%/i915_glk_guc_33_0_0_bin.ko
+%%GEMINILAKE%%/%%KMODDIR%%/i915_glk_huc_4_0_0_bin.ko
+%%GEMINILAKE%%/%%KMODDIR%%/i915_glk_huc_ver03_01_bin.ko
+%%COFFEELAKE%%/%%KMODDIR%%/i915_cnl_dmc_ver1_06_bin.ko
+%%COFFEELAKE%%/%%KMODDIR%%/i915_cnl_dmc_ver1_07_bin.ko
+%%COFFEELAKE%%/%%KMODDIR%%/i915_cml_guc_33_0_0_bin.ko
+%%COFFEELAKE%%/%%KMODDIR%%/i915_cml_huc_4_0_0_bin.ko
+%%ICELAKE%%/%%KMODDIR%%/i915_icl_dmc_ver1_07_bin.ko
+%%ICELAKE%%/%%KMODDIR%%/i915_icl_dmc_ver1_09_bin.ko
+%%ICELAKE%%/%%KMODDIR%%/i915_icl_guc_33_0_0_bin.ko
+%%ICELAKE%%/%%KMODDIR%%/i915_icl_huc_9_0_0_bin.ko
+%%ICELAKE%%/%%KMODDIR%%/i915_icl_huc_ver8_4_bin.ko
+%%ELKHARTLAKE%%/%%KMODDIR%%/i915_ehl_guc_33_0_4_bin.ko
+%%ELKHARTLAKE%%/%%KMODDIR%%/i915_ehl_huc_9_0_0_bin.ko
+%%TIGERLAKE%%/%%KMODDIR%%/i915_tgl_dmc_ver2_04_bin.ko
+%%TIGERLAKE%%/%%KMODDIR%%/i915_tgl_guc_35_2_0_bin.ko
+%%TIGERLAKE%%/%%KMODDIR%%/i915_tgl_huc_7_0_3_bin.ko