Hello community,

here is the log from the commit of package xorg-x11-server for openSUSE:Factory 
checked in at 2014-08-11 10:06:54
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/xorg-x11-server (Old)
 and      /work/SRC/openSUSE:Factory/.xorg-x11-server.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "xorg-x11-server"

Changes:
--------
--- /work/SRC/openSUSE:Factory/xorg-x11-server/xorg-x11-server.changes  
2014-08-06 15:31:47.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.xorg-x11-server.new/xorg-x11-server.changes     
2014-08-11 10:06:55.000000000 +0200
@@ -1,0 +2,8 @@
+Thu Aug  7 14:50:55 CEST 2014 - [email protected]
+
+- Fix corrupted graphics with 24bpp on cirrus KMS (bnc#890599)
+  two patches added:
+  
U_render-Don-t-generate-invalid-pixman-format-when-using-a-24bpp-framebuffer-with-a-32bit-depth-visual.patch
+  
U_fb-Correctly-implement-CopyArea-when-using-a-window-with-depth-32-and-24bpp.patch
+
+-------------------------------------------------------------------

New:
----
  
U_fb-Correctly-implement-CopyArea-when-using-a-window-with-depth-32-and-24bpp.patch
  
U_render-Don-t-generate-invalid-pixman-format-when-using-a-24bpp-framebuffer-with-a-32bit-depth-visual.patch

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ xorg-x11-server.spec ++++++
--- /var/tmp/diff_new_pack.Gbtj9Z/_old  2014-08-11 10:06:56.000000000 +0200
+++ /var/tmp/diff_new_pack.Gbtj9Z/_new  2014-08-11 10:06:56.000000000 +0200
@@ -152,6 +152,8 @@
 Patch111:       u_CloseConsole-Don-t-report-FatalError-when-shutting-down.patch
 Patch112:       
u_render-Cast-color-masks-to-unsigned-long-before-shifting-them.patch
 Patch130:       
U_BellProc-Send-bell-event-on-core-protocol-bell-when-requested.patch
+Patch131:       
U_render-Don-t-generate-invalid-pixman-format-when-using-a-24bpp-framebuffer-with-a-32bit-depth-visual.patch
+Patch132:       
U_fb-Correctly-implement-CopyArea-when-using-a-window-with-depth-32-and-24bpp.patch
 
 Patch1000:      n_xserver-optimus-autoconfig-hack.patch
 
@@ -231,6 +233,8 @@
 %patch111 -p1
 %patch112 -p1
 %patch130 -p1
+%patch131 -p1
+%patch132 -p1
 %patch1000 -p1
 
 ### disabled for now

++++++ 
U_fb-Correctly-implement-CopyArea-when-using-a-window-with-depth-32-and-24bpp.patch
 ++++++
>From patchwork Fri Jun  6 11:52:13 2014
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: fb: Correctly implement CopyArea when using a window with depth 32
 and 24bpp.
From: Robert Ancell <[email protected]>
X-Patchwork-Id: 27263
Message-Id: <[email protected]>
To: [email protected]
Cc: Robert Ancell <[email protected]>
Date: Fri,  6 Jun 2014 23:52:13 +1200

When using the fb backend at 24bpp it allows a visual with 32 bit depth.
When using CopyArea from a 32bpp pixmap to a window with a 32 bit depth it would
read the ARGB as RGB.

Fix is to correctly ignore the alpha channel in the pixmap when copying.

---
fb/fbcopy.c | 10 +++++++++-
 fb/fbcopy.c |   10 +++++++++-
 1 file changed, 9 insertions(+), 1 deletion(-)

--- a/fb/fbcopy.c
+++ b/fb/fbcopy.c
@@ -242,8 +242,16 @@ fbCopyArea(DrawablePtr pSrcDrawable,
            int xIn, int yIn, int widthSrc, int heightSrc, int xOut, int yOut)
 {
     miCopyProc copy;
+    int src_bpp, dst_bpp;
 
-    if (pSrcDrawable->bitsPerPixel != pDstDrawable->bitsPerPixel)
+    src_bpp = pSrcDrawable->bitsPerPixel;
+    if (src_bpp < pSrcDrawable->depth)
+        src_bpp = BitsPerPixel (pSrcDrawable->depth);
+    dst_bpp = pDstDrawable->bitsPerPixel;
+    if (dst_bpp < pDstDrawable->depth)
+        dst_bpp = BitsPerPixel (pDstDrawable->depth);
+
+    if (src_bpp != dst_bpp)
         copy = fb24_32CopyMtoN;
     else
         copy = fbCopyNtoN;
++++++ 
U_render-Don-t-generate-invalid-pixman-format-when-using-a-24bpp-framebuffer-with-a-32bit-depth-visual.patch
 ++++++
>From patchwork Fri Jun  6 04:36:59 2014
Content-Type: text/plain; charset="utf-8"
MIME-Version: 1.0
Content-Transfer-Encoding: 7bit
Subject: render: Don't generate invalid pixman format when using a 24bpp
 framebuffer with a 32bit depth visual.
From: Robert Ancell <[email protected]>
X-Patchwork-Id: 27240
Message-Id: <[email protected]>
To: [email protected]
Cc: Robert Ancell <[email protected]>
Date: Fri,  6 Jun 2014 16:36:59 +1200

When using the fb backend at 24bpp it allows a visual with 32 bit depth.
This would cause RENDER to try and create an invalid pixman buffer and hit the
following assertion when trying to render to it:

---
 render/picture.c |    6 +++++-
 1 file changed, 5 insertions(+), 1 deletion(-)

--- a/render/picture.c
+++ b/render/picture.c
@@ -762,6 +762,7 @@ CreatePicture(Picture pid,
 {
     PicturePtr pPicture;
     PictureScreenPtr ps = GetPictureScreen(pDrawable->pScreen);
+    int bpp;
 
     pPicture = dixAllocateScreenObjectWithPrivates(pDrawable->pScreen,
                                                    PictureRec, 
PRIVATE_PICTURE);
@@ -773,7 +774,10 @@ CreatePicture(Picture pid,
     pPicture->id = pid;
     pPicture->pDrawable = pDrawable;
     pPicture->pFormat = pFormat;
-    pPicture->format = pFormat->format | (pDrawable->bitsPerPixel << 24);
+    bpp = pDrawable->bitsPerPixel;
+    if (bpp < pFormat->depth)
+        bpp = BitsPerPixel (pFormat->depth);
+    pPicture->format = pFormat->format | (bpp << 24);
 
     /* security creation/labeling check */
     *error = XaceHook(XACE_RESOURCE_ACCESS, client, pid, PictureType, pPicture,
-- 
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to