egl-platform-mir.patch: Incorrect (backwards) pixel formats are accepted

Bug #1473901 reported by Daniel van Vugt
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
mesa (Ubuntu)
Fix Released
Undecided
Unassigned

Bug Description

egl-platform-mir.patch: Incorrect (backwards) pixel formats are accepted.

I noticed this recently. GBM reports some pixel formats as supported but if you use them the colours come out backwards. Turns out it's just our patch reporting incorrect format support ...

--- a/src/gbm/backends/dri/gbm_dri.c
+++ b/src/gbm/backends/dri/gbm_dri.c

@@ -528,9 +528,11 @@ gbm_dri_is_format_supported(struct gbm_d
    switch (format) {
    case GBM_BO_FORMAT_XRGB8888:
    case GBM_FORMAT_XRGB8888:
+ case GBM_FORMAT_XBGR8888: <-------- Wrong. Delete this.
       break;
    case GBM_BO_FORMAT_ARGB8888:
    case GBM_FORMAT_ARGB8888:
+ case GBM_FORMAT_ABGR8888: <--------- Wrong. Delete this
       if (usage & GBM_BO_USE_SCANOUT)
          return 0;
       break;

Related branches

description: updated
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

Linked a loosely related branch, where the bug was first observed.

tags: added: mir-mesa
tags: added: egl-platform-mir
removed: mir-mesa
Revision history for this message
Daniel van Vugt (vanvugt) wrote :

UPDATE:

Starting in Mesa 12.x, GBM_FORMAT_XBGR8888 is supported. So we only need to remove GBM_FORMAT_ABGR8888 to solve this bug.

https://cgit.freedesktop.org/mesa/mesa/tree/src/gbm/backends/dri/gbm_dri.c?h=12.0#n542

Revision history for this message
Timo Aaltonen (tjaalton) wrote :

upstream enabled support for XBGR8888, but I'll drop the other one from the patch

Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package mesa - 12.0.1-3ubuntu2

---------------
mesa (12.0.1-3ubuntu2) yakkety; urgency=medium

  * debian/rules: Work around gcc ICE on ppc64el by forcing -O2.

 -- Adam Conrad <email address hidden> Fri, 22 Jul 2016 16:46:48 -0600

Changed in mesa (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.