diff --git a/extra/libdrm/0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch b/extra/libdrm/0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch index 8e02b5ba3..4d56a635e 100644 --- a/extra/libdrm/0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch +++ b/extra/libdrm/0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch @@ -1,7 +1,7 @@ From 677cd97dc4a930af508388713f5016baf664ed18 Mon Sep 17 00:00:00 2001 From: Rob Herring Date: Fri, 21 Oct 2016 10:07:59 -0700 -Subject: [PATCH] Return an -ENODEV from drmGetDevice() when no device was +Subject: [PATCH 1/2] Return an -ENODEV from drmGetDevice() when no device was found. Fixes crashes in Mesa on platform devices, which expected *device to diff --git a/extra/libdrm/0002-Silence-runtime-complaints-on-platform-devices.patch b/extra/libdrm/0002-Silence-runtime-complaints-on-platform-devices.patch new file mode 100644 index 000000000..b30058155 --- /dev/null +++ b/extra/libdrm/0002-Silence-runtime-complaints-on-platform-devices.patch @@ -0,0 +1,38 @@ +From 2d8c01f256011c013edf3a76672d6ce9e2b05d8f Mon Sep 17 00:00:00 2001 +From: Eric Anholt +Date: Fri, 21 Oct 2016 10:09:47 -0700 +Subject: [PATCH 2/2] Silence runtime complaints on platform devices + +glxgears was spamming this 12 times at startup because of Mesa's +probing of the DRM device code, which doesn't support platform +devices. + +Signed-off-by: Eric Anholt +Reviewed-by: Alex Deucher +--- + xf86drm.c | 2 -- + 1 file changed, 2 deletions(-) + +diff --git a/xf86drm.c b/xf86drm.c +index 9b52889..52add5e 100644 +--- a/xf86drm.c ++++ b/xf86drm.c +@@ -3149,7 +3149,6 @@ int drmGetDevice(int fd, drmDevicePtr *device) + + break; + default: +- fprintf(stderr, "The subsystem type is not supported yet\n"); + continue; + } + +@@ -3259,7 +3258,6 @@ int drmGetDevices(drmDevicePtr devices[], int max_devices) + + break; + default: +- fprintf(stderr, "The subsystem type is not supported yet\n"); + continue; + } + +-- +2.10.2 + diff --git a/extra/libdrm/PKGBUILD b/extra/libdrm/PKGBUILD index 655703279..080a016ef 100644 --- a/extra/libdrm/PKGBUILD +++ b/extra/libdrm/PKGBUILD @@ -4,11 +4,11 @@ # ALARM: Kevin Mihelich # - enable omap, exynos, tegra, etnaviv for v7 # - drop valgrind makdepend for v5 and v6 -# - upstream patch to fix glamoregl segfault with Mesa 13.0 +# - upstream patches to fix glamoregl segfault with Mesa 13.0 pkgname=libdrm pkgver=2.4.71 -pkgrel=1.1 +pkgrel=1.2 pkgdesc="Userspace interface to kernel DRM services" arch=(i686 x86_64) license=('custom') @@ -21,10 +21,12 @@ replaces=('libdrm-new' 'libdrm-nouveau') url="http://dri.freedesktop.org/" source=(http://dri.freedesktop.org/$pkgname/$pkgname-$pkgver.tar.bz2{,.sig} 0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch + 0002-Silence-runtime-complaints-on-platform-devices.patch COPYING) sha256sums=('c66287ddeee5f46ea8f8880b94b80acb3bbc33ba6321d17767eef145046df9b8' 'SKIP' - '3b3bf1b68c8f8f8666a6e7ee31609dd255c8d6015561c90049d6510675764aad' + '2b35620c67771ef286106863076f7f544d7795d53368f51b757105865d82b88f' + 'bc6ef82d3a4a601590ea40dc644734cfc05aa6e74dbdb3401d98e966d7f45e48' '9631d4f694952e3e6ae5a05534c2e93e994e47d3413677a3a00e45c8cef6db93') validpgpkeys=('B97BD6A80CAC4981091AE547FE558C72A67013C3') # Maarten Lankhorst validpgpkeys+=('215DEE688925CCB965BE5DA97C03D7797B6E1AE2') # Damien Lespiau @@ -38,6 +40,7 @@ prepare() { cd $pkgname-$pkgver patch -p1 -i ../0001-Return-an-ENODEV-from-drmGetDevice-when-no-device-wa.patch + patch -p1 -i ../0002-Silence-runtime-complaints-on-platform-devices.patch # pthread is useless in Linux sed -i "/pthread-stubs/d" configure.ac