Update to 2.4.69 (RHBZ #1358549)
Signed-off-by: Igor Gnatenko <ignatenko@redhat.com>
This commit is contained in:
parent
3968b944ec
commit
16bb0de84f
@ -1,7 +1,7 @@
|
|||||||
diff -up libdrm-2.4.60/xf86drm.c.no-bc libdrm-2.4.60/xf86drm.c
|
diff -uNr libdrm-2.4.69.orig/xf86drm.c libdrm-2.4.69/xf86drm.c
|
||||||
--- libdrm-2.4.60/xf86drm.c.no-bc 2015-03-23 09:04:17.272458959 +1000
|
--- libdrm-2.4.69.orig/xf86drm.c 2016-07-20 20:42:39.000000000 +0200
|
||||||
+++ libdrm-2.4.60/xf86drm.c 2015-03-23 09:07:36.856720490 +1000
|
+++ libdrm-2.4.69/xf86drm.c 2016-07-21 08:00:10.411599806 +0200
|
||||||
@@ -482,11 +482,6 @@ int drmAvailable(void)
|
@@ -484,11 +484,6 @@
|
||||||
int fd;
|
int fd;
|
||||||
|
|
||||||
if ((fd = drmOpenMinor(0, 1, DRM_NODE_PRIMARY)) < 0) {
|
if ((fd = drmOpenMinor(0, 1, DRM_NODE_PRIMARY)) < 0) {
|
||||||
@ -13,7 +13,7 @@ diff -up libdrm-2.4.60/xf86drm.c.no-bc libdrm-2.4.60/xf86drm.c
|
|||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -659,38 +654,6 @@ static int drmOpenByName(const char *nam
|
@@ -661,38 +656,6 @@
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,94 +0,0 @@
|
|||||||
diff -up libdrm-2.4.0/libdrm/xf86drm.c.mknod libdrm-2.4.0/libdrm/xf86drm.c
|
|
||||||
--- libdrm-2.4.0/libdrm/xf86drm.c.mknod 2007-10-30 20:10:10.000000000 -0400
|
|
||||||
+++ libdrm-2.4.0/libdrm/xf86drm.c 2007-11-12 19:26:12.000000000 -0500
|
|
||||||
@@ -266,64 +266,12 @@ static int drmMatchBusID(const char *id1
|
|
||||||
*/
|
|
||||||
static int drmOpenDevice(long dev, int minor)
|
|
||||||
{
|
|
||||||
- stat_t st;
|
|
||||||
char buf[64];
|
|
||||||
int fd;
|
|
||||||
- mode_t devmode = DRM_DEV_MODE, serv_mode;
|
|
||||||
- int isroot = !geteuid();
|
|
||||||
- uid_t user = DRM_DEV_UID;
|
|
||||||
- gid_t group = DRM_DEV_GID, serv_group;
|
|
||||||
|
|
||||||
sprintf(buf, DRM_DEV_NAME, DRM_DIR_NAME, minor);
|
|
||||||
drmMsg("drmOpenDevice: node name is %s\n", buf);
|
|
||||||
|
|
||||||
- if (drm_server_info) {
|
|
||||||
- drm_server_info->get_perms(&serv_group, &serv_mode);
|
|
||||||
- devmode = serv_mode ? serv_mode : DRM_DEV_MODE;
|
|
||||||
- devmode &= ~(S_IXUSR|S_IXGRP|S_IXOTH);
|
|
||||||
- group = (serv_group >= 0) ? serv_group : DRM_DEV_GID;
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- if (stat(DRM_DIR_NAME, &st)) {
|
|
||||||
- if (!isroot)
|
|
||||||
- return DRM_ERR_NOT_ROOT;
|
|
||||||
- mkdir(DRM_DIR_NAME, DRM_DEV_DIRMODE);
|
|
||||||
- chown(DRM_DIR_NAME, 0, 0); /* root:root */
|
|
||||||
- chmod(DRM_DIR_NAME, DRM_DEV_DIRMODE);
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- /* Check if the device node exists and create it if necessary. */
|
|
||||||
- if (stat(buf, &st)) {
|
|
||||||
- if (!isroot)
|
|
||||||
- return DRM_ERR_NOT_ROOT;
|
|
||||||
- remove(buf);
|
|
||||||
- mknod(buf, S_IFCHR | devmode, dev);
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- if (drm_server_info) {
|
|
||||||
- chown(buf, user, group);
|
|
||||||
- chmod(buf, devmode);
|
|
||||||
- }
|
|
||||||
-
|
|
||||||
- fd = open(buf, O_RDWR, 0);
|
|
||||||
- drmMsg("drmOpenDevice: open result is %d, (%s)\n",
|
|
||||||
- fd, fd < 0 ? strerror(errno) : "OK");
|
|
||||||
- if (fd >= 0)
|
|
||||||
- return fd;
|
|
||||||
-
|
|
||||||
- /* Check if the device node is not what we expect it to be, and recreate it
|
|
||||||
- * and try again if so.
|
|
||||||
- */
|
|
||||||
- if (st.st_rdev != dev) {
|
|
||||||
- if (!isroot)
|
|
||||||
- return DRM_ERR_NOT_ROOT;
|
|
||||||
- remove(buf);
|
|
||||||
- mknod(buf, S_IFCHR | devmode, dev);
|
|
||||||
- if (drm_server_info) {
|
|
||||||
- chown(buf, user, group);
|
|
||||||
- chmod(buf, devmode);
|
|
||||||
- }
|
|
||||||
- }
|
|
||||||
fd = open(buf, O_RDWR, 0);
|
|
||||||
drmMsg("drmOpenDevice: open result is %d, (%s)\n",
|
|
||||||
fd, fd < 0 ? strerror(errno) : "OK");
|
|
||||||
@@ -331,7 +279,6 @@ static int drmOpenDevice(long dev, int m
|
|
||||||
return fd;
|
|
||||||
|
|
||||||
drmMsg("drmOpenDevice: Open failed\n");
|
|
||||||
- remove(buf);
|
|
||||||
return -errno;
|
|
||||||
}
|
|
||||||
|
|
||||||
diff -up libdrm-2.4.0/libdrm/xf86drm.h.mknod libdrm-2.4.0/libdrm/xf86drm.h
|
|
||||||
--- libdrm-2.4.0/libdrm/xf86drm.h.mknod 2007-07-19 00:27:52.000000000 -0400
|
|
||||||
+++ libdrm-2.4.0/libdrm/xf86drm.h 2007-11-12 19:27:51.000000000 -0500
|
|
||||||
@@ -39,14 +39,6 @@
|
|
||||||
#include <stdint.h>
|
|
||||||
#include <drm.h>
|
|
||||||
|
|
||||||
- /* Defaults, if nothing set in xf86config */
|
|
||||||
-#define DRM_DEV_UID 0
|
|
||||||
-#define DRM_DEV_GID 0
|
|
||||||
-/* Default /dev/dri directory permissions 0755 */
|
|
||||||
-#define DRM_DEV_DIRMODE \
|
|
||||||
- (S_IRUSR|S_IWUSR|S_IXUSR|S_IRGRP|S_IXGRP|S_IROTH|S_IXOTH)
|
|
||||||
-#define DRM_DEV_MODE (S_IRUSR|S_IWUSR|S_IRGRP|S_IWGRP)
|
|
||||||
-
|
|
||||||
#define DRM_DIR_NAME "/dev/dri"
|
|
||||||
#define DRM_DEV_NAME "%s/card%d"
|
|
||||||
#define DRM_PROC_NAME "/proc/dri/" /* For backward Linux compatibility */
|
|
@ -1,44 +0,0 @@
|
|||||||
From 891517f5111cd82909906d5e8ee0299db0d46762 Mon Sep 17 00:00:00 2001
|
|
||||||
From: Ben Skeggs <bskeggs@redhat.com>
|
|
||||||
Date: Mon, 7 Jan 2013 13:07:13 +1000
|
|
||||||
Subject: [PATCH] nouveau: disallow pushbuf BOs in multiple memory types
|
|
||||||
|
|
||||||
Under certain circumstances it's possible for libdrm to decide to move
|
|
||||||
a GART|VRAM pushbuf to be VRAM-only. This causes the kernel to reject
|
|
||||||
the command submission on GF8 and up, due to a stricter policy where
|
|
||||||
buffers are only allowed to move to memory types that were specified
|
|
||||||
at creation time.
|
|
||||||
|
|
||||||
The simplest fix for this is to force the creation-time memory type for
|
|
||||||
the lifetime of the push buffer.
|
|
||||||
|
|
||||||
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
|
|
||||||
---
|
|
||||||
nouveau/pushbuf.c | 8 ++++----
|
|
||||||
1 file changed, 4 insertions(+), 4 deletions(-)
|
|
||||||
|
|
||||||
diff --git a/nouveau/pushbuf.c b/nouveau/pushbuf.c
|
|
||||||
index 0e37ce3..ff8e125 100644
|
|
||||||
--- a/nouveau/pushbuf.c
|
|
||||||
+++ b/nouveau/pushbuf.c
|
|
||||||
@@ -574,13 +574,13 @@ nouveau_pushbuf_new(struct nouveau_client *client, struct nouveau_object *chan,
|
|
||||||
push->client = client;
|
|
||||||
push->channel = immediate ? chan : NULL;
|
|
||||||
push->flags = NOUVEAU_BO_RD;
|
|
||||||
- if (fifo->pushbuf & NOUVEAU_GEM_DOMAIN_VRAM) {
|
|
||||||
- push->flags |= NOUVEAU_BO_VRAM;
|
|
||||||
- nvpb->type = NOUVEAU_BO_VRAM;
|
|
||||||
- }
|
|
||||||
if (fifo->pushbuf & NOUVEAU_GEM_DOMAIN_GART) {
|
|
||||||
push->flags |= NOUVEAU_BO_GART;
|
|
||||||
nvpb->type = NOUVEAU_BO_GART;
|
|
||||||
+ } else
|
|
||||||
+ if (fifo->pushbuf & NOUVEAU_GEM_DOMAIN_VRAM) {
|
|
||||||
+ push->flags |= NOUVEAU_BO_VRAM;
|
|
||||||
+ nvpb->type = NOUVEAU_BO_VRAM;
|
|
||||||
}
|
|
||||||
nvpb->type |= NOUVEAU_BO_MAP;
|
|
||||||
|
|
||||||
--
|
|
||||||
1.8.0.1
|
|
||||||
|
|
@ -1,6 +1,6 @@
|
|||||||
Name: libdrm
|
Name: libdrm
|
||||||
Summary: Direct Rendering Manager runtime library
|
Summary: Direct Rendering Manager runtime library
|
||||||
Version: 2.4.68
|
Version: 2.4.69
|
||||||
Release: 1%{?dist}
|
Release: 1%{?dist}
|
||||||
License: MIT
|
License: MIT
|
||||||
|
|
||||||
@ -228,6 +228,9 @@ done
|
|||||||
%{_mandir}/man7/drm*.7*
|
%{_mandir}/man7/drm*.7*
|
||||||
|
|
||||||
%changelog
|
%changelog
|
||||||
|
* Thu Jul 21 2016 Igor Gnatenko <ignatenko@redhat.com> - 2.4.69-1
|
||||||
|
- Update to 2.4.69 (RHBZ #1358549)
|
||||||
|
|
||||||
* Thu Apr 28 2016 Igor Gnatenko <ignatenko@redhat.com> - 2.4.68-1
|
* Thu Apr 28 2016 Igor Gnatenko <ignatenko@redhat.com> - 2.4.68-1
|
||||||
- Update to 2.4.68
|
- Update to 2.4.68
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user