Date: Monday, February 16, 2015 @ 23:00:07
  Author: lcarlier
Revision: 231625

upgpkg: xf86-video-intel 2.99.917-3

fix FS#43840

Added:
  xf86-video-intel/trunk/git-fixes.patch
Modified:
  xf86-video-intel/trunk/PKGBUILD

-----------------+
 PKGBUILD        |   14 +++++++--
 git-fixes.patch |   82 ++++++++++++++++++++++++++++++++++++++++++++++++++++++
 2 files changed, 93 insertions(+), 3 deletions(-)

Modified: PKGBUILD
===================================================================
--- PKGBUILD    2015-02-16 20:53:57 UTC (rev 231624)
+++ PKGBUILD    2015-02-16 22:00:07 UTC (rev 231625)
@@ -4,7 +4,7 @@
 
 pkgname=xf86-video-intel
 pkgver=2.99.917
-pkgrel=2
+pkgrel=3
 arch=(i686 x86_64)
 url="http://xorg.freedesktop.org/";
 license=('custom')
@@ -23,9 +23,17 @@
 conflicts=('xorg-server<1.16' 'X-ABI-VIDEODRV_VERSION<19' 
'X-ABI-VIDEODRV_VERSION>=20'
            'xf86-video-intel-sna' 'xf86-video-intel-uxa' 'xf86-video-i810' 
'xf86-video-intel-legacy')
 groups=('xorg-drivers' 'xorg')
-source=(${url}/archive/individual/driver/${pkgname}-${pkgver}.tar.bz2)
-sha256sums=('00b781eea055582820a123c47b62411bdf6aabf4f03dc0568faec55faf9667c9')
+source=(${url}/archive/individual/driver/${pkgname}-${pkgver}.tar.bz2
+        git-fixes.patch)
+sha256sums=('00b781eea055582820a123c47b62411bdf6aabf4f03dc0568faec55faf9667c9'
+            '201f60bc75d61dd95ae7bc166ef2cb153fe693471b42952e6d61cc0780a51e2e')
 
+prepare() {
+  cd ${pkgname}-${pkgver}
+  # fix FS#43840
+  patch -Np1 -i ../git-fixes.patch
+}
+
 build() {
   cd ${pkgname}-${pkgver}
   ./configure --prefix=/usr --libexecdir=/usr/lib

Added: git-fixes.patch
===================================================================
--- git-fixes.patch                             (rev 0)
+++ git-fixes.patch     2015-02-16 22:00:07 UTC (rev 231625)
@@ -0,0 +1,82 @@
+From 127aae5a72a69df325fed0b63d345e81583d5ca1 Mon Sep 17 00:00:00 2001
+From: Chris Wilson <ch...@chris-wilson.co.uk>
+Date: Mon, 16 Feb 2015 21:37:35 +0000
+Subject: tools/intel-virtual-output: Check for DRI3 more carefully
+
+Using xcb, we cannot simply call xcb_dri3_query_version() without it
+terminating the connection if DRI3 is not enabled on the target display.
+Oops.
+
+Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=89172
+Signed-off-by: Chris Wilson <ch...@chris-wilson.co.uk>
+
+diff --git a/tools/virtual.c b/tools/virtual.c
+index 8e2b4a2..3bcd057 100644
+--- a/tools/virtual.c
++++ b/tools/virtual.c
+@@ -218,6 +218,13 @@ static inline XRRScreenResources 
*_XRRGetScreenResourcesCurrent(Display *dpy, Wi
+ static int _x_error_occurred;
+ 
+ static int
++_io_error_handler(Display *display)
++{
++      fprintf(stderr, "XIO error on display %s\n", DisplayString(display));
++      abort();
++}
++
++static int
+ _check_error_handler(Display     *display,
+                    XErrorEvent *event)
+ {
+@@ -320,6 +327,7 @@ can_use_shm(Display *dpy,
+ #include <X11/Xlib-xcb.h>
+ #include <X11/xshmfence.h>
+ #include <xcb/xcb.h>
++#include <xcb/xcbext.h>
+ #include <xcb/dri3.h>
+ #include <xcb/sync.h>
+ static Pixmap dri3_create_pixmap(Display *dpy,
+@@ -357,6 +365,7 @@ static int dri3_query_version(Display *dpy, int *major, 
int *minor)
+ {
+       xcb_connection_t *c = XGetXCBConnection(dpy);
+       xcb_dri3_query_version_reply_t *reply;
++      xcb_generic_error_t *error;
+ 
+       *major = *minor = -1;
+ 
+@@ -364,7 +373,8 @@ static int dri3_query_version(Display *dpy, int *major, 
int *minor)
+                                            xcb_dri3_query_version(c,
+                                                                   
XCB_DRI3_MAJOR_VERSION,
+                                                                   
XCB_DRI3_MINOR_VERSION),
+-                                           NULL);
++                                           &error);
++      free(error);
+       if (reply == NULL)
+               return -1;
+ 
+@@ -377,8 +387,14 @@ static int dri3_query_version(Display *dpy, int *major, 
int *minor)
+ 
+ static int dri3_exists(Display *dpy)
+ {
++      xcb_extension_t dri3 = { "DRI3", 0 };
++      const xcb_query_extension_reply_t *ext;
+       int major, minor;
+ 
++      ext = xcb_get_extension_data(XGetXCBConnection(dpy), &dri3);
++      if (ext == NULL || !ext->present)
++              return 0;
++
+       if (dri3_query_version(dpy, &major, &minor) < 0)
+               return 0;
+ 
+@@ -3228,6 +3244,7 @@ int main(int argc, char **argv)
+               return -ret;
+ 
+       XSetErrorHandler(_check_error_handler);
++      XSetIOErrorHandler(_io_error_handler);
+ 
+       ret = add_fd(&ctx, display_open(&ctx, src_name));
+       if (ret) {
+-- 
+cgit v0.10.2
+

Reply via email to