summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRandolph Sapp <rs@ti.com>2024-05-02 14:18:41 -0500
committerRyan Eatmon <reatmon@ti.com>2024-05-02 15:02:04 -0500
commitd89907ec2322f23271917d75f052217dd8a2c27a (patch)
treeb7b38987751de3cf68aa706e49bb90bc8f24d96a
parentdd114ef1c5bd6f7b5ee827c32ef6b90d6252b894 (diff)
downloadmeta-ti-d89907ec2322f23271917d75f052217dd8a2c27a.tar.gz
ti-img-rogue-*: add ddk 24.1 recipes for ltsprep
Recipes for DDK 24.1, but lock them behind ltsprep tags because they require device tree changes that do not work on the current default kernel for this layer. Signed-off-by: Randolph Sapp <rs@ti.com> Signed-off-by: Ryan Eatmon <reatmon@ti.com>
-rw-r--r--meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver_24.1.6554834.bb44
-rw-r--r--meta-ti-bsp/recipes-graphics/powervr-umlibs/ti-img-rogue-umlibs_24.1.6554834.bb148
2 files changed, 192 insertions, 0 deletions
diff --git a/meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver_24.1.6554834.bb b/meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver_24.1.6554834.bb
new file mode 100644
index 00000000..a1b76d27
--- /dev/null
+++ b/meta-ti-bsp/recipes-bsp/powervr-drivers/ti-img-rogue-driver_24.1.6554834.bb
@@ -0,0 +1,44 @@
1DESCRIPTION = "Kernel drivers for the PowerVR Rogue GPU found in the TI SoCs"
2HOMEPAGE = "http://git.ti.com/graphics/ti-img-rogue-driver"
3LICENSE = "MIT | GPL-2.0-only"
4LIC_FILES_CHKSUM = "file://README;beginline=14;endline=19;md5=0403c7dea01a2b8232261e805325fac2"
5
6DEFAULT_PREFERENCE = "-1"
7
8inherit module
9
10PROVIDES = "virtual/gpudriver"
11
12MACHINE_KERNEL_PR:append = "b"
13PR = "${MACHINE_KERNEL_PR}"
14
15PACKAGE_ARCH = "${MACHINE_ARCH}"
16
17COMPATIBLE_MACHINE = "j721e|j721s2|j784s4|am62xx|am62pxx|j722s"
18
19DEPENDS = "virtual/kernel"
20
21BRANCH = "linuxws/scarthgap/k6.6/${PV}"
22
23SRC_URI = "git://git.ti.com/git/graphics/ti-img-rogue-driver.git;protocol=https;branch=${BRANCH}"
24
25S = "${WORKDIR}/git"
26
27SRCREV = "e2dfdfee991dadc18175f27fe9e8676e910a2f8d"
28
29TARGET_PRODUCT:j721e = "j721e_linux"
30TARGET_PRODUCT:j721s2 = "j721s2_linux"
31TARGET_PRODUCT:j784s4 = "j784s4_linux"
32TARGET_PRODUCT:am62xx = "am62_linux"
33TARGET_PRODUCT:am62pxx = "am62p_linux"
34TARGET_PRODUCT:j722s = "j722s_linux"
35PVR_BUILD = "release"
36PVR_WS = "lws-generic"
37
38EXTRA_OEMAKE += 'KERNELDIR="${STAGING_KERNEL_DIR}" BUILD=${PVR_BUILD} PVR_BUILD_DIR=${TARGET_PRODUCT} WINDOW_SYSTEM=${PVR_WS}'
39
40do_install() {
41 make -C ${STAGING_KERNEL_DIR} M=${B}/binary_${TARGET_PRODUCT}_${PVR_WS}_${PVR_BUILD}/target_aarch64/kbuild INSTALL_MOD_PATH=${D}${root_prefix} PREFIX=${STAGING_DIR_HOST} modules_install
42}
43
44RRECOMMENDS:${PN} += "ti-img-rogue-umlibs"
diff --git a/meta-ti-bsp/recipes-graphics/powervr-umlibs/ti-img-rogue-umlibs_24.1.6554834.bb b/meta-ti-bsp/recipes-graphics/powervr-umlibs/ti-img-rogue-umlibs_24.1.6554834.bb
new file mode 100644
index 00000000..d43d1635
--- /dev/null
+++ b/meta-ti-bsp/recipes-graphics/powervr-umlibs/ti-img-rogue-umlibs_24.1.6554834.bb
@@ -0,0 +1,148 @@
1DESCRIPTION = "Userspace libraries for PowerVR Rogue GPU on TI SoCs"
2HOMEPAGE = "http://git.ti.com/graphics/ti-img-rogue-umlibs"
3LICENSE = "TI-TFL"
4LIC_FILES_CHKSUM = "file://${WORKDIR}/git/LICENSE;md5=7232b98c1c58f99e3baa03de5207e76f"
5
6DEFAULT_PREFERENCE = "-1"
7
8inherit bin_package
9
10INHIBIT_DEFAULT_DEPS = ""
11
12PACKAGE_ARCH = "${MACHINE_ARCH}"
13COMPATIBLE_MACHINE = "j721e|j721s2|j784s4|am62xx|am62pxx|j722s"
14
15PR = "r3"
16
17BRANCH = "linuxws/scarthgap/k6.6/${PV}"
18SRC_URI = "git://git.ti.com/git/graphics/ti-img-rogue-umlibs.git;protocol=https;branch=${BRANCH}"
19SRCREV = "e473234158c736248cf71a60080b7faf76fca561"
20S = "${WORKDIR}/git/targetfs/${TARGET_PRODUCT}/${PVR_WS}/${PVR_BUILD}"
21
22TARGET_PRODUCT:j721e = "j721e_linux"
23TARGET_PRODUCT:j721s2 = "j721s2_linux"
24TARGET_PRODUCT:j784s4 = "j784s4_linux"
25TARGET_PRODUCT:am62xx = "am62_linux"
26TARGET_PRODUCT:am62pxx = "am62p_linux"
27TARGET_PRODUCT:j722s = "j722s_linux"
28PVR_BUILD = "release"
29PVR_WS = "lws-generic"
30
31RDEPENDS:${PN} = " \
32 libdrm \
33 ti-img-rogue-driver \
34 ${PN}-firmware \
35"
36
37PACKAGECONFIG ?= " \
38 ${@bb.utils.contains('DISTRO_FEATURES', 'vulkan wayland', 'vulkan', '', d)} \
39 ${@bb.utils.filter('DISTRO_FEATURES', 'opengl opencl', d)} \
40"
41
42PACKAGECONFIG[opengl] = ",,,,${GLES_PACKAGES}"
43PACKAGECONFIG[vulkan] = ",,,,${VULKAN_PACKAGES}"
44PACKAGECONFIG[opencl] = ",,,,${OPENCL_PACKAGES}"
45
46def get_file_list(package_list_var, d):
47 file_list = []
48 package_list = d.getVar(package_list_var)
49 prefix = f"{d.getVar('S')}/"
50 if package_list:
51 for package in package_list.split():
52 package_file_string = d.getVar(f"FILES:{package}")
53 if package_file_string:
54 for package_file in package_file_string.split():
55 file_list.append(f"{prefix}{package_file}")
56 return " ".join(file_list)
57
58do_install:prepend() {
59 if ${@bb.utils.contains('PACKAGECONFIG', 'opengl', 'false', 'true', d)}; then
60 for file in ${@get_file_list('GLES_PACKAGES', d)}; do
61 rm -rf ${file}
62 done
63 fi
64 if ${@bb.utils.contains('PACKAGECONFIG', 'vulkan', 'false', 'true', d)}; then
65 for file in ${@get_file_list('VULKAN_PACKAGES', d)}; do
66 rm -rf ${file}
67 done
68 fi
69 if ${@bb.utils.contains('PACKAGECONFIG', 'opencl', 'false', 'true', d)}; then
70 for file in ${@get_file_list('OPENCL_PACKAGES', d)}; do
71 rm -rf ${file}
72 done
73 fi
74 if ${@bb.utils.contains('DISTRO_FEATURES', 'usrmerge', 'true', 'false', d)}; then
75 if [ -e ${S}/lib/firmware ]; then
76 mv ${S}/lib/firmware ${S}${nonarch_base_libdir}
77 fi
78 fi
79
80 # clean up any empty directories
81 find "${S}" -empty -type d -delete
82}
83
84GLES_PACKAGES = "libgles1-rogue libgles2-rogue libgles3-rogue"
85VULKAN_PACKAGES = "libvk-rogue"
86OPENCL_PACKAGES = "libopencl-rogue libopencl-rogue-tools"
87
88PACKAGES = " \
89 ${@bb.utils.contains('PACKAGECONFIG', 'opengl', d.getVar('GLES_PACKAGES'), '', d)} \
90 ${@bb.utils.contains('PACKAGECONFIG', 'vulkan', d.getVar('VULKAN_PACKAGES'), '', d)} \
91 ${@bb.utils.contains('PACKAGECONFIG', 'opencl', d.getVar('OPENCL_PACKAGES'), '', d)} \
92 ${PN}-tools \
93 ${PN}-firmware \
94 ${PN} \
95"
96
97# Inject variables so that packages don't get Debian-renamed (which would
98# remove the -rogue suffix), but don't RPROVIDEs/RCONFLICTs on the generic
99# libgl name to prevent colliding with swrast libs
100python __anonymous() {
101 suffix = ""
102 if "-native" in d.getVar("PN"):
103 suffix = "-native"
104 for p in (("vulkan", "libvk",),
105 ("gles", "libgles1", "libglesv1-cm1"),
106 ("gles", "libgles2", "libglesv2-2"),
107 ("gles", "libgles3",),
108 ("opencl", "libopencl",)):
109 mlprefix = d.getVar("MLPREFIX")
110 fullp = mlprefix + p[1] + "-rogue" + suffix
111 mlprefix = d.getVar("MLPREFIX")
112 pkgs = " " + " ".join(mlprefix + x + suffix for x in p[1:])
113 d.setVar("DEBIAN_NOAUTONAME:" + fullp, "1")
114 d.setVar("INSANE_SKIP:" + fullp, "dev-so ldflags")
115 d.appendVar("RRECOMMENDS:" + fullp, " ${MLPREFIX}ti-img-rogue-umlibs" + suffix)
116}
117
118# gles specific shared objects
119FILES:libgles1-rogue = "${libdir}/libGLESv1*.so*"
120FILES:libgles2-rogue = "${libdir}/libGLESv2*.so*"
121RDEPENDS:libgles1-rogue += "mesa-megadriver"
122RDEPENDS:libgles2-rogue += "mesa-megadriver"
123
124# vulkan specific shared objects and configs
125FILES:libvk-rogue = "${libdir}/libVK_IMG.so* ${datadir}/vulkan"
126RDEPENDS:libvk-rogue += "vulkan-loader wayland libdrm"
127
128# opencl specific shared objects and configs
129FILES:libopencl-rogue = "${libdir}/libPVROCL.so* ${sysconfdir}/OpenCL"
130RDEPENDS:libopencl-rogue += "opencl-icd-loader"
131RRECOMMENDS:libopencl-rogue += "libopencl-rogue-tools"
132FILES:libopencl-rogue-tools += "${bindir}/ocl*"
133DEBIAN_NOAUTONAME:libopencl-rogue-tools = "1"
134
135# optional tools and tests
136FILES:${PN}-tools = "${bindir}/"
137RDEPENDS:${PN}-tools = "python3-core libdrm ${PN}"
138INSANE_SKIP:${PN}-tools = "ldflags"
139
140# required firmware
141FILES:${PN}-firmware = "${base_libdir}/firmware/*"
142INSANE_SKIP:${PN}-firmware += "arch"
143
144RRECOMMENDS:${PN} += " \
145 ${PN}-tools \
146"
147
148INSANE_SKIP:${PN} += "already-stripped dev-so ldflags"