diff options
Diffstat (limited to 'drivers/gpu/drm/drm_gem.c')
-rw-r--r-- | drivers/gpu/drm/drm_gem.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/drm/drm_gem.c b/drivers/gpu/drm/drm_gem.c index 57ce27c9a74..74e4ff57801 100644 --- a/drivers/gpu/drm/drm_gem.c +++ b/drivers/gpu/drm/drm_gem.c | |||
@@ -499,11 +499,12 @@ EXPORT_SYMBOL(drm_gem_vm_open); | |||
499 | void drm_gem_vm_close(struct vm_area_struct *vma) | 499 | void drm_gem_vm_close(struct vm_area_struct *vma) |
500 | { | 500 | { |
501 | struct drm_gem_object *obj = vma->vm_private_data; | 501 | struct drm_gem_object *obj = vma->vm_private_data; |
502 | struct drm_device *dev = obj->dev; | ||
502 | 503 | ||
503 | mutex_lock(&obj->dev->struct_mutex); | 504 | mutex_lock(&dev->struct_mutex); |
504 | drm_vm_close_locked(vma); | 505 | drm_vm_close_locked(vma); |
505 | drm_gem_object_unreference(obj); | 506 | drm_gem_object_unreference(obj); |
506 | mutex_unlock(&obj->dev->struct_mutex); | 507 | mutex_unlock(&dev->struct_mutex); |
507 | } | 508 | } |
508 | EXPORT_SYMBOL(drm_gem_vm_close); | 509 | EXPORT_SYMBOL(drm_gem_vm_close); |
509 | 510 | ||