[Intel-gfx] [PATCH 121/190] drm/i915: Scan GGTT active list for context object
Chris Wilson
chris at chris-wilson.co.uk
Mon Jan 11 02:45:05 PST 2016
Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
---
drivers/gpu/drm/i915/i915_gpu_error.c | 15 +++++++--------
1 file changed, 7 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c
index a3090d7ac20a..9a18fc502145 100644
--- a/drivers/gpu/drm/i915/i915_gpu_error.c
+++ b/drivers/gpu/drm/i915/i915_gpu_error.c
@@ -940,19 +940,18 @@ static void i915_gem_record_active_context(struct intel_engine_cs *ring,
struct drm_i915_error_state *error,
struct drm_i915_error_ring *ering)
{
- struct drm_i915_private *dev_priv = ring->dev->dev_private;
- struct drm_i915_gem_object *obj;
+ struct drm_i915_private *dev_priv = ring->i915;
+ struct i915_vma *vma;
/* Currently render ring is the only HW context user */
if (ring->id != RCS || !error->ccid)
return;
- list_for_each_entry(obj, &dev_priv->mm.bound_list, global_list) {
- if (!i915_gem_obj_ggtt_bound(obj))
- continue;
-
- if ((error->ccid & PAGE_MASK) == i915_gem_obj_ggtt_offset(obj)) {
- ering->ctx = i915_error_ggtt_object_create(dev_priv, obj);
+ list_for_each_entry(vma, &dev_priv->gtt.base.active_list, vm_link) {
+ if ((error->ccid & PAGE_MASK) == vma->node.start) {
+ ering->ctx = i915_error_object_create(dev_priv,
+ vma->obj,
+ vma->vm);
break;
}
}
--
2.7.0.rc3
More information about the Intel-gfx
mailing list