wlroots/backend/drm
Simon Ser bdc75d058b backend/drm: check buffer format for multi-GPU
Fixes on-screen corruption when displaying a fullscreen client
with an implicit modifier on the secondary GPU.

What happens here:

- Client allocates a buffer with an INVALID modifier on primary GPU.
- Compositor attempts to scan-out this buffer on an output connected
  to secondary GPU.
- Buffer is imported to secondary GPU, and is interpreted as if it had
  the secondary GPU's implicit tiling, even though it has the primary
  GPU's implicit tiling.

We need to forbid cross-device imports with implicit modifiers.
The mgpu_formats list is stripped from any INVALID modifier so
checking that fixes the bug.

Using the mgpu_formats list has an additional benefit: the buffer
is rejected in the test commit if it doesn't have a format supported
by the multi-GPU renderer.

Requires this Mesa bugfix:
https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/31725

(cherry picked from commit c6dd5e3c2e)
2024-11-29 08:42:21 -05:00
..
atomic.c backend/drm: check whether clipped damage is empty 2024-11-11 14:11:06 -05:00
backend.c backend/drm: Free drm device name on error 2024-04-30 10:18:05 +02:00
drm.c backend/drm: check buffer format for multi-GPU 2024-11-29 08:42:21 -05:00
fb.c backend/drm: add drm_fb_copy() 2024-03-04 11:25:33 +01:00
gen_pnpids.sh backend/drm: use libdisplay-info to parse EDID 2023-02-28 14:44:02 +00:00
legacy.c backend/drm: Use cached vrr support flag 2024-06-21 14:18:34 +00:00
libliftoff.c backend/drm: avoid "maybe uninitialized" warning 2024-06-05 01:07:24 +03:00
meson.build add an option to enable/disable libliftoff 2024-06-05 22:33:05 -06:00
monitor.c backend/drm: drop wl_display argument 2024-01-25 15:05:36 +00:00
properties.c backend/drm: add support for SIZE_HINTS property 2024-07-10 22:42:44 +00:00
renderer.c allocator: remove backend parameter in allocator_autocreate_with_drm_fd 2024-02-02 16:36:31 -05:00
util.c backend/drm: use CRTCs in-order 2024-08-23 09:30:33 -04:00