]> asedeno.scripts.mit.edu Git - linux.git/commitdiff
drm/ttm: remove set but not used variable 'bdev'
authorYueHaibing <yuehaibing@huawei.com>
Mon, 18 Feb 2019 13:59:35 +0000 (13:59 +0000)
committerAlex Deucher <alexander.deucher@amd.com>
Tue, 19 Mar 2019 20:03:53 +0000 (15:03 -0500)
Fixes gcc '-Wunused-but-set-variable' warning:

drivers/gpu/drm/ttm/ttm_execbuf_util.c: In function 'ttm_eu_fence_buffer_objects':
drivers/gpu/drm/ttm/ttm_execbuf_util.c:191:24: warning:
 variable 'bdev' set but not used [-Wunused-but-set-variable]

It's not used any more and can be removed.

Signed-off-by: YueHaibing <yuehaibing@huawei.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/ttm/ttm_execbuf_util.c

index 93860346c42600b455a3f4db1394cc43cc74ae11..0075eb9a0b52f6f22f2c98d8aa739030d195b4f1 100644 (file)
@@ -188,13 +188,11 @@ void ttm_eu_fence_buffer_objects(struct ww_acquire_ctx *ticket,
        struct ttm_validate_buffer *entry;
        struct ttm_buffer_object *bo;
        struct ttm_bo_global *glob;
-       struct ttm_bo_device *bdev;
 
        if (list_empty(list))
                return;
 
        bo = list_first_entry(list, struct ttm_validate_buffer, head)->bo;
-       bdev = bo->bdev;
        glob = bo->bdev->glob;
 
        spin_lock(&glob->lru_lock);