[PATCH] drm/radeon: only warn once in radeon_ttm_bo_destroy if va list not empty
Julien Isorce
julien.isorce at gmail.com
Thu Apr 27 10:58:39 UTC 2017
But always print an error.
Encountered a dozen of exact same backtraces when mesa's
pb_cache_release_all_buffers is called after that a gpu reset failed.
An other approach would be to check rdev->vm_manager.enabled instead
of rdev->accel_working in the other function radeon_gem_object_close.
But it will only work if the vm_manager succeeded to be re-enabled
after a gpu reset.
bug: https://bugs.freedesktop.org/show_bug.cgi?id=96271
Signed-off-by: Julien Isorce <jisorce at oblong.com>
---
drivers/gpu/drm/radeon/radeon_object.c | 8 +++++++-
1 file changed, 7 insertions(+), 1 deletion(-)
diff --git a/drivers/gpu/drm/radeon/radeon_object.c b/drivers/gpu/drm/radeon/radeon_object.c
index bec2ec0..76cc039 100644
--- a/drivers/gpu/drm/radeon/radeon_object.c
+++ b/drivers/gpu/drm/radeon/radeon_object.c
@@ -81,7 +81,13 @@ 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));
+
+ if (!list_empty(&bo->va)) {
+ DRM_ERROR("Virtual address list not empty, accel: %d\n",
+ bo->rdev->accel_working);
+ WARN_ON_ONCE(1);
+ }
+
drm_gem_object_release(&bo->gem_base);
kfree(bo);
}
--
2.7.4
More information about the amd-gfx
mailing list