drm/radeon: only warn once in radeon_ttm_bo_destroy if va list not empty
authorJulien Isorce <julien.isorce@gmail.com>
Thu, 27 Apr 2017 14:10:08 +0000 (15:10 +0100)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 10 May 2017 15:23:08 +0000 (11:23 -0400)
Encountered a dozen of exact same backtraces when mesa's
pb_cache_release_all_buffers is called after that a gpu reset failed.

v2: Remove superfluous error message added in v1.

bug: https://bugs.freedesktop.org/show_bug.cgi?id=96271

Signed-off-by: Julien Isorce <jisorce@oblong.com>
Reviewed-by: Christian König <christian.koenig@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/radeon/radeon_object.c

index bec2ec056de43d30f27e0c9c218036f7d324372c..8b722297a05c7f5c3d958285664e3c37c398eb7a 100644 (file)
@@ -81,7 +81,7 @@ static void radeon_ttm_bo_destroy(struct ttm_buffer_object *tbo)
        list_del_init(&bo->list);
        mutex_unlock(&bo->rdev->gem.mutex);
        radeon_bo_clear_surface_reg(bo);
-       WARN_ON(!list_empty(&bo->va));
+       WARN_ON_ONCE(!list_empty(&bo->va));
        drm_gem_object_release(&bo->gem_base);
        kfree(bo);
 }