diff options
Diffstat (limited to 'drivers/gpu')
-rw-r--r-- | drivers/gpu/drm/radeon/radeon_object.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon/radeon_object.c index 06def70..a8d18bc 100644 --- a/drivers/gpu/drm/radeon/radeon_object.c +++ b/drivers/gpu/drm/radeon/radeon_object.c @@ -168,13 +168,15 @@ void radeon_bo_kunmap(struct radeon_bo *bo) void radeon_bo_unref(struct radeon_bo **bo) { struct ttm_buffer_object *tbo; + struct radeon_device *rdev; if ((*bo) == NULL) return; + rdev = (*bo)->rdev; tbo = &((*bo)->tbo); - mutex_lock(&(*bo)->rdev->vram_mutex); + mutex_lock(&rdev->vram_mutex); ttm_bo_unref(&tbo); - mutex_unlock(&(*bo)->rdev->vram_mutex); + mutex_unlock(&rdev->vram_mutex); if (tbo == NULL) *bo = NULL; } |