fixup libdrm patch

This commit is contained in:
Dave Airlie 2020-11-04 13:42:30 +10:00
parent 7752a6cda7
commit f9254acf93

View File

@ -1,7 +1,7 @@
diff -uNr libdrm-2.4.69.orig/xf86drm.c libdrm-2.4.69/xf86drm.c
--- libdrm-2.4.69.orig/xf86drm.c 2016-07-20 20:42:39.000000000 +0200
+++ libdrm-2.4.69/xf86drm.c 2016-07-21 08:00:10.411599806 +0200
@@ -484,11 +484,6 @@
diff -up libdrm-2.4.103/xf86drm.c.dma libdrm-2.4.103/xf86drm.c
--- libdrm-2.4.103/xf86drm.c.dma 2020-11-04 13:24:14.000000000 +1000
+++ libdrm-2.4.103/xf86drm.c 2020-11-04 13:42:04.190975193 +1000
@@ -507,11 +507,6 @@ drm_public int drmAvailable(void)
int fd;
if ((fd = drmOpenMinor(0, 1, DRM_NODE_PRIMARY)) < 0) {
@ -13,7 +13,7 @@ diff -uNr libdrm-2.4.69.orig/xf86drm.c libdrm-2.4.69/xf86drm.c
return 0;
}
@@ -661,38 +656,6 @@
@@ -704,38 +699,6 @@ static int drmOpenByName(const char *nam
}
}
@ -25,7 +25,7 @@ diff -uNr libdrm-2.4.69.orig/xf86drm.c libdrm-2.4.69/xf86drm.c
- int retcode;
-
- sprintf(proc_name, "/proc/dri/%d/name", i);
- if ((fd = open(proc_name, 0, 0)) >= 0) {
- if ((fd = open(proc_name, O_RDONLY, 0)) >= 0) {
- retcode = read(fd, buf, sizeof(buf)-1);
- close(fd);
- if (retcode) {