Bug#1151024: libegl-nvidia0: 550.163.01 DRM_FORMAT_NV12 EGL DMA-BUF import silently drops UV plane (green video in Chrome on Wayland)
Raul E Rangel
rrangel at chromium.org
Fri Oct 16 16:02:39 BST 2026
Follow-up verification update for Debian Bug #1151024:
We applied the 4-entry binary patch to `/usr/lib/x86_64-linux-gnu/nvidia/current/libEGL_nvidia.so.550.163.01`
and verified it in Google Chrome (`155.0.8059.79-1`) running natively on
Wayland (`--ozone-platform=wayland --render-node-override=/dev/dri/renderD128`
with hardware zero-copy `NV12` `NativePixmap` DMA-BUFs enabled, 55 active
`/dmabuf:` FDs in the GPU process):
* Both Google Meet (WebRTC camera & remote participant streams) and YouTube
video playback now render with completely normal, accurate colors (the
bright green tint is 100% resolved).
* `journalctl` and `dmesg` show zero EGL/GL binding errors or kernel warnings.
For anyone affected on `550.163.01` (or for packaging/testing reference),
here is the idempotent patch script we used to patch `libEGL_nvidia.so.550.163.01`:
```bash
#!/bin/bash
set -euo pipefail
TARGET="/usr/lib/x86_64-linux-gnu/nvidia/current/libEGL_nvidia.so.550.163.01"
BACKUP="${TARGET}.bak"
if [ ! -f "$BACKUP" ]; then
cp -p "$TARGET" "$BACKUP"
fi
python3 - "$TARGET" << 'PYEOF'
import os
import shutil
import struct
import sys
target = sys.argv[1]
tmp_target = target + ".new"
shutil.copy2(target, tmp_target)
with open(tmp_target, "r+b") as f:
# Verify expected FourCCs and patch Plane 1 format in NV12, NV21, NV16, NV24
patches = [
(0xd4b80, b"NV12", 0xd4b98, 0x10180e10, 0x10880710),
(0xd4bb8, b"NV21", 0xd4bd0, 0x10880e10, 0x10180710),
(0xd4bf0, b"NV16", 0xd4c08, 0x10180e10, 0x10880710),
(0xd4c28, b"NV24", 0xd4c40, 0x10180e10, 0x10880710),
]
for entry_off, fourcc, fmt_off, old_val, new_val in patches:
f.seek(entry_off)
actual_fourcc = f.read(4)
if actual_fourcc != fourcc:
raise RuntimeError(f"Unexpected FourCC at {hex(entry_off)}: {actual_fourcc!r} != {fourcc!r}")
f.seek(fmt_off)
cur_val = struct.unpack("<I", f.read(4))[0]
if cur_val == old_val:
f.seek(fmt_off)
f.write(struct.pack("<I", new_val))
print(f"Patched {fourcc.decode()} Plane 1 fmt at {hex(fmt_off)}: {hex(old_val)} -> {hex(new_val)}")
elif cur_val == new_val:
print(f"{fourcc.decode()} Plane 1 fmt at {hex(fmt_off)} already patched ({hex(new_val)})")
else:
raise RuntimeError(f"Unexpected value at {hex(fmt_off)}: {hex(cur_val)}")
os.chmod(tmp_target, 0o644)
os.replace(tmp_target, target)
PYEOF
```
Thanks,
Raul E Rangel <rrangel at google.com>
More information about the pkg-nvidia-devel
mailing list