aboutsummaryrefslogtreecommitdiff
path: root/backend
diff options
context:
space:
mode:
authorSimon Ser <contact@emersion.fr>2021-04-06 15:02:57 +0200
committerSimon Ser <contact@emersion.fr>2021-04-06 15:02:57 +0200
commit6bfbf356181a78a39d04c9c0f4a182b0529394c8 (patch)
tree389dfa4c0da4ceda6e3622cc79739dfccf7987bd /backend
parent1ec97bdf4fea9ae1c9cd4d4589d15cb45d9bfb84 (diff)
backend/drm: reject DMA-BUFs with flags
We cannot scan-out DMA-BUFs with any flag right now.
Diffstat (limited to 'backend')
-rw-r--r--backend/drm/renderer.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/backend/drm/renderer.c b/backend/drm/renderer.c
index 2e9c825c..208b8621 100644
--- a/backend/drm/renderer.c
+++ b/backend/drm/renderer.c
@@ -383,6 +383,12 @@ static struct wlr_drm_fb *drm_fb_create(struct wlr_drm_backend *drm,
goto error_get_dmabuf;
}
+ if (attribs.flags != 0) {
+ wlr_log(WLR_DEBUG, "Buffer with DMA-BUF flags 0x%"PRIX32" cannot be "
+ "scanned out", attribs.flags);
+ goto error_get_dmabuf;
+ }
+
if (formats && !wlr_drm_format_set_has(formats, attribs.format,
attribs.modifier)) {
// The format isn't supported by the plane. Try stripping the alpha