diff --git a/arch/chromium-fourier/KWIN_PIVOT.md b/arch/chromium-fourier/KWIN_PIVOT.md index c7fccedbb..55731a64c 100644 --- a/arch/chromium-fourier/KWIN_PIVOT.md +++ b/arch/chromium-fourier/KWIN_PIVOT.md @@ -1,5 +1,25 @@ # KWin pivot — fix the chrome-on-KWin video stall +> **2026-04-28 update part 3 — campaign closed end-to-end.** Three +> patches landed on ohm in sequence: qt6-base-fourier (GL_ALPHA → +> GL_R8), kwin-fourier (watchDmaBuf no-op), chromium-fourier patch +> 4/4 (V4L2 capture pool floor at 16). Each unsticks one layer. +> Together they produce smooth 1080p30 H.264 playback under KDE +> Plasma 6.6.4 Wayland on the box where stock chromium previously +> stalled in 3 seconds. Combined chrome CPU ~81 % steady, KWin ~9 %, +> zero GL_INVALID_VALUE in the journal during playback. Brave's +> YouTube on the same session feels markedly snappier independently +> — kwin-fourier is a general-purpose latency reduction for every +> wp_linux_dmabuf client on this hardware, not a chrome-specific +> fix. **The kernel-side architectural hole — vb2 / hantro / rga not +> populating `dma_resv` exclusive fences for V4L2 producers — is the +> right upstream-correct fix and the planned next move.** kwin-fourier +> in its current shape (blanket bypass) is a working *diagnostic +> instrument*; the upstream MR will be the kernel-side per-driver +> patch (3 commits: vb2 helper API, hantro opt-in, rga opt-in) plus +> a parallel KWin commit using `poll(POLLIN)` directly on the dmabuf +> fd instead of the `EXPORT_SYNC_FILE`+`QSocketNotifier` roundtrip. + > **2026-04-28 update part 2 — qt6-base-fourier landed, validated, did > not fix the chrome stall.** The Qt 6 GL_ALPHA bug (qopengltextureglyphcache.cpp, > qrhigles2.cpp, qopengltextureuploader.cpp) is real, the patch is diff --git a/arch/qt6-base-fourier/patches/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch b/arch/qt6-base-fourier/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch similarity index 100% rename from arch/qt6-base-fourier/patches/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch rename to arch/qt6-base-fourier/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch diff --git a/arch/qt6-base-fourier/patches/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch b/arch/qt6-base-fourier/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch similarity index 100% rename from arch/qt6-base-fourier/patches/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch rename to arch/qt6-base-fourier/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch diff --git a/arch/qt6-base-fourier/patches/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch b/arch/qt6-base-fourier/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch similarity index 100% rename from arch/qt6-base-fourier/patches/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch rename to arch/qt6-base-fourier/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch diff --git a/arch/qt6-base-fourier/PKGBUILD b/arch/qt6-base-fourier/PKGBUILD index 2020c5ce9..cc676191f 100644 --- a/arch/qt6-base-fourier/PKGBUILD +++ b/arch/qt6-base-fourier/PKGBUILD @@ -110,11 +110,11 @@ optdepends=('freetds: MS SQL driver' groups=(qt6) _pkgfn=${pkgbase/6-/} source=(git+https://code.qt.io/qt/$_pkgfn#tag=v$_pkgver - patches/qt6-base-cflags.patch - patches/qt6-base-nostrip.patch - patches/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch - patches/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch - patches/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch) + qt6-base-cflags.patch + qt6-base-nostrip.patch + 0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch + 0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch + 0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch) sha256sums=('2223c075e95d86f8dbf6395b025a74d996c418f094453c903290e3c2663fbed2' '5411edbe215c24b30448fac69bd0ba7c882f545e8cf05027b2b6e2227abc5e78' '4b93f6a79039e676a56f9d6990a324a64a36f143916065973ded89adc621e094' @@ -123,20 +123,20 @@ sha256sums=('2223c075e95d86f8dbf6395b025a74d996c418f094453c903290e3c2663fbed2' 'SKIP') prepare() { - patch -d $_pkgfn -p1 < patches/qt6-base-cflags.patch # Use system CFLAGS - patch -d $_pkgfn -p1 < patches/qt6-base-nostrip.patch # Don't strip binaries with qmake + patch -d $_pkgfn -p1 < qt6-base-cflags.patch # Use system CFLAGS + patch -d $_pkgfn -p1 < qt6-base-nostrip.patch # Don't strip binaries with qmake # cherry-pick needs git author identity; git-cli refuses without it. git -C $_pkgfn -c user.email=fourier@build -c user.name='qt6-base-fourier build' \ cherry-pick -n 8b54513cdcf62047376a5d27d784ad68a8f235bf # Fix qdbus crashes # qt6-base-fourier — three small runtime-checks that pick GL_R8 over - # GL_ALPHA when the live GL context is ES 3 or newer. See patches/ - # for the per-site diagnosis. The chromium-fourier KWIN_PIVOT.md - # writeup carries the discovery thread. - patch -d $_pkgfn -p1 < patches/0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch - patch -d $_pkgfn -p1 < patches/0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch - patch -d $_pkgfn -p1 < patches/0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch + # GL_ALPHA when the live GL context is ES 3 or newer. See the + # individual patch headers for per-site diagnosis. The + # chromium-fourier KWIN_PIVOT.md writeup carries the discovery thread. + patch -d $_pkgfn -p1 < 0001-qopengltextureglyphcache-pick-GL_R8-on-ES3.patch + patch -d $_pkgfn -p1 < 0002-qrhigles2-RED_OR_ALPHA8-pick-GL_R8-on-ES3.patch + patch -d $_pkgfn -p1 < 0003-qopengltextureuploader-pick-GL_R8-on-ES3.patch } build() { @@ -165,6 +165,7 @@ build() { -DFEATURE_system_sqlite=ON \ -DFEATURE_system_xcb_xinput=ON \ -DFEATURE_no_direct_extern_access=$_no_direct_extern_access \ + -DFEATURE_sql_ibase=OFF \ -DCMAKE_INTERPROCEDURAL_OPTIMIZATION=ON \ -DCMAKE_MESSAGE_LOG_LEVEL=STATUS cmake --build build diff --git a/arch/qt6-base-fourier/patches/qt6-base-cflags.patch b/arch/qt6-base-fourier/qt6-base-cflags.patch similarity index 100% rename from arch/qt6-base-fourier/patches/qt6-base-cflags.patch rename to arch/qt6-base-fourier/qt6-base-cflags.patch diff --git a/arch/qt6-base-fourier/patches/qt6-base-nostrip.patch b/arch/qt6-base-fourier/qt6-base-nostrip.patch similarity index 100% rename from arch/qt6-base-fourier/patches/qt6-base-nostrip.patch rename to arch/qt6-base-fourier/qt6-base-nostrip.patch diff --git a/arch/vulkan-panfrost/PKGBUILD b/arch/vulkan-panfrost/PKGBUILD new file mode 100644 index 000000000..fbe649a42 --- /dev/null +++ b/arch/vulkan-panfrost/PKGBUILD @@ -0,0 +1,110 @@ +# Maintainer: Markus Fritsche +# +# vulkan-panfrost — Mesa's panvk Vulkan driver, packaged as a +# standalone ICD on Arch Linux ARM. Stock ALARM `mesa` does not build +# with -Dvulkan-drivers=panfrost, so panvk doesn't ship. +# +# Targets both Mali kernel drivers: +# - panfrost (Bifrost: Mali-G31 / G52 / G57) on RK3566 / RK3568 etc. +# - panthor (Valhall: Mali-G610+) on RK3588 / RK3588S etc. +# +# panvk on Mali-G52 r1 (Bifrost-gen2) currently returns +# VK_ERROR_INCOMPATIBLE_DRIVER on probe — that's an upstream mesa +# issue, not a packaging one. The driver lights up cleanly on +# Mali-G610 Valhall (RK3588) which is the immediate target. Install on +# Bifrost boards anyway; future mesa releases may unblock G52 r1 +# without re-packaging. + +pkgname=vulkan-panfrost +pkgver=26.0.5 +pkgrel=1 +epoch=1 +pkgdesc='Mesa Vulkan ICD for Mali Bifrost / Valhall (panvk)' +arch=('aarch64') +url='https://gitlab.freedesktop.org/mesa/mesa' +license=('MIT') +depends=( + vulkan-icd-loader + libdrm + zlib + zstd + expat + libelf + wayland +) +makedepends=( + meson + ninja + python-mako + glslang + libxrandr + libxshmfence + libxxf86vm + vulkan-headers + wayland-protocols + rust-bindgen + rust + llvm + llvm-libs + libclc + spirv-tools + spirv-llvm-translator +) +provides=('vulkan-driver') +options=('!lto') +source=("https://archive.mesa3d.org/mesa-${pkgver}.tar.xz") +sha256sums=('SKIP') + +build() { + cd "${srcdir}/mesa-${pkgver}" + + # Strip mesa down to just the panvk Vulkan driver — no Gallium + # drivers, no GL/GLES, no GLX, no EGL, no VAAPI/VDPAU. The host's + # stock `mesa` package keeps providing all of those; this PKGBUILD + # only adds the missing Vulkan ICD next to it. + # + # --auto-features=disabled means features have to be opt-in. Avoids + # mesa's default "enable everything we can find headers for" pulling + # in xlib-lease / gallium-va / etc. that we don't want here. + meson setup . build \ + --prefix=/usr \ + --libexecdir=lib \ + --sbindir=bin \ + --buildtype=release \ + --auto-features=disabled \ + --wrap-mode=nodownload \ + -Db_lto=false \ + -Db_pie=true \ + -Dvulkan-drivers=panfrost \ + -Dgallium-drivers= \ + -Dplatforms=wayland \ + -Dshared-glapi=disabled \ + -Dgallium-rusticl=false \ + -Dmicrosoft-clc=disabled \ + -Dvideo-codecs= \ + -Dllvm=enabled \ + -Dshared-llvm=enabled \ + -Dspirv-tools=enabled \ + -Dvulkan-icd-dir=/usr/share/vulkan/icd.d + + meson compile -C build +} + +package() { + cd "${srcdir}/mesa-${pkgver}" + + # Mesa's install rules drop a lot of files we don't want in this + # narrow package — stage to a temp dir, then cherry-pick. + DESTDIR="${srcdir}/staging" meson install -C build --no-rebuild + + # The ICD shared object + install -Dm755 "${srcdir}/staging/usr/lib/libvulkan_panfrost.so" \ + "${pkgdir}/usr/lib/libvulkan_panfrost.so" + + # The Vulkan loader manifest. Mesa installs it as + # `panfrost_icd..json` (the userspace driver name) — that + # filename is what the Vulkan loader expects, no need to rename. + install -dm755 "${pkgdir}/usr/share/vulkan/icd.d" + cp -av "${srcdir}/staging/usr/share/vulkan/icd.d/"panfrost_icd*.json \ + "${pkgdir}/usr/share/vulkan/icd.d/" +}