From a2f9d421786cef0fd0b377c81259dee9c78f4b4a Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 10:47:50 -0500 Subject: [PATCH 01/13] wayland-protocols: Upgrade 1.37.imx -> 1.41.imx Signed-off-by: Tom Hochstein --- conf/machine/include/imx-base.inc | 2 +- ...ols_1.37.imx.bb => wayland-protocols_1.41.imx.bb} | 12 ++++++------ 2 files changed, 7 insertions(+), 7 deletions(-) rename recipes-graphics/wayland/{wayland-protocols_1.37.imx.bb => wayland-protocols_1.41.imx.bb} (79%) diff --git a/conf/machine/include/imx-base.inc b/conf/machine/include/imx-base.inc index 5966da36..6d1671a7 100644 --- a/conf/machine/include/imx-base.inc +++ b/conf/machine/include/imx-base.inc @@ -582,7 +582,7 @@ PREFERRED_VERSION_weston:mx6-nxp-bsp ??= "10.0.5.imx" PREFERRED_VERSION_weston:mx7-nxp-bsp ??= "10.0.5.imx" PREFERRED_VERSION_weston:imx-mainline-bsp = "" -PREFERRED_VERSION_wayland-protocols:imx-nxp-bsp ??= "1.37.imx" +PREFERRED_VERSION_wayland-protocols:imx-nxp-bsp ??= "1.41.imx" PREFERRED_VERSION_xwayland:imx-nxp-bsp ??= "24.1.6.imx" diff --git a/recipes-graphics/wayland/wayland-protocols_1.37.imx.bb b/recipes-graphics/wayland/wayland-protocols_1.41.imx.bb similarity index 79% rename from recipes-graphics/wayland/wayland-protocols_1.37.imx.bb rename to recipes-graphics/wayland/wayland-protocols_1.41.imx.bb index f360706b..3350a479 100644 --- a/recipes-graphics/wayland/wayland-protocols_1.37.imx.bb +++ b/recipes-graphics/wayland/wayland-protocols_1.41.imx.bb @@ -11,10 +11,13 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=c7b12b6702da38ca028ace54aae3d484 \ SRC_URI = "${WAYLAND_PROTOCOLS_SRC};branch=${SRCBRANCH}" WAYLAND_PROTOCOLS_SRC ?= "git://github.com/nxp-imx/wayland-protocols-imx.git;protocol=https" -SRCBRANCH = "wayland-protocols-imx-${@oe.utils.trim_version("${PV}", 2)}" -SRCREV = "831a5389062e56dcb1aac4a5419e55e3002aafaf" +SRCBRANCH = "wayland-protocols-imx-1.41" +SRCREV = "7213a4e09837c77112bce2d241491600e00dd095" -UPSTREAM_CHECK_URI = "https://wayland.freedesktop.org/releases.html" +UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/wayland-protocols/-/tags" +UPSTREAM_CHECK_REGEX = "releases/(?P.+)" + +DEPENDS += "wayland-native" # NOTE: For i.MX drop allarch since the recipe is SOCARCH #inherit meson pkgconfig allarch @@ -22,9 +25,6 @@ inherit meson pkgconfig EXTRA_OEMESON += "-Dtests=false" -PACKAGES = "${PN}" -FILES:${PN} += "${datadir}/pkgconfig/wayland-protocols.pc" - BBCLASSEXTEND = "native nativesdk" PACKAGE_ARCH = "${MACHINE_SOCARCH}" From 3c9bea25be2869f1a07d79db35e6cb7095ff0257 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 10:54:43 -0500 Subject: [PATCH 02/13] imx-gpu-viv,imx-gpu-g2d: Upgrade 6.4.11.p3.0 -> 6.4.11.p3.2 Signed-off-by: Tom Hochstein --- ...u-g2d_6.4.11.p3.0.bb => imx-gpu-g2d_6.4.11.p3.2.bb} | 10 +++++----- recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc | 1 - .../imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch32.bb | 9 --------- .../imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch64.bb | 9 --------- .../imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch32.bb | 9 +++++++++ .../imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch64.bb | 9 +++++++++ .../kernel-module-imx-gpu-viv_6.4.11.p3.2.bb | 6 +++--- 7 files changed, 26 insertions(+), 27 deletions(-) rename recipes-graphics/imx-g2d/{imx-gpu-g2d_6.4.11.p3.0.bb => imx-gpu-g2d_6.4.11.p3.2.bb} (78%) delete mode 100644 recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch32.bb delete mode 100644 recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch64.bb create mode 100644 recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch32.bb create mode 100644 recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch64.bb diff --git a/recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.0.bb b/recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.2.bb similarity index 78% rename from recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.0.bb rename to recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.2.bb index 3c8784d0..d1f23d91 100644 --- a/recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.0.bb +++ b/recipes-graphics/imx-g2d/imx-gpu-g2d_6.4.11.p3.2.bb @@ -1,19 +1,19 @@ # Copyright (C) 2016 Freescale Semiconductor -# Copyright 2017-2024 NXP +# Copyright 2017-2022 NXP # Copyright 2018 (C) O.S. Systems Software LTDA. # Released under the MIT license (see COPYING.MIT for the terms) DESCRIPTION = "G2D library using i.MX GPU" LICENSE = "Proprietary" -LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" +LIC_FILES_CHKSUM = "file://COPYING;md5=a93b654673e1bc8398ed1f30e0813359" DEPENDS = "libgal-imx" PROVIDES = "virtual/libg2d" SRC_URI = "${FSL_MIRROR}/${IMX_BIN_NAME}.bin;name=${TARGET_ARCH};fsl-eula=true" IMX_BIN_NAME = "${BP}-${TARGET_ARCH}-${IMX_SRCREV_ABBREV}" -IMX_SRCREV_ABBREV = "c600d03" -SRC_URI[aarch64.sha256sum] = "e6c336c0b876efab7598a2d7817111772284487f646d5d83c400692f2cdfebe3" -SRC_URI[arm.sha256sum] = "6e1a42f2c570582b8038d1b5c86dbdcd645e75cc10a1db23e716f662d1c1329f" +IMX_SRCREV_ABBREV = "3c5e429" +SRC_URI[aarch64.sha256sum] = "190bc9203e60e5de508e1dcf057b36d2c9bc3667c6972fd12f7df797e508a22d" +SRC_URI[arm.sha256sum] = "aaf9a38fe446af579b16a836bf297f8cb1b2842ca3a784bedc21e32d37271ab4" S = "${UNPACKDIR}/${IMX_BIN_NAME}" diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc index 88081cc6..ebb75985 100644 --- a/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc +++ b/recipes-graphics/imx-gpu-viv/imx-gpu-viv-6.inc @@ -330,7 +330,6 @@ FILES:libegl-imx-dev = "${includedir}/EGL ${includedir}/KHR ${libdir}/pkgconfig/ INSANE_SKIP:libegl-imx += "dev-so" FILES:libgal-imx = "${libdir}/libGAL${SOLIBS} ${libdir}/libGAL_egl${SOLIBS}" -FILES:libgal-imx-dev:remove = "${includedir}/HAL" RDEPENDS:libgal-imx += "${@bb.utils.contains('PACKAGECONFIG', 'valgrind', 'valgrind', '', d)}" RPROVIDES:libgal-imx += "libgal-imx" RRECOMMENDS:libgal-imx += "kernel-module-imx-gpu-viv" diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch32.bb b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch32.bb deleted file mode 100644 index 9fbb7e92..00000000 --- a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch32.bb +++ /dev/null @@ -1,9 +0,0 @@ -require imx-gpu-viv-6.inc - -LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" - -IMX_SRCREV_ABBREV = "c600d03" - -SRC_URI[sha256sum] = "fe8fc231f18047b9547a038e111c08e855760190d0e9848ead22b383d793499d" - -COMPATIBLE_MACHINE = "(mx6q-nxp-bsp|mx6dl-nxp-bsp|mx6sx-nxp-bsp|mx6sl-nxp-bsp|mx7ulp-nxp-bsp)" diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch64.bb b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch64.bb deleted file mode 100644 index aeed17fe..00000000 --- a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.0-aarch64.bb +++ /dev/null @@ -1,9 +0,0 @@ -require imx-gpu-viv-6.inc - -LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" - -IMX_SRCREV_ABBREV = "c600d03" - -SRC_URI[sha256sum] = "82e1bb6304d2aac70c72b691239d1bb5f6738cadfa812d07196db2f580c63d29" - -COMPATIBLE_MACHINE = "(mx8-nxp-bsp)" diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch32.bb b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch32.bb new file mode 100644 index 00000000..f0e7d285 --- /dev/null +++ b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch32.bb @@ -0,0 +1,9 @@ +require imx-gpu-viv-6.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=a93b654673e1bc8398ed1f30e0813359" + +IMX_SRCREV_ABBREV = "3c5e429" + +SRC_URI[sha256sum] = "ea7ffb01fd7cd88f2a308e5b12b40cc3c9553b8ff2941c4867943b4fee265d27" + +COMPATIBLE_MACHINE = "(mx6q-nxp-bsp|mx6dl-nxp-bsp|mx6sx-nxp-bsp|mx6sl-nxp-bsp|mx7ulp-nxp-bsp)" diff --git a/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch64.bb b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch64.bb new file mode 100644 index 00000000..38870add --- /dev/null +++ b/recipes-graphics/imx-gpu-viv/imx-gpu-viv_6.4.11.p3.2-aarch64.bb @@ -0,0 +1,9 @@ +require imx-gpu-viv-6.inc + +LIC_FILES_CHKSUM = "file://COPYING;md5=a93b654673e1bc8398ed1f30e0813359" + +IMX_SRCREV_ABBREV = "3c5e429" + +SRC_URI[sha256sum] = "bf6fe102e8aa7a16373392efcf6ac45d705bbb95f5c39501da8aaa30957c554f" + +COMPATIBLE_MACHINE = "(mx8-nxp-bsp)" diff --git a/recipes-kernel/kernel-modules/kernel-module-imx-gpu-viv_6.4.11.p3.2.bb b/recipes-kernel/kernel-modules/kernel-module-imx-gpu-viv_6.4.11.p3.2.bb index 63086d59..8670443d 100644 --- a/recipes-kernel/kernel-modules/kernel-module-imx-gpu-viv_6.4.11.p3.2.bb +++ b/recipes-kernel/kernel-modules/kernel-module-imx-gpu-viv_6.4.11.p3.2.bb @@ -1,5 +1,5 @@ # Copyright (C) 2015-2016 Freescale Semiconductor -# Copyright (C) 2017-2024 NXP +# Copyright (C) 2017-2025 NXP SUMMARY = "Kernel loadable module for Vivante GPU" DESCRIPTION = "Builds the Vivante GPU kernel driver as a loadable kernel module, \ @@ -7,9 +7,9 @@ allowing flexibility to use a newer graphics release with an older kernel." LICENSE = "GPL-2.0-only" LIC_FILES_CHKSUM = "file://${COMMON_LICENSE_DIR}/GPL-2.0-only;md5=801f80980d171dd6425610833a22dbe6" -SRC_URI = "${KERNEL_SRC};subpath=drivers/mxc/gpu-viv;destsuffix=${S}/src \ +SRC_URI = "${LINUX_IMX_SRC};subpath=drivers/mxc/gpu-viv;destsuffix=${S}/src \ file://Add-makefile.patch" -KERNEL_SRC ?= "git://github.com/nxp-imx/linux-imx.git;protocol=https;branch=${SRCBRANCH}" +LINUX_IMX_SRC ?= "git://github.com/nxp-imx/linux-imx.git;protocol=https;branch=${SRCBRANCH}" SRCBRANCH = "lf-6.12.y" LOCALVERSION = "-6.12.20-2.0.0" SRCREV = "d53b3fa8a69bef5ead825e81aa62dbdd08e1409c" From 5ede9cee499b8e0171c75953aca5dacdd6a81fd6 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 11:10:03 -0500 Subject: [PATCH 03/13] imx-dpu-g2d: Upgrade 2.3.0 -> 2.4.0.0 Signed-off-by: Tom Hochstein --- .../{imx-dpu-g2d_2.3.0.bb => imx-dpu-g2d_2.4.0.0.bb} | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) rename recipes-graphics/imx-g2d/{imx-dpu-g2d_2.3.0.bb => imx-dpu-g2d_2.4.0.0.bb} (75%) diff --git a/recipes-graphics/imx-g2d/imx-dpu-g2d_2.3.0.bb b/recipes-graphics/imx-g2d/imx-dpu-g2d_2.4.0.0.bb similarity index 75% rename from recipes-graphics/imx-g2d/imx-dpu-g2d_2.3.0.bb rename to recipes-graphics/imx-g2d/imx-dpu-g2d_2.4.0.0.bb index bf0a127c..4e3444b9 100644 --- a/recipes-graphics/imx-g2d/imx-dpu-g2d_2.3.0.bb +++ b/recipes-graphics/imx-g2d/imx-dpu-g2d_2.4.0.0.bb @@ -1,10 +1,10 @@ # Copyright (C) 2016 Freescale Semiconductor -# Copyright 2017-2024 NXP +# Copyright 2017-2025 NXP # Released under the MIT license (see COPYING.MIT for the terms) DESCRIPTION = "G2D library using i.MX DPU" LICENSE = "Proprietary" -LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" +LIC_FILES_CHKSUM = "file://COPYING;md5=a93b654673e1bc8398ed1f30e0813359" DEPENDS = "libdrm ${LIBGAL_IMX}" LIBGAL_IMX = "" @@ -15,13 +15,13 @@ PROVIDES += "virtual/libg2d" SRC_URI = "${FSL_MIRROR}/${IMX_BIN_NAME}.bin;fsl-eula=true;name=${IMX_SRC_URI_NAME}" IMX_BIN_NAME = "${BPN}-${IMX_SRC_URI_NAME}-${PV}-${IMX_SRCREV_ABBREV}" -IMX_SRCREV_ABBREV = "8d2a88d" +IMX_SRCREV_ABBREV = "9e8bbf1" IMX_SRC_URI_NAME = "v1" -SRC_URI[v1.sha256sum] = "20325a7c6090b79e012339aed25fa4c3b760efcc32be339e389a36a15e44bdfc" +SRC_URI[v1.sha256sum] = "67be9b56a5d2196613460d3cc3a734d7a088e2177377e27f83287766d5d8cf70" -IMX_SRCREV_ABBREV:imxmali = "8d2a88d" +IMX_SRCREV_ABBREV:imxmali = "9e8bbf1" IMX_SRC_URI_NAME:imxmali = "v2" -SRC_URI[v2.sha256sum] = "eb7108256cb55d996c07f6941d0d4a76beaf73458494b2c902d907bc8228eeeb" +SRC_URI[v2.sha256sum] = "f56dae607f89e0f414625657d8345c5d1b68b79d3ac61e50016fbe4d49a91402" S = "${UNPACKDIR}/${IMX_BIN_NAME}" From 1e0800d96b03def617f1b36b21d6bda32706d216 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 11:12:09 -0500 Subject: [PATCH 04/13] imx-pxp-g2d: Upgrade 2.3 -> 2.4 Adds i.MX 943 support. Signed-off-by: Tom Hochstein --- recipes-graphics/imx-g2d/imx-pxp-g2d_git.bb | 16 +++++++++------- 1 file changed, 9 insertions(+), 7 deletions(-) diff --git a/recipes-graphics/imx-g2d/imx-pxp-g2d_git.bb b/recipes-graphics/imx-g2d/imx-pxp-g2d_git.bb index 9fd170ad..8165c0c6 100644 --- a/recipes-graphics/imx-g2d/imx-pxp-g2d_git.bb +++ b/recipes-graphics/imx-g2d/imx-pxp-g2d_git.bb @@ -1,27 +1,29 @@ # Copyright (C) 2016 Freescale Semiconductor -# Copyright 2017-2024 NXP +# Copyright 2017-2025 NXP # Released under the MIT license (see COPYING.MIT for the terms) DESCRIPTION = "G2D library using i.MX PXP" LICENSE = "Proprietary" -LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=c0fb372b5d7f12181de23ef480f225f3" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=a93b654673e1bc8398ed1f30e0813359" PROVIDES += "virtual/libg2d" -PV = "2.3+git${SRCPV}" +PV = "2.4+git" SRC_URI = "${IMX_PXP_G2D_SRC};branch=${SRCBRANCH}" IMX_PXP_G2D_SRC ?= "git://github.com/nxp-imx/imx-g2d-pxp.git;protocol=https" -SRCBRANCH = "imx_2.3" -SRCREV = "f3aabbcb7977a0a17c962c62b02bc829855f8edf" +SRCBRANCH = "imx_2.4" +SRCREV = "c3368ea82e4507d7b35aee258c28d04f9f8fb8e9" inherit use-imx-headers -EXTRA_OEMAKE = "PLATFORM=IMX93 INCLUDE='-I${STAGING_INCDIR_IMX}' DEST_DIR=${D}" +EXTRA_OEMAKE = "PLATFORM=${IMX_PLATFORM} INCLUDE='-I${STAGING_INCDIR_IMX}' DEST_DIR=${D}" +IMX_PLATFORM:mx93-nxp-bsp = "IMX93" +IMX_PLATFORM:mx943-nxp-bsp = "IMX943" do_install() { oe_runmake install } PACKAGE_ARCH = "${MACHINE_SOCARCH}" -COMPATIBLE_MACHINE = "(mx93-nxp-bsp)" +COMPATIBLE_MACHINE = "(mx93-nxp-bsp|mx943-nxp-bsp)" From f40950ac44bb5eeb35a75e28eea47569ca397fbd Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 11:23:36 -0500 Subject: [PATCH 05/13] imx-g2d-samples: Upgrade 2.3 -> 2.4 Adds i.MX 943 support. Signed-off-by: Tom Hochstein --- recipes-graphics/imx-g2d/imx-g2d-samples_git.bb | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/recipes-graphics/imx-g2d/imx-g2d-samples_git.bb b/recipes-graphics/imx-g2d/imx-g2d-samples_git.bb index 1f62398f..98e97610 100644 --- a/recipes-graphics/imx-g2d/imx-g2d-samples_git.bb +++ b/recipes-graphics/imx-g2d/imx-g2d-samples_git.bb @@ -5,11 +5,11 @@ LIC_FILES_CHKSUM = "file://LICENSE;md5=0858ec9c7a80c4a2cf16e4f825a2cc91" DEPENDS = "cairo" -PV = "2.3+git${SRCPV}" +PV = "2.4+git" SRC_URI = "${GPU_G2D_SAMPLES_SRC};branch=${SRCBRANCH}" GPU_G2D_SAMPLES_SRC ?= "git://github.com/nxp-imx/g2d-samples.git;protocol=https" -SRCBRANCH = "imx_2.3" +SRCBRANCH = "imx_2.4" SRCREV = "7d12c50c07d73650b4c97906ce917aff429238f8" inherit pkgconfig @@ -21,6 +21,7 @@ PACKAGECONFIG_IMPLEMENTATION:mx95-nxp-bsp = "dpu95" PACKAGECONFIG_IMPLEMENTATION:imxgpu2d = "gpu-drm" PACKAGECONFIG_IMPLEMENTATION:imxgpu2d:imxfbdev = "gpu-fbdev" PACKAGECONFIG_IMPLEMENTATION:mx93-nxp-bsp = "pxp" +PACKAGECONFIG_IMPLEMENTATION:mx943-nxp-bsp = "pxp" PACKAGECONFIG[dpu] = " \ BUILD_IMPLEMENTATION=dpu, \ @@ -71,4 +72,4 @@ FILES:${PN} += "/opt" PACKAGE_ARCH = "${MACHINE_SOCARCH}" -COMPATIBLE_MACHINE = "(imxgpu2d|mx93-nxp-bsp|mx95-nxp-bsp)" +COMPATIBLE_MACHINE = "(imxgpu2d|mx93-nxp-bsp|mx943-nxp-bsp|mx95-nxp-bsp)" From eb3740447589b8a198b31b2ac9255d72e401b4f2 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 11:46:17 -0500 Subject: [PATCH 06/13] mali-imx: Upgrade r53.0 -> r54.0 Note, this version no longer builds vulkan-wsi-layer itself. Signed-off-by: Tom Hochstein --- recipes-graphics/mali/mali-imx.inc | 1 + .../mali/{mali-imx_r53.0.bb => mali-imx_r54.0.bb} | 10 +++++----- 2 files changed, 6 insertions(+), 5 deletions(-) rename recipes-graphics/mali/{mali-imx_r53.0.bb => mali-imx_r54.0.bb} (55%) diff --git a/recipes-graphics/mali/mali-imx.inc b/recipes-graphics/mali/mali-imx.inc index e4fafeb0..8956d7dd 100644 --- a/recipes-graphics/mali/mali-imx.inc +++ b/recipes-graphics/mali/mali-imx.inc @@ -45,6 +45,7 @@ FILES:${PN}-opencl-icd = " \ ${sysconfdir}/OpenCL" FILES:${PN}-libvulkan = " \ ${sysconfdir}/vulkan" +RDEPENDS:${PN}-libvulkan = "vulkan-wsi-layer" FILES:${PN}-dev = " \ ${bindir}/malisc" diff --git a/recipes-graphics/mali/mali-imx_r53.0.bb b/recipes-graphics/mali/mali-imx_r54.0.bb similarity index 55% rename from recipes-graphics/mali/mali-imx_r53.0.bb rename to recipes-graphics/mali/mali-imx_r54.0.bb index 74d9d0fa..85ac6f8c 100644 --- a/recipes-graphics/mali/mali-imx_r53.0.bb +++ b/recipes-graphics/mali/mali-imx_r54.0.bb @@ -1,13 +1,13 @@ require mali-imx.inc LICENSE = "Proprietary" -LIC_FILES_CHKSUM = "file://COPYING;md5=c0fb372b5d7f12181de23ef480f225f3" +LIC_FILES_CHKSUM = "file://COPYING;md5=a93b654673e1bc8398ed1f30e0813359" -SRC_URI = "${FSL_MIRROR}/${BPN}-${PV}-${IMX_SRCREV_ABBREV}.bin;fsl-eula=true" -SRC_URI[sha256sum] = "67a008bc64af4f3d9ad91465af3c0c3ac90ff8dcbcdaed96036eccc62880c7a3" -IMX_SRCREV_ABBREV = "f2226b0" +SRC_URI = "${FSL_MIRROR}/${BP}-${IMX_SRCREV_ABBREV}.bin;fsl-eula=true" +SRC_URI[sha256sum] = "df89c80456c73ee8c235201b98c0b678d993083540912eab968dc0cbf683ad26" +IMX_SRCREV_ABBREV = "2943b3d" -S = "${UNPACKDIR}/${BPN}-${PV}-${IMX_SRCREV_ABBREV}" +S = "${UNPACKDIR}/${BP}-${IMX_SRCREV_ABBREV}" inherit fsl-eula-unpack From 0fa78aab193dc4089f2d9a6ecebb06e2684f840c Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 11:50:34 -0500 Subject: [PATCH 07/13] vulkan-wsi-layer: Initial version Signed-off-by: Tom Hochstein --- .../0001-MGS-6801-ccc-vkmark-on-wayland.patch | 30 +++ ...-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch | 243 ++++++++++++++++++ ...0003-Update-minimum-version-of-CMake.patch | 32 +++ .../vulkan/vulkan-wsi-layer_git.bb | 54 ++++ 4 files changed, 359 insertions(+) create mode 100644 recipes-graphics/vulkan/vulkan-wsi-layer/0001-MGS-6801-ccc-vkmark-on-wayland.patch create mode 100644 recipes-graphics/vulkan/vulkan-wsi-layer/0002-MGS-6823-nxp-Add-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch create mode 100644 recipes-graphics/vulkan/vulkan-wsi-layer/0003-Update-minimum-version-of-CMake.patch create mode 100644 recipes-graphics/vulkan/vulkan-wsi-layer_git.bb diff --git a/recipes-graphics/vulkan/vulkan-wsi-layer/0001-MGS-6801-ccc-vkmark-on-wayland.patch b/recipes-graphics/vulkan/vulkan-wsi-layer/0001-MGS-6801-ccc-vkmark-on-wayland.patch new file mode 100644 index 00000000..48cfcd76 --- /dev/null +++ b/recipes-graphics/vulkan/vulkan-wsi-layer/0001-MGS-6801-ccc-vkmark-on-wayland.patch @@ -0,0 +1,30 @@ +From ada74fb0ca3099f33d173eb664bd7e42025a3277 Mon Sep 17 00:00:00 2001 +From: Prabhu Sundararaj +Date: Mon, 9 Dec 2024 09:15:11 +0800 +Subject: [PATCH 1/2] MGS-6801 [#ccc] vkmark on wayland + +Extend the wayland surface properties with VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR + +Upstream-Status: Inappropriate [i.MX-specific] +Signed-off-by: Prabhu Sundararaj +Signed-off-by: Jiyu Yang +--- + wsi/wayland/surface_properties.cpp | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/wsi/wayland/surface_properties.cpp b/wsi/wayland/surface_properties.cpp +index e6435b9..bc1a737 100644 +--- a/wsi/wayland/surface_properties.cpp ++++ b/wsi/wayland/surface_properties.cpp +@@ -89,7 +89,7 @@ VkResult surface_properties::get_surface_capabilities(VkPhysicalDevice physical_ + + /* Composite alpha */ + pSurfaceCapabilities->supportedCompositeAlpha = static_cast( +- VK_COMPOSITE_ALPHA_PRE_MULTIPLIED_BIT_KHR | VK_COMPOSITE_ALPHA_INHERIT_BIT_KHR); ++ VK_COMPOSITE_ALPHA_PRE_MULTIPLIED_BIT_KHR | VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR); + return VK_SUCCESS; + } + +-- +2.37.1 + diff --git a/recipes-graphics/vulkan/vulkan-wsi-layer/0002-MGS-6823-nxp-Add-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch b/recipes-graphics/vulkan/vulkan-wsi-layer/0002-MGS-6823-nxp-Add-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch new file mode 100644 index 00000000..9955f415 --- /dev/null +++ b/recipes-graphics/vulkan/vulkan-wsi-layer/0002-MGS-6823-nxp-Add-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch @@ -0,0 +1,243 @@ +From 4293d8835eaa45168c070793eefd8867c6ec7605 Mon Sep 17 00:00:00 2001 +From: Yuan Tian +Date: Thu, 27 Jul 2023 18:25:16 +0800 +Subject: [PATCH 2/2] MGS-6823 [#nxp] Add support of + VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR feature + +Mali vulkan driver doesn't support VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR. It caused unwanted blending effect in many vulkan cases. +Add support of this feature to solve the problem. + +Upstream-Status: Inappropriate [i.MX-specific] +Signed-off-by: Yuan Tian +Signed-off-by: Jiyu Yang +--- + wsi/wayland/swapchain.cpp | 161 ++++++++++++++++++++++++++++++++++++++ + wsi/wayland/swapchain.hpp | 9 +++ + 2 files changed, 170 insertions(+) + +Index: git/wsi/wayland/swapchain.cpp +=================================================================== +--- git.orig/wsi/wayland/swapchain.cpp ++++ git/wsi/wayland/swapchain.cpp +@@ -38,6 +38,7 @@ + #include + #include + #include ++#include + + #include "util/drm/drm_utils.hpp" + #include "util/log.hpp" +@@ -72,12 +73,152 @@ swapchain::~swapchain() + wsialloc_delete(m_wsi_allocator); + } + m_wsi_allocator = nullptr; ++ if (wlc.opaque_region) ++ { ++ wl_compositor_destroy(wlc.wl_compositor); ++ wl_registry_destroy(wlc.registry); ++ wl_region_destroy(wlc.opaque_region); ++ wlc = {0}; ++ } + if (m_buffer_queue != nullptr) + { + wl_event_queue_destroy(m_buffer_queue); + } + } + ++static inline int ++poll_event(struct wl_display *wl_dpy, short int events, int timeout) ++{ ++ int ret; ++ struct pollfd pfd[1]; ++ ++ pfd[0].fd = wl_display_get_fd(wl_dpy); ++ pfd[0].events = events; ++ ++ do ++ { ++ ret = poll(pfd, 1, timeout); ++ } ++ while (ret == -1 && errno == EINTR); ++ ++ return ret; ++} ++ ++static int ++dispatch_queue_op(struct wl_display *wl_dpy, ++ struct wl_event_queue *wl_queue, int timeout) ++{ ++ int ret; ++ ++ if (wl_display_prepare_read_queue(wl_dpy, wl_queue) == -1) ++ { ++ return wl_display_dispatch_queue_pending(wl_dpy, wl_queue); ++ } ++ ++ for (;;) ++ { ++ ret = wl_display_flush(wl_dpy); ++ ++ if (ret != -1 || errno != EAGAIN) ++ break; ++ ++ if (poll_event(wl_dpy, POLLOUT, -1) == -1) ++ { ++ wl_display_cancel_read(wl_dpy); ++ return -1; ++ } ++ } ++ ++ /* Don't stop if flushing hits an EPIPE; continue so we can read any ++ * protocol error that may have triggered it. */ ++ if (ret < 0 && errno != EPIPE) ++ { ++ wl_display_cancel_read(wl_dpy); ++ return -1; ++ } ++ ++ ret = poll_event(wl_dpy, POLLIN, timeout); ++ ++ /* cancel read when on error or timeout. */ ++ if (ret == -1 || ret == 0) ++ { ++ wl_display_cancel_read(wl_dpy); ++ return ret; ++ } ++ ++ if (wl_display_read_events(wl_dpy) == -1) ++ return -1; ++ ++ return wl_display_dispatch_queue_pending(wl_dpy, wl_queue); ++} ++ ++static void ++sync_callback(void *data, struct wl_callback *callback, uint32_t serial) ++{ ++ int *done = (int *)data; ++ ++ *done = 1; ++ wl_callback_destroy(callback); ++} ++ ++static const struct wl_callback_listener sync_listener = { ++ sync_callback ++}; ++ ++static int ++roundtrip_queue(struct wl_display *wl_dpy, struct wl_event_queue *wl_queue) ++{ ++ struct wl_callback *callback; ++ int done, ret = 0; ++ ++ done = 0; ++ ++ /* ++ * This is to block read & dispatch events in other threads, so that the ++ * callback is with correct queue and listener when 'done' event. ++ */ ++ while (wl_display_prepare_read_queue(wl_dpy, wl_queue) == -1) ++ wl_display_dispatch_queue_pending(wl_dpy, wl_queue); ++ ++ callback = wl_display_sync(wl_dpy); ++ ++ if (callback == NULL) ++ { ++ wl_display_cancel_read(wl_dpy); ++ return -1; ++ } ++ ++ wl_proxy_set_queue((struct wl_proxy *) callback, wl_queue); ++ wl_callback_add_listener(callback, &sync_listener, &done); ++ ++ wl_display_cancel_read(wl_dpy); ++ ++ while (!done && ret >= 0) ++ ret = dispatch_queue_op(wl_dpy, wl_queue, 5); ++ ++ if (ret == -1 && !done) ++ wl_callback_destroy(callback); ++ ++ return ret; ++} ++ ++static void ++registry_handle_global(void *data, struct wl_registry *registry, uint32_t name, ++ const char *interface, uint32_t version) ++{ ++ wl_context *pwlc = (wl_context *)data; ++ ++ if(!pwlc->wl_compositor) ++ { ++ pwlc->wl_compositor = (wl_compositor *)wl_registry_bind(registry, name, &wl_compositor_interface, 1); ++ wl_proxy_set_queue((struct wl_proxy *)pwlc->wl_compositor, pwlc->wl_queue); ++ } ++} ++ ++static const struct wl_registry_listener registry_listener = { ++ registry_handle_global ++}; ++ + VkResult swapchain::init_platform(VkDevice device, const VkSwapchainCreateInfoKHR *swapchain_create_info, + bool &use_presentation_thread) + { +@@ -124,6 +265,21 @@ VkResult swapchain::init_platform(VkDevi + use_presentation_thread = + WAYLAND_FIFO_PRESENTATION_THREAD_ENABLED && (m_present_mode != VK_PRESENT_MODE_MAILBOX_KHR); + ++ if (swapchain_create_info->compositeAlpha & VK_COMPOSITE_ALPHA_OPAQUE_BIT_KHR) ++ { ++ wlc.wl_queue = m_buffer_queue; ++ wlc.registry = wl_display_get_registry(m_display); ++ wl_proxy_set_queue((struct wl_proxy *)(wlc.registry), m_buffer_queue); ++ wl_registry_add_listener(wlc.registry, ®istry_listener, &wlc); ++ ++ roundtrip_queue(m_display, m_buffer_queue); ++ ++ wlc.opaque_region = wl_compositor_create_region(wlc.wl_compositor); ++ wl_proxy_set_queue((struct wl_proxy *)(wlc.opaque_region), m_buffer_queue); ++ ++ wl_region_add(wlc.opaque_region, 0, 0, swapchain_create_info->imageExtent.width, swapchain_create_info->imageExtent.height); ++ } ++ + return VK_SUCCESS; + } + +@@ -494,6 +650,11 @@ void swapchain::present_image(const pend + set_error_state(VK_ERROR_SURFACE_LOST_KHR); + } + ++ if (wlc.opaque_region) ++ { ++ wl_surface_set_opaque_region(m_surface, wlc.opaque_region); ++ } ++ + wl_surface_attach(m_surface, image_data->buffer, 0, 0); + + auto present_sync_fd = image_data->present_fence.export_sync_fd(); +Index: git/wsi/wayland/swapchain.hpp +=================================================================== +--- git.orig/wsi/wayland/swapchain.hpp ++++ git/wsi/wayland/swapchain.hpp +@@ -78,6 +78,14 @@ struct image_creation_parameters + } + }; + ++struct wl_context ++{ ++ struct wl_event_queue *wl_queue; ++ struct wl_compositor *wl_compositor; ++ struct wl_registry *registry; ++ struct wl_region *opaque_region; ++}; ++ + class swapchain : public wsi::swapchain_base + { + public: +@@ -190,6 +198,7 @@ private: + + struct wl_display *m_display; + struct wl_surface *m_surface; ++ struct wl_context wlc = {0}; + /** Raw pointer to the WSI Surface that this swapchain was created from. The Vulkan specification ensures that the + * surface is valid until swapchain is destroyed. */ + surface *m_wsi_surface; diff --git a/recipes-graphics/vulkan/vulkan-wsi-layer/0003-Update-minimum-version-of-CMake.patch b/recipes-graphics/vulkan/vulkan-wsi-layer/0003-Update-minimum-version-of-CMake.patch new file mode 100644 index 00000000..0bc00de0 --- /dev/null +++ b/recipes-graphics/vulkan/vulkan-wsi-layer/0003-Update-minimum-version-of-CMake.patch @@ -0,0 +1,32 @@ +From 0c4ed8178a25135ced9df8c8a8909e2882bfe869 Mon Sep 17 00:00:00 2001 +From: Maged Elnaggar +Date: Tue, 17 Jun 2025 10:33:44 +0000 +Subject: [PATCH] Update minimum version of CMake + +Set CMake minimum required version range to 3.4.3...4.0 +to silence compatibility errors in CMake 4.0 +by explicitly opting into all policies up to 4.0 + +Upstream-Status: Backport [https://gitlab.freedesktop.org/mesa/vulkan-wsi-layer/-/commit/1eafebc56a7f735cd4e8298956d596c64ac9f681] +Signed-off-by: Maged Elnaggar +Change-Id: I2e0527dde4e764e9c17f519fc0ddd3c0e382fa31 +--- + CMakeLists.txt | 2 +- + 1 file changed, 1 insertion(+), 1 deletion(-) + +diff --git a/CMakeLists.txt b/CMakeLists.txt +index 4dc800c..b91cd54 100644 +--- a/CMakeLists.txt ++++ b/CMakeLists.txt +@@ -20,7 +20,7 @@ + # OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE + # SOFTWARE. + +-cmake_minimum_required(VERSION 3.4.3) ++cmake_minimum_required(VERSION 3.4.3...4.0) + project(VkLayer_window_system_integration) + + find_package(PkgConfig REQUIRED) +-- +2.34.1 + diff --git a/recipes-graphics/vulkan/vulkan-wsi-layer_git.bb b/recipes-graphics/vulkan/vulkan-wsi-layer_git.bb new file mode 100644 index 00000000..efa6accb --- /dev/null +++ b/recipes-graphics/vulkan/vulkan-wsi-layer_git.bb @@ -0,0 +1,54 @@ +DESCRIPTION = "Vulkan Window System Integration Layer" +LICENSE = "MIT" +LIC_FILES_CHKSUM = "file://LICENSE;md5=c2e771b72d60a13d2de384cb49055d00" +DEPENDS = "libdrm vulkan-loader" + +PV = "0.0+git${SRCPV}" + +SRC_URI = "git://gitlab.freedesktop.org/mesa/vulkan-wsi-layer.git;protocol=https;branch=main \ + file://0001-MGS-6801-ccc-vkmark-on-wayland.patch \ + file://0002-MGS-6823-nxp-Add-support-of-VK_COMPOSITE_ALPHA_OPAQU.patch \ + file://0003-Update-minimum-version-of-CMake.patch" +SRCREV = "cb1a50cf7e640ad7306e673131ded98c0f133628" + +inherit cmake pkgconfig + +PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'wayland', 'headless', d)}" + +PACKAGECONFIG[headless] = " \ + -DBUILD_WSI_HEADLESS=1, \ + -DBUILD_WSI_HEADLESS=0, \ + ,,, \ + wayland" +PACKAGECONFIG[wayland] = " \ + -DBUILD_WSI_WAYLAND=1 -DENABLE_WAYLAND_FIFO_PRESENTATION_THREAD=1 -DSELECT_EXTERNAL_ALLOCATOR=dma_buf_heaps, \ + -DBUILD_WSI_WAYLAND=0, \ + wayland wayland-native wayland-protocols,,, \ + headless" + +EXTRA_OECMAKE = " \ + -DBUILD_WSI_DISPLAY=0 \ + -DBUILD_WSI_IMAGE_COMPRESSION_CONTROL_SWAPCHAIN=1 \ + -DCMAKE_BUILD_TYPE=Release \ + -DCMAKE_EXPORT_COMPILE_COMMANDS=1 \ + -DENABLE_INSTRUMENTATION=1 \ + -DKERNEL_HEADER_DIR=${KERNEL_HEADER_DIR} \ + -DVULKAN_WSI_LAYER_EXPERIMENTAL=0 " + +# The KERNEL_HEADER_DIR setting is required by the CMake apparently +# in order to find the DRM headers. However, the Yocto build provides +# the DRM headers via a separate recipe libdrm in order to avoid the +# kernel dependency. The CMake fails if the variable is not defined, +# so set it to an invalid value in case the build ever actually needs +# the kernel headers for something else. +KERNEL_HEADER_DIR = "KERNEL_HEADER_DIR_NOT_PROVIDED_BY_YOCTO" + +do_install() { + install -d ${D}${sysconfdir}/vulkan/implicit_layer.d + install -m 0755 ${B}/libVkLayer_window_system_integration.so ${D}${sysconfdir}/vulkan/implicit_layer.d/ + install -m 0644 ${B}/VkLayer_window_system_integration.json ${D}${sysconfdir}/vulkan/implicit_layer.d +} + +# Adjust packaging variables for unversioned library +SOLIBS = ".so" +FILES_SOLIBSDEV = "" From e90033778bce73089ca5e7d12960eb8127e8b22f Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 14:02:25 -0500 Subject: [PATCH 08/13] piglit: Update bbappend NXP 6.12.20-2.0.0 - Add GBM and Vulkan for DRM parts - Remove x11 for 6 and 7 - Add pending patches Signed-off-by: Tom Hochstein --- ...t-Include-Directories-error-Error-0-.patch | 30 +++++++++++++ ...exclusive-memory-flags-for-CL_MEM_KE.patch | 42 +++++++++++++++++++ recipes-graphics/piglit/piglit_%.bbappend | 23 ++++++++-- 3 files changed, 92 insertions(+), 3 deletions(-) create mode 100644 recipes-graphics/piglit/piglit/0001-tests-Fix-cl-test-Include-Directories-error-Error-0-.patch create mode 100644 recipes-graphics/piglit/piglit/0002-cl-Add-mutually-exclusive-memory-flags-for-CL_MEM_KE.patch diff --git a/recipes-graphics/piglit/piglit/0001-tests-Fix-cl-test-Include-Directories-error-Error-0-.patch b/recipes-graphics/piglit/piglit/0001-tests-Fix-cl-test-Include-Directories-error-Error-0-.patch new file mode 100644 index 00000000..3e673a49 --- /dev/null +++ b/recipes-graphics/piglit/piglit/0001-tests-Fix-cl-test-Include-Directories-error-Error-0-.patch @@ -0,0 +1,30 @@ +From c14b65106687b1097f5d50a993707d8a2f99005b Mon Sep 17 00:00:00 2001 +From: jiajia Qian +Date: Tue, 19 Dec 2023 13:23:33 +0800 +Subject: [PATCH] tests: Fix cl test Include Directories: error : Error(0,8) : + Cannot find the header file include_test.h. + +Modified CMakeLists.txt to install include_test.h file in piglit/tests/cl/program/build/ folder. + +Modified the relative path in include-directories.cl from "tests/cl/program/build" to "../lib/piglit/tests/cl/program/build". + +Upstream-Status: Pending [https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/853] +Signed-off-by: jiajia Qian +--- + CMakeLists.txt | 1 + + tests/cl/program/build/include-directories.cl | 2 +- + 2 files changed, 2 insertions(+), 1 deletion(-) + +Index: git/tests/cl/program/build/include-directories.cl +=================================================================== +--- git.orig/tests/cl/program/build/include-directories.cl ++++ git/tests/cl/program/build/include-directories.cl +@@ -2,7 +2,7 @@ + [config] + name: Include Directories + clc_version_min: 10 +-build_options: -I . -I tests/cl/program/build ++build_options: -I . -I ../lib/piglit/tests/cl/program/build + !*/ + + #include "include_test.h" diff --git a/recipes-graphics/piglit/piglit/0002-cl-Add-mutually-exclusive-memory-flags-for-CL_MEM_KE.patch b/recipes-graphics/piglit/piglit/0002-cl-Add-mutually-exclusive-memory-flags-for-CL_MEM_KE.patch new file mode 100644 index 00000000..a4935b16 --- /dev/null +++ b/recipes-graphics/piglit/piglit/0002-cl-Add-mutually-exclusive-memory-flags-for-CL_MEM_KE.patch @@ -0,0 +1,42 @@ +From 2673c2adc81a408a4238f786cb2d795a65308ce6 Mon Sep 17 00:00:00 2001 +From: Eric Guo +Date: Fri, 11 Apr 2025 17:15:40 +0800 +Subject: [PATCH] cl: Add mutually exclusive memory flags for + CL_MEM_KERNEL_READ_AND_WRITE + +Fix cl-api-create-buffer on mali DDK. + +Upstream-Status: Submitted [https://gitlab.freedesktop.org/mesa/piglit/-/merge_requests/1004] +Signed-off-by: Eric Guo +--- + tests/util/piglit-util-cl-enum.c | 7 ++++++- + 1 file changed, 6 insertions(+), 1 deletion(-) + +diff --git a/tests/util/piglit-util-cl-enum.c b/tests/util/piglit-util-cl-enum.c +index 5d43bc102..f2c185c9c 100644 +--- a/tests/util/piglit-util-cl-enum.c ++++ b/tests/util/piglit-util-cl-enum.c +@@ -979,7 +979,7 @@ PIGLIT_CL_DEFINE_ENUM_2(cl_command_queue_properties, 2, 2, 2, 4, 4 /* really? */ + PIGLIT_CL_DEFINE_ENUM_PTR_2(cl_command_queue_properties); + + +-PIGLIT_CL_DEFINE_ENUM(cl_mem_flags, cl_mem_flags_mutexes, 5, 5, 8, 8, 8) = { ++PIGLIT_CL_DEFINE_ENUM(cl_mem_flags, cl_mem_flags_mutexes, 5, 5, 8, 11, 11) = { + CL_MEM_READ_WRITE | CL_MEM_READ_ONLY, + CL_MEM_READ_WRITE | CL_MEM_WRITE_ONLY, + CL_MEM_READ_ONLY | CL_MEM_WRITE_ONLY, +@@ -990,6 +990,11 @@ PIGLIT_CL_DEFINE_ENUM(cl_mem_flags, cl_mem_flags_mutexes, 5, 5, 8, 8, 8) = { + CL_MEM_HOST_WRITE_ONLY | CL_MEM_HOST_NO_ACCESS, + CL_MEM_HOST_READ_ONLY | CL_MEM_HOST_NO_ACCESS, + #endif //CL_VERSION_1_2 ++#if defined(CL_VERSION_2_0) ++ CL_MEM_KERNEL_READ_AND_WRITE | CL_MEM_READ_ONLY, ++ CL_MEM_KERNEL_READ_AND_WRITE | CL_MEM_WRITE_ONLY, ++ CL_MEM_KERNEL_READ_AND_WRITE | CL_MEM_READ_WRITE, ++#endif //CL_VERSION_2_0 + }; + PIGLIT_CL_DEFINE_ENUM_PTR(cl_mem_flags, cl_mem_flags_mutexes); + +-- +2.34.1 + diff --git a/recipes-graphics/piglit/piglit_%.bbappend b/recipes-graphics/piglit/piglit_%.bbappend index fe2a0bc2..3caf8aa1 100644 --- a/recipes-graphics/piglit/piglit_%.bbappend +++ b/recipes-graphics/piglit/piglit_%.bbappend @@ -1,6 +1,23 @@ -PACKAGECONFIG:remove:imxgpu = "glx" +FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" -PACKAGECONFIG:append:mx8-nxp-bsp = " opencl" -PACKAGECONFIG:append:mx9-nxp-bsp = " opencl" +SRC_URI += "file://0001-tests-Fix-cl-test-Include-Directories-error-Error-0-.patch \ + file://0002-cl-Add-mutually-exclusive-memory-flags-for-CL_MEM_KE.patch" + +PACKAGECONFIG:append = " ${PACKAGECONFIG_APPEND}" +PACKAGECONFIG:remove = " ${PACKAGECONFIG_REMOVE}" + +PACKAGECONFIG_APPEND ?= " \ + gbm \ + opencl \ + ${@bb.utils.filter('DISTRO_FEATURES', 'vulkan', d)}" +PACKAGECONFIG_APPEND:imxgpu:mx6-nxp-bsp = "" +PACKAGECONFIG_APPEND:imxgpu:mx7-nxp-bsp = "" + +PACKAGECONFIG_REMOVE ?= "" +PACKAGECONFIG_REMOVE:imxgpu = "glx" +PACKAGECONFIG_REMOVE:imxgpu:mx6-nxp-bsp = "glx x11" +PACKAGECONFIG_REMOVE:imxgpu:mx7-nxp-bsp = "glx x11" + +PACKAGECONFIG[gbm] = "-DPIGLIT_USE_GBM=1,-DPIGLIT_USE_GBM=0,virtual/libgbm" CFLAGS:append:imxgpu:toolchain-clang = " -Wno-error=int-conversion" From 5717bf74121ca3f0c6d3c7c8194e85e0626f0760 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 14:48:31 -0500 Subject: [PATCH 09/13] glslang: Align with Vulkan downgrade 1.3.275.0.imx The current glslang fails to compile. ``` | /.../SPIRV/SpvTools.cpp: In function 'spv_target_env glslang::MapToSpirvToolsEnv(const SpvVersion&, spv::SpvBuildLogger*)': | /.../SPIRV/SpvTools.cpp:75:32: error: 'SPV_ENV_VULKAN_1_4' is not a member of 'spv_target_env' | 75 | return spv_target_env::SPV_ENV_VULKAN_1_4; | | ^~~~~~~~~~~~~~~~~~ | /.../SPIRV/SpvTools.cpp: In function 'void glslang::SpirvToolsValidate(const TIntermediate&, std::vector&, spv::SpvBuildLogger*, bool)': | /.../SPIRV/SpvTools.cpp:168:5: error: 'spvValidatorOptionsSetAllowOffsetTextureOperand' was not declared in this scope | 168 | spvValidatorOptionsSetAllowOffsetTextureOperand(options, intermediate.usingTextureOffsetNonConst()); | | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ ``` Downgrade to 1.3.275.0 to align with the existing Vulkan downgrade. Signed-off-by: Tom Hochstein --- conf/machine/include/imx-base.inc | 1 + .../0001-generate-glslang-pkg-config.patch | 46 +++++++++++++++++++ ...uilder.h-add-missing-cstdint-include.patch | 33 +++++++++++++ .../glslang/glslang_1.3.275.0.imx.bb | 36 +++++++++++++++ 4 files changed, 116 insertions(+) create mode 100644 recipes-downgrade/glslang/glslang/0001-generate-glslang-pkg-config.patch create mode 100644 recipes-downgrade/glslang/glslang/0002-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch create mode 100644 recipes-downgrade/glslang/glslang_1.3.275.0.imx.bb diff --git a/conf/machine/include/imx-base.inc b/conf/machine/include/imx-base.inc index 6d1671a7..8605d7c0 100644 --- a/conf/machine/include/imx-base.inc +++ b/conf/machine/include/imx-base.inc @@ -589,6 +589,7 @@ PREFERRED_VERSION_xwayland:imx-nxp-bsp ??= "24.1.6.imx" # Use i.MX libdrm Version PREFERRED_VERSION_libdrm:imx-nxp-bsp ??= "2.4.123.imx" +PREFERRED_VERSION_glslang:imxvulkan ??= "1.3.275.0.imx" PREFERRED_VERSION_spirv-headers:imxvulkan ??= "1.3.275.0.imx" PREFERRED_VERSION_spirv-tools:imxvulkan ??= "1.3.275.0.imx" PREFERRED_VERSION_vulkan-headers:imxvulkan ??= "1.3.275.0.imx" diff --git a/recipes-downgrade/glslang/glslang/0001-generate-glslang-pkg-config.patch b/recipes-downgrade/glslang/glslang/0001-generate-glslang-pkg-config.patch new file mode 100644 index 00000000..337a999b --- /dev/null +++ b/recipes-downgrade/glslang/glslang/0001-generate-glslang-pkg-config.patch @@ -0,0 +1,46 @@ +From 4cede5edcff96134baf35953d58595c4aa5f1fc5 Mon Sep 17 00:00:00 2001 +From: Jose Quaresma +Date: Sun, 7 Feb 2021 01:30:39 +0000 +Subject: [PATCH] generate glslang pkg-config + +Based on https://src.fedoraproject.org/rpms/glslang/blob/main/f/0001-pkg-config-compatibility.patch + +Upstream-Status: Inappropriate [independently developed patch submitted at https://github.com/KhronosGroup/glslang/pull/3371] + +Signed-off-by: Jose Quaresma +--- + glslang/CMakeLists.txt | 2 ++ + glslang/glslang.pc.cmake.in | 11 +++++++++++ + 2 files changed, 13 insertions(+) + create mode 100644 glslang/glslang.pc.cmake.in + +diff --git a/glslang/CMakeLists.txt b/glslang/CMakeLists.txt +index 37eecaad..6974935c 100644 +--- a/glslang/CMakeLists.txt ++++ b/glslang/CMakeLists.txt +@@ -251,6 +251,8 @@ if(PROJECT_IS_TOP_LEVEL) + ") + install(FILES "${CMAKE_CURRENT_BINARY_DIR}/glslangTargets.cmake" DESTINATION ${CMAKE_INSTALL_LIBDIR}/cmake) + endif() ++ configure_file(${CMAKE_CURRENT_SOURCE_DIR}/glslang.pc.cmake.in ${CMAKE_CURRENT_BINARY_DIR}/pkgconfig/glslang.pc @ONLY) ++ install(FILES ${CMAKE_CURRENT_BINARY_DIR}/pkgconfig/glslang.pc DESTINATION ${CMAKE_INSTALL_LIBDIR}/pkgconfig) + + set(PUBLIC_HEADERS + Public/ResourceLimits.h +diff --git a/glslang/glslang.pc.cmake.in b/glslang/glslang.pc.cmake.in +new file mode 100644 +index 00000000..43104e68 +--- /dev/null ++++ b/glslang/glslang.pc.cmake.in +@@ -0,0 +1,11 @@ ++prefix=@CMAKE_INSTALL_PREFIX@ ++exec_prefix=@CMAKE_INSTALL_PREFIX@ ++libdir=${exec_prefix}/@CMAKE_INSTALL_LIBDIR@ ++includedir=${prefix}/@CMAKE_INSTALL_INCLUDEDIR@ ++ ++Name: @PROJECT_NAME@ ++Description: OpenGL and OpenGL ES shader front end and validator ++Requires: ++Version: @GLSLANG_VERSION@ ++Libs: -L${libdir} -lglslang -lHLSL -lSPVRemapper ++Cflags: -I${includedir} diff --git a/recipes-downgrade/glslang/glslang/0002-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch b/recipes-downgrade/glslang/glslang/0002-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch new file mode 100644 index 00000000..9f9270e6 --- /dev/null +++ b/recipes-downgrade/glslang/glslang/0002-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch @@ -0,0 +1,33 @@ +From e40c14a3e007fac0e4f2e4164fdf14d1712355bd Mon Sep 17 00:00:00 2001 +From: Sergei Trofimovich +Date: Fri, 2 Aug 2024 22:44:21 +0100 +Subject: [PATCH] SPIRV/SpvBuilder.h: add missing include + +Without the change `glslang` build fails on upcoming `gcc-15` as: + + In file included from /build/source/SPIRV/GlslangToSpv.cpp:45: + SPIRV/SpvBuilder.h:248:30: error: 'uint32_t' has not been declared + 248 | Id makeDebugLexicalBlock(uint32_t line); + | ^~~~~~~~ +--- + SPIRV/SpvBuilder.h | 1 + + 1 file changed, 1 insertion(+) + +Upstream-Status: Backport [https://github.com/KhronosGroup/glslang/commit/e40c14a3e007fac0e4f2e4164fdf14d1712355bd] +Signed-off-by: Tom Hochstein + +diff --git a/SPIRV/SpvBuilder.h b/SPIRV/SpvBuilder.h +index f86dd81b3..d688436a6 100644 +--- a/SPIRV/SpvBuilder.h ++++ b/SPIRV/SpvBuilder.h +@@ -56,6 +56,7 @@ namespace spv { + } + + #include ++#include + #include + #include + #include +-- +2.34.1 + diff --git a/recipes-downgrade/glslang/glslang_1.3.275.0.imx.bb b/recipes-downgrade/glslang/glslang_1.3.275.0.imx.bb new file mode 100644 index 00000000..7b3c2f60 --- /dev/null +++ b/recipes-downgrade/glslang/glslang_1.3.275.0.imx.bb @@ -0,0 +1,36 @@ +SUMMARY = "OpenGL / OpenGL ES Reference Compiler" +DESCRIPTION = "Glslang is the official reference compiler front end for the \ +OpenGL ES and OpenGL shading languages. It implements a strict interpretation \ +of the specifications for these languages. It is open and free for anyone to use, \ +either from a command line or programmatically." +SECTION = "graphics" +HOMEPAGE = "https://www.khronos.org/opengles/sdk/tools/Reference-Compiler" +LICENSE = "BSD-3-Clause & BSD-2-Clause & MIT & Apache-2.0 & GPL-3-with-bison-exception" +LIC_FILES_CHKSUM = "file://LICENSE.txt;md5=2a2b5acd7bc4844964cfda45fe807dc3" + +SRCREV = "a91631b260cba3f22858d6c6827511e636c2458a" +SRC_URI = "git://github.com/KhronosGroup/glslang.git;protocol=https;branch=main \ + file://0001-generate-glslang-pkg-config.patch \ + file://0002-SPIRV-SpvBuilder.h-add-missing-cstdint-include.patch" +PE = "1" +# These recipes need to be updated in lockstep with each other: +# glslang, vulkan-headers, vulkan-loader, vulkan-tools, spirv-headers, spirv-tools +# vulkan-validation-layers, vulkan-utility-libraries. +# The tags versions should always be sdk-x.y.z, as this is what +# upstream considers a release. +UPSTREAM_CHECK_GITTAGREGEX = "sdk-(?P\d+(\.\d+)+)" + +inherit cmake python3native + +DEPENDS = "spirv-tools" + +EXTRA_OECMAKE = " \ + -DCMAKE_BUILD_TYPE=Release \ + -DBUILD_SHARED_LIBS=ON \ + -DENABLE_PCH=OFF \ + -DENABLE_CTEST=OFF \ + -DBUILD_EXTERNAL=OFF \ + -DALLOW_EXTERNAL_SPIRV_TOOLS=ON \ +" + +BBCLASSEXTEND = "native nativesdk" From 6ba1226f1199cc7bb2a54e4313cf1d6682b2cd2e Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 15:02:21 -0500 Subject: [PATCH 10/13] weston: Backport recipe fixes to 10.0.5.imx Backports: 23271a1 weston: Add missing runtime dependency on freerdp 50608d9 weston: Fix wayland-protocols dependency Signed-off-by: Tom Hochstein --- recipes-graphics/wayland/weston_10.0.5.imx.bb | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/recipes-graphics/wayland/weston_10.0.5.imx.bb b/recipes-graphics/wayland/weston_10.0.5.imx.bb index a8440cf2..4d7d9913 100644 --- a/recipes-graphics/wayland/weston_10.0.5.imx.bb +++ b/recipes-graphics/wayland/weston_10.0.5.imx.bb @@ -68,7 +68,7 @@ PACKAGECONFIG[headless] = "-Dbackend-headless=true,-Dbackend-headless=false" # Weston on framebuffer PACKAGECONFIG[fbdev] = "-Ddeprecated-backend-fbdev=true,-Ddeprecated-backend-fbdev=false,udev mtdev" # Weston on RDP -PACKAGECONFIG[rdp] = "-Dbackend-rdp=true,-Dbackend-rdp=false,freerdp" +PACKAGECONFIG[rdp] = "-Dbackend-rdp=true,-Dbackend-rdp=false,freerdp,freerdp" # weston-launch PACKAGECONFIG[launch] = "-Ddeprecated-weston-launch=true,-Ddeprecated-weston-launch=false,drm" # VA-API desktop recorder @@ -144,7 +144,7 @@ RDEPENDS:${PN}-xwayland += "xwayland" RDEPENDS:${PN} += "xkeyboard-config" RRECOMMENDS:${PN} = "weston-init liberation-fonts" -RRECOMMENDS:${PN}-dev += "wayland-protocols" +RDEPENDS:${PN}-dev += "wayland-protocols-dev" USERADD_PACKAGES = "${PN}" GROUPADD_PARAM:${PN} = "--system weston-launch" @@ -205,6 +205,6 @@ EXTRA_OEMESON += "-Ddeprecated-wl-shell=true" LDFLAGS:append:imxgpu:libc-musl = " -Wl,--allow-shlib-undefined" PACKAGE_ARCH = "${MACHINE_SOCARCH}" -COMPATIBLE_MACHINE = "(imxfbdev|imxgpu)" +COMPATIBLE_MACHINE = "(imx-nxp-bsp)" ########### End of i.MX overrides ######### From a3c087a3cbfb67240ac869a497f32f4f12877d3c Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Fri, 15 Aug 2025 15:06:57 -0500 Subject: [PATCH 11/13] weston: Upgrade 14.0.1.imx -> 14.0.2.imx Signed-off-by: Tom Hochstein --- conf/machine/include/imx-base.inc | 2 +- ...ton_14.0.1.imx.bb => weston_14.0.2.imx.bb} | 35 +++++++------------ 2 files changed, 14 insertions(+), 23 deletions(-) rename recipes-graphics/wayland/{weston_14.0.1.imx.bb => weston_14.0.2.imx.bb} (89%) diff --git a/conf/machine/include/imx-base.inc b/conf/machine/include/imx-base.inc index 8605d7c0..f9151e4f 100644 --- a/conf/machine/include/imx-base.inc +++ b/conf/machine/include/imx-base.inc @@ -576,7 +576,7 @@ PREFERRED_PROVIDER_virtual/libg2d ?= "imx-gpu-g2d" PREFERRED_PROVIDER_virtual/libg2d:imxdpu ?= "imx-dpu-g2d" PREFERRED_PROVIDER_virtual/libg2d:mx93-nxp-bsp ?= "imx-pxp-g2d" -PREFERRED_VERSION_weston:imx-nxp-bsp ??= "14.0.1.imx" +PREFERRED_VERSION_weston:imx-nxp-bsp ??= "14.0.2.imx" # i.MX 6 & 7 stay on weston 10.0 for fbdev PREFERRED_VERSION_weston:mx6-nxp-bsp ??= "10.0.5.imx" PREFERRED_VERSION_weston:mx7-nxp-bsp ??= "10.0.5.imx" diff --git a/recipes-graphics/wayland/weston_14.0.1.imx.bb b/recipes-graphics/wayland/weston_14.0.2.imx.bb similarity index 89% rename from recipes-graphics/wayland/weston_14.0.1.imx.bb rename to recipes-graphics/wayland/weston_14.0.2.imx.bb index 96bde0fe..c4f938e5 100644 --- a/recipes-graphics/wayland/weston_14.0.1.imx.bb +++ b/recipes-graphics/wayland/weston_14.0.2.imx.bb @@ -3,7 +3,7 @@ # recipe. The second section customizes the recipe for i.MX. ########### OE-core copy ################## -# Upstream hash: 23271a1f908a223b4eb56d6034cbb1ac23da14fe +# Upstream hash: 8996690a79ac42a1dee6d041eeb1c1fe29fdac84 SUMMARY = "Weston, a Wayland compositor" DESCRIPTION = "Weston is the reference implementation of a Wayland compositor" @@ -14,14 +14,13 @@ LIC_FILES_CHKSUM = "file://COPYING;md5=d79ee9e66bb0f95d3386a7acae780b70 \ " SRC_URI = "https://gitlab.freedesktop.org/wayland/weston/-/releases/${PV}/downloads/${BPN}-${PV}.tar.xz \ - file://0001-libweston-tools-Include-libgen.h-for-basename-signat.patch \ file://weston.png \ file://weston.desktop \ file://xwayland.weston-start \ file://systemd-notify.weston-start \ " -SRC_URI[sha256sum] = "27f68d96e3b97d98daadef13a202356524924fa381418fa6716b9136ef099093" +SRC_URI[sha256sum] = "a8150505b126a59df781fe8c30c8e6f87da7013e179039eb844a5bbbcc7c79b3" UPSTREAM_CHECK_URI = "https://gitlab.freedesktop.org/wayland/weston/-/tags" UPSTREAM_CHECK_REGEX = "releases/(?P\d+\.\d+\.(?!9\d+)\d+)" @@ -33,13 +32,13 @@ inherit meson pkgconfig useradd require ${THISDIR}/required-distro-features.inc DEPENDS = "libxkbcommon gdk-pixbuf pixman cairo glib-2.0" -DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native" +DEPENDS += "wayland wayland-protocols libinput virtual/egl pango wayland-native libdisplay-info" LDFLAGS += "${@bb.utils.contains('DISTRO_FEATURES', 'lto', '-Wl,-z,undefs', '', d)}" WESTON_MAJOR_VERSION = "${@'.'.join(d.getVar('PV').split('.')[0:1])}" -EXTRA_OEMESON += "-Dpipewire=false" +EXTRA_OEMESON += "-Dpipewire=false -Dtests=false" PACKAGECONFIG ??= "${@bb.utils.contains('DISTRO_FEATURES', 'wayland', 'kms wayland egl clients', '', d)} \ ${@bb.utils.contains('DISTRO_FEATURES', 'x11 wayland', 'xwayland', '', d)} \ @@ -80,9 +79,7 @@ PACKAGECONFIG[webp] = "-Dimage-webp=true,-Dimage-webp=false,libwebp" # Weston with systemd support PACKAGECONFIG[systemd] = "-Dsystemd=true,-Dsystemd=false,systemd dbus" # Weston with Xwayland support (requires X11 and Wayland) -PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false,libxcb libxcursor xcb-util-cursor xwayland" -# colord CMS support -PACKAGECONFIG[colord] = "-Ddeprecated-color-management-colord=true,-Ddeprecated-color-management-colord=false,colord" +PACKAGECONFIG[xwayland] = "-Dxwayland=true,-Dxwayland=false,libxcb libxcursor xwayland" # Clients support PACKAGECONFIG[clients] = "-Dsimple-clients=${SIMPLECLIENTS} -Ddemo-clients=true,-Dsimple-clients= -Ddemo-clients=false" # Virtual remote output with GStreamer on DRM backend @@ -147,7 +144,7 @@ RDEPENDS:${PN}-xwayland += "xwayland" RDEPENDS:${PN} += "xkeyboard-config" RRECOMMENDS:${PN} = "weston-init liberation-fonts" -RRECOMMENDS:${PN}-dev += "wayland-protocols" +RDEPENDS:${PN}-dev += "wayland-protocols-dev" USERADD_PACKAGES = "${PN}" GROUPADD_PARAM:${PN} = "--system weston-launch" @@ -162,26 +159,20 @@ LIC_FILES_CHKSUM += "file://LICENSE;md5=d79ee9e66bb0f95d3386a7acae780b70" DEFAULT_PREFERENCE = "-1" -DEPENDS:append = " libdisplay-info" - SRC_URI:remove = "https://gitlab.freedesktop.org/wayland/weston/-/releases/${PV}/downloads/${BPN}-${PV}.tar.xz" SRC_URI:prepend = "${WESTON_SRC};branch=${SRCBRANCH} " WESTON_SRC ?= "git://github.com/nxp-imx/weston-imx.git;protocol=https" -SRCBRANCH = "weston-imx-14.0.1" -SRCREV = "0fd5d3ab75346e525b565039a7b8bf5d9008be78" +SRCBRANCH = "weston-imx-14.0.2" +SRCREV = "c267ba8e6eed3a824e042a200bcc1b4c370ba88f" -SRC_URI:remove = "file://0001-libweston-tools-Include-libgen.h-for-basename-signat.patch" - -PACKAGECONFIG_IMX_REMOVALS ?= "wayland x11" PACKAGECONFIG:remove = "${PACKAGECONFIG_IMX_REMOVALS}" +PACKAGECONFIG_IMX_REMOVALS ?= "wayland x11" PACKAGECONFIG:append = " ${PACKAGECONFIG_G2D}" -PACKAGECONFIG_G2D ??= "" -PACKAGECONFIG_G2D:imxgpu2d ??= "imxg2d" -PACKAGECONFIG_G2D:mx93-nxp-bsp ??= "imxg2d" - -# Remove no longer supported colord -PACKAGECONFIG[colord] = "" +PACKAGECONFIG_G2D ??= "" +PACKAGECONFIG_G2D:imxgpu2d ??= "imxg2d" +PACKAGECONFIG_G2D:mx93-nxp-bsp ??= "imxg2d" +PACKAGECONFIG_G2D:mx943-nxp-bsp ??= "imxg2d" # Weston with i.MX G2D renderer PACKAGECONFIG[imxg2d] = "-Drenderer-g2d=true,-Drenderer-g2d=false,virtual/libg2d" From 43b21c7e8782d3900c602c41b4c7791974668143 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Wed, 20 Aug 2025 08:58:06 -0500 Subject: [PATCH 12/13] vulkan-loader: Update i.MX 9 to latest Vulkan Vivante is limited to older Vulkan, but Mali is not. Adapt the bbappend so i.MX 9 can use the latest Vulkan while i.MX 8 continues to be limited to 1.3.275.0.imx. Signed-off-by: Tom Hochstein --- ...ange-mali-wsi-layer-activating-order.patch | 15 +++--- ...ange-mali-wsi-layer-activating-order.patch | 52 +++++++++++++++++++ ....imx.bbappend => vulkan-loader_%.bbappend} | 8 +-- 3 files changed, 63 insertions(+), 12 deletions(-) create mode 100644 recipes-graphics/vulkan/vulkan-loader/mx8-nxp-bsp/0001-LF-11869-change-mali-wsi-layer-activating-order.patch rename recipes-graphics/vulkan/{vulkan-loader_1.3.275.0.imx.bbappend => vulkan-loader_%.bbappend} (70%) diff --git a/recipes-graphics/vulkan/vulkan-loader/0001-LF-11869-change-mali-wsi-layer-activating-order.patch b/recipes-graphics/vulkan/vulkan-loader/0001-LF-11869-change-mali-wsi-layer-activating-order.patch index da738aab..f54919cd 100644 --- a/recipes-graphics/vulkan/vulkan-loader/0001-LF-11869-change-mali-wsi-layer-activating-order.patch +++ b/recipes-graphics/vulkan/vulkan-loader/0001-LF-11869-change-mali-wsi-layer-activating-order.patch @@ -1,4 +1,4 @@ -From 3448c245b15928aa5a5a3695d9271fb201eb2e3b Mon Sep 17 00:00:00 2001 +From 91aff12a127428ff558d57d93b91b0b909321c35 Mon Sep 17 00:00:00 2001 From: Yuan Tian Date: Sat, 27 Apr 2024 06:06:54 +0800 Subject: [PATCH] LF-11869 change mali wsi layer activating order @@ -11,18 +11,18 @@ Signed-off-by: Yuan Tian 1 file changed, 12 insertions(+) diff --git a/loader/loader.c b/loader/loader.c -index e646b28b4..55912c178 100644 +index 9064cd633..5b00870a4 100644 --- a/loader/loader.c +++ b/loader/loader.c -@@ -2906,6 +2906,7 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s +@@ -3034,6 +3034,7 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s #if !defined(_WIN32) char temp_path[2048]; #endif + bool has_wsi_layer = false; // Now, parse the paths - next_file = search_path; -@@ -2965,6 +2966,10 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s + char *next_file = search_path; +@@ -3100,6 +3101,10 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s name = full_path; VkResult local_res; @@ -33,7 +33,7 @@ index e646b28b4..55912c178 100644 local_res = add_if_manifest_file(inst, name, out_files); // Incomplete means this was not a valid data file. -@@ -2975,6 +2980,13 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s +@@ -3110,6 +3115,13 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s break; } } @@ -47,6 +47,3 @@ index e646b28b4..55912c178 100644 loader_closedir(inst, dir_stream); if (vk_result != VK_SUCCESS) { goto out; --- -2.34.1 - diff --git a/recipes-graphics/vulkan/vulkan-loader/mx8-nxp-bsp/0001-LF-11869-change-mali-wsi-layer-activating-order.patch b/recipes-graphics/vulkan/vulkan-loader/mx8-nxp-bsp/0001-LF-11869-change-mali-wsi-layer-activating-order.patch new file mode 100644 index 00000000..da738aab --- /dev/null +++ b/recipes-graphics/vulkan/vulkan-loader/mx8-nxp-bsp/0001-LF-11869-change-mali-wsi-layer-activating-order.patch @@ -0,0 +1,52 @@ +From 3448c245b15928aa5a5a3695d9271fb201eb2e3b Mon Sep 17 00:00:00 2001 +From: Yuan Tian +Date: Sat, 27 Apr 2024 06:06:54 +0800 +Subject: [PATCH] LF-11869 change mali wsi layer activating order + +Upstream-Status: Inappropriate [i.MX specific] + +Signed-off-by: Yuan Tian +--- + loader/loader.c | 12 ++++++++++++ + 1 file changed, 12 insertions(+) + +diff --git a/loader/loader.c b/loader/loader.c +index e646b28b4..55912c178 100644 +--- a/loader/loader.c ++++ b/loader/loader.c +@@ -2906,6 +2906,7 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s + #if !defined(_WIN32) + char temp_path[2048]; + #endif ++ bool has_wsi_layer = false; + + // Now, parse the paths + next_file = search_path; +@@ -2965,6 +2966,10 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s + name = full_path; + + VkResult local_res; ++ if(!strcmp(name,"/etc/vulkan/implicit_layer.d/VkLayer_window_system_integration.json")) { ++ has_wsi_layer = true; ++ continue; ++ } + local_res = add_if_manifest_file(inst, name, out_files); + + // Incomplete means this was not a valid data file. +@@ -2975,6 +2980,13 @@ VkResult add_data_files(const struct loader_instance *inst, char *search_path, s + break; + } + } ++ ++ if(has_wsi_layer) { ++ name = "/etc/vulkan/implicit_layer.d/VkLayer_window_system_integration.json"; ++ vk_result = add_if_manifest_file(inst, name, out_files); ++ has_wsi_layer = false; ++ } ++ + loader_closedir(inst, dir_stream); + if (vk_result != VK_SUCCESS) { + goto out; +-- +2.34.1 + diff --git a/recipes-graphics/vulkan/vulkan-loader_1.3.275.0.imx.bbappend b/recipes-graphics/vulkan/vulkan-loader_%.bbappend similarity index 70% rename from recipes-graphics/vulkan/vulkan-loader_1.3.275.0.imx.bbappend rename to recipes-graphics/vulkan/vulkan-loader_%.bbappend index f4624921..f72f5b01 100644 --- a/recipes-graphics/vulkan/vulkan-loader_1.3.275.0.imx.bbappend +++ b/recipes-graphics/vulkan/vulkan-loader_%.bbappend @@ -4,10 +4,12 @@ SRC_URI:append:imx-nxp-bsp = " \ file://0001-LF-11869-change-mali-wsi-layer-activating-order.patch \ " +PACKAGE_ARCH:imx-nxp-bsp = "${MACHINE_SOCARCH}" + # libvulkan.so is loaded dynamically, so put it in the main package -SOLIBS = ".so*" -FILES_SOLIBSDEV = "" -INSANE_SKIP:${PN} += "dev-so" +SOLIBS:imx-nxp-bsp = ".so*" +FILES_SOLIBSDEV:imx-nxp-bsp = "" +INSANE_SKIP:${PN}:imx-nxp-bsp += "dev-so" # Override default mesa drivers with i.MX GPU drivers RRECOMMENDS:${PN}:imxviv = "libvulkan-imx" From c2b898eed4eedc4630c891f92695390a5c2f4909 Mon Sep 17 00:00:00 2001 From: Tom Hochstein Date: Thu, 21 Aug 2025 09:04:56 -0500 Subject: [PATCH 13/13] mesa: Drop patches as no longer needed The issues addressed by the patches are fixed in the current version. Signed-off-by: Tom Hochstein --- recipes-graphics/mesa/mesa.bbappend | 4 -- ...99-cso-fix-virgl-driver-assert-issue.patch | 47 ------------------- ...l-dri2-fix-video-showing-wrong-frame.patch | 33 ------------- 3 files changed, 84 deletions(-) delete mode 100644 recipes-graphics/mesa/mesa/0001-MGS-7599-cso-fix-virgl-driver-assert-issue.patch delete mode 100644 recipes-graphics/mesa/mesa/0001-MGS-7673-egl-dri2-fix-video-showing-wrong-frame.patch diff --git a/recipes-graphics/mesa/mesa.bbappend b/recipes-graphics/mesa/mesa.bbappend index 120561d1..1c75c988 100644 --- a/recipes-graphics/mesa/mesa.bbappend +++ b/recipes-graphics/mesa/mesa.bbappend @@ -1,10 +1,6 @@ PROVIDES:remove:imxgpu = "virtual/egl" PROVIDES:remove:imxgpu3d = "virtual/libgl virtual/libgles1 virtual/libgles2" -FILESEXTRAPATHS:prepend := "${THISDIR}/${PN}:" -SRC_URI:append:mx93-nxp-bsp = " file://0001-MGS-7673-egl-dri2-fix-video-showing-wrong-frame.patch" -SRC_URI:append:imx-nxp-bsp = " file://0001-MGS-7599-cso-fix-virgl-driver-assert-issue.patch" - PACKAGECONFIG:remove:imxgpu = "egl gbm" PACKAGECONFIG:remove:imxgpu3d = "gles" diff --git a/recipes-graphics/mesa/mesa/0001-MGS-7599-cso-fix-virgl-driver-assert-issue.patch b/recipes-graphics/mesa/mesa/0001-MGS-7599-cso-fix-virgl-driver-assert-issue.patch deleted file mode 100644 index 3dc8db09..00000000 --- a/recipes-graphics/mesa/mesa/0001-MGS-7599-cso-fix-virgl-driver-assert-issue.patch +++ /dev/null @@ -1,47 +0,0 @@ -From 612c3dc98d5d050b9cfee16ec77ca3c8358caa0d Mon Sep 17 00:00:00 2001 -From: Wujian Sun -Date: Mon, 29 Apr 2024 17:29:16 +0800 -Subject: [PATCH] MGS-7599 cso: fix virgl driver assert issue - -A workaround that remove PIPE_MAX_SAMPLERS and -PIPE_MAX_CONSTANT_BUFFERS assert. - -Upstream-Status: Inappropriate [i.MX-specific] - -Signed-off-by: Wujian Sun ---- - src/gallium/auxiliary/cso_cache/cso_context.c | 2 -- - src/gallium/drivers/virgl/virgl_screen.c | 2 +- - 2 files changed, 1 insertion(+), 3 deletions(-) - -diff --git a/src/gallium/auxiliary/cso_cache/cso_context.c b/src/gallium/auxiliary/cso_cache/cso_context.c -index 3e86def31c5..ffc6d22da9c 100644 ---- a/src/gallium/auxiliary/cso_cache/cso_context.c -+++ b/src/gallium/auxiliary/cso_cache/cso_context.c -@@ -403,10 +403,8 @@ cso_unbind_context(struct cso_context *ctx) - PIPE_SHADER_CAP_MAX_CONST_BUFFERS); - int maximg = scr->get_shader_param(scr, sh, - PIPE_SHADER_CAP_MAX_SHADER_IMAGES); -- assert(maxsam <= PIPE_MAX_SAMPLERS); - assert(maxview <= PIPE_MAX_SHADER_SAMPLER_VIEWS); - assert(maxssbo <= PIPE_MAX_SHADER_BUFFERS); -- assert(maxcb <= PIPE_MAX_CONSTANT_BUFFERS); - assert(maximg <= PIPE_MAX_SHADER_IMAGES); - if (maxsam > 0) { - ctx->base.pipe->bind_sampler_states(ctx->base.pipe, sh, 0, maxsam, zeros); -diff --git a/src/gallium/drivers/virgl/virgl_screen.c b/src/gallium/drivers/virgl/virgl_screen.c -index 389a1935cc3..7c7f8ba576b 100644 ---- a/src/gallium/drivers/virgl/virgl_screen.c -+++ b/src/gallium/drivers/virgl/virgl_screen.c -@@ -435,7 +435,7 @@ virgl_get_shader_param(struct pipe_screen *screen, - return 1; - case PIPE_SHADER_CAP_MAX_TEXTURE_SAMPLERS: - return MIN2(vscreen->caps.caps.v2.max_shader_sampler_views, -- PIPE_MAX_SHADER_SAMPLER_VIEWS); -+ PIPE_MAX_SAMPLERS); - case PIPE_SHADER_CAP_INTEGERS: - return vscreen->caps.caps.v1.glsl_level >= 130; - case PIPE_SHADER_CAP_MAX_CONTROL_FLOW_DEPTH: --- -2.17.1 - diff --git a/recipes-graphics/mesa/mesa/0001-MGS-7673-egl-dri2-fix-video-showing-wrong-frame.patch b/recipes-graphics/mesa/mesa/0001-MGS-7673-egl-dri2-fix-video-showing-wrong-frame.patch deleted file mode 100644 index 0cdcbfca..00000000 --- a/recipes-graphics/mesa/mesa/0001-MGS-7673-egl-dri2-fix-video-showing-wrong-frame.patch +++ /dev/null @@ -1,33 +0,0 @@ -From 188d7b01037e5a0249e63c2600cf15a288a9ff3f Mon Sep 17 00:00:00 2001 -From: Wujian Sun -Date: Fri, 19 Apr 2024 18:38:17 +0800 -Subject: [PATCH] MGS-7673 egl/dri2: fix video showing wrong frame - -Softpipe driver doesn't support EGL_EXT_image_dma_buf_import_modifiers -extension. -Should not report the extension. - -Upstream-Status: Pending - -Signed-off-by: Wujian Sun ---- - src/egl/drivers/dri2/egl_dri2.c | 3 ++- - 1 file changed, 2 insertions(+), 1 deletion(-) - -diff --git a/src/egl/drivers/dri2/egl_dri2.c b/src/egl/drivers/dri2/egl_dri2.c -index 992f0e3d46d..6ee209d4b47 100644 ---- a/src/egl/drivers/dri2/egl_dri2.c -+++ b/src/egl/drivers/dri2/egl_dri2.c -@@ -942,7 +942,8 @@ dri2_setup_screen(_EGLDisplay *disp) - - #ifdef HAVE_LIBDRM - if (dri2_dpy->image->base.version >= 8 && -- dri2_dpy->image->createImageFromDmaBufs) { -+ dri2_dpy->image->createImageFromDmaBufs && -+ strcmp("softpipe", pscreen->get_name(pscreen))) { - disp->Extensions.EXT_image_dma_buf_import = EGL_TRUE; - disp->Extensions.EXT_image_dma_buf_import_modifiers = EGL_TRUE; - } --- -2.17.1 -