diff options
-rw-r--r-- | linux-core/drmP.h | 1 | ||||
-rw-r--r-- | linux-core/drm_context.c | 3 | ||||
-rw-r--r-- | linux-core/drm_fops.c | 13 |
3 files changed, 7 insertions, 10 deletions
diff --git a/linux-core/drmP.h b/linux-core/drmP.h index c2c3cdde..f96e6bee 100644 --- a/linux-core/drmP.h +++ b/linux-core/drmP.h @@ -415,7 +415,6 @@ struct drm_file { unsigned long ioctl_count; struct list_head lhead; struct drm_minor *minor; - int remove_auth_on_close; unsigned long lock_count; /* diff --git a/linux-core/drm_context.c b/linux-core/drm_context.c index febee9f7..f3d69ff7 100644 --- a/linux-core/drm_context.c +++ b/linux-core/drm_context.c @@ -444,9 +444,6 @@ int drm_rmctx(struct drm_device *dev, void *data, struct drm_ctx *ctx = data; DRM_DEBUG("%d\n", ctx->handle); - if (ctx->handle == DRM_KERNEL_CONTEXT + 1) { - file_priv->remove_auth_on_close = 1; - } if (ctx->handle != DRM_KERNEL_CONTEXT) { if (dev->driver->context_dtor) dev->driver->context_dtor(dev, ctx->handle); diff --git a/linux-core/drm_fops.c b/linux-core/drm_fops.c index d5c59b19..043552fd 100644 --- a/linux-core/drm_fops.c +++ b/linux-core/drm_fops.c @@ -489,6 +489,13 @@ int drm_release(struct inode *inode, struct file *filp) drm_fb_release(filp); if (file_priv->is_master) { + struct drm_file *temp; + list_for_each_entry(temp, &dev->filelist, lhead) { + if ((temp->master == file_priv->master) && + (temp != file_priv)) + temp->authenticated = 0; + } + if (file_priv->minor->master == file_priv->master) file_priv->minor->master = NULL; drm_put_master(file_priv->master); @@ -499,15 +506,9 @@ int drm_release(struct inode *inode, struct file *filp) mutex_lock(&dev->struct_mutex); drm_object_release(filp); - if (file_priv->remove_auth_on_close == 1) { - struct drm_file *temp; - list_for_each_entry(temp, &dev->filelist, lhead) - temp->authenticated = 0; - } list_del(&file_priv->lhead); - mutex_unlock(&dev->struct_mutex); if (dev->driver->postclose) |