projects
/
platform
/
kernel
/
linux-rpi.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
6b00842
)
drm: check for minor master before allowing drop master.
author
Dave Airlie
<airlied@redhat.com>
Sun, 19 Apr 2009 23:32:50 +0000
(09:32 +1000)
committer
Dave Airlie
<airlied@redhat.com>
Mon, 20 Apr 2009 00:04:28 +0000
(10:04 +1000)
When fast user switching a lot eventually we get to the point,
where we were checking for the wrong thing in this function.
Signed-off-by: Dave Airlie <airlied@redhat.com>
drivers/gpu/drm/drm_stub.c
patch
|
blob
|
history
diff --git
a/drivers/gpu/drm/drm_stub.c
b/drivers/gpu/drm/drm_stub.c
index 1b3e0ff57b45392df76051d4a7cf260280a9aace..ef878615c49f65d33c47f2bb6397eb0e34d6cd3b 100644
(file)
--- a/
drivers/gpu/drm/drm_stub.c
+++ b/
drivers/gpu/drm/drm_stub.c
@@
-185,6
+185,9
@@
int drm_dropmaster_ioctl(struct drm_device *dev, void *data,
if (!file_priv->is_master)
return -EINVAL;
+ if (!file_priv->minor->master)
+ return -EINVAL;
+
mutex_lock(&dev->struct_mutex);
drm_master_put(&file_priv->minor->master);
file_priv->is_master = 0;