aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem.c
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2014-02-25 10:11:24 -0500
committerDaniel Vetter <daniel.vetter@ffwll.ch>2014-03-05 15:30:24 -0500
commitab0e7ff9f2d0bfe139a2ed5bb6a36f8cbd4e0886 (patch)
tree66a0a24af927cffbb34a25d0c0190d1a4507cecc /drivers/gpu/drm/i915/i915_gem.c
parent8d9fc7fd2de6edc3b9c3f828a701bfa6891987e7 (diff)
drm/i915: Record pid/comm of hanging task
After finding the guilty batch and request, we can use it to find the process that submitted the batch and then add the culprit into the error state. This is a slightly different approach from Ben's in that instead of adding the extra information into the struct i915_hw_context, we use the information already captured in struct drm_file which is then referenced from the request. v2: Also capture the workaround buffer for gen2, so that we can compare its contents against the intended batch for the active request. v3: Rebase (Mika) v4: Check for null context (Chris) checkpatch warnings fixed Link: http://lists.freedesktop.org/archives/intel-gfx/2013-August/032280.html Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> (v2) Signed-off-by: Mika Kuoppala <mika.kuoppala@intel.com> (v4) Acked-by: Ben Widawsky <ben@bwidawsk.net> Cc: Ben Widawsky <ben@bwidawsk.net> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem.c')
-rw-r--r--drivers/gpu/drm/i915/i915_gem.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem.c b/drivers/gpu/drm/i915/i915_gem.c
index c5a182be2eb0..6e17b45db850 100644
--- a/drivers/gpu/drm/i915/i915_gem.c
+++ b/drivers/gpu/drm/i915/i915_gem.c
@@ -4857,6 +4857,7 @@ int i915_gem_open(struct drm_device *dev, struct drm_file *file)
4857 4857
4858 file->driver_priv = file_priv; 4858 file->driver_priv = file_priv;
4859 file_priv->dev_priv = dev->dev_private; 4859 file_priv->dev_priv = dev->dev_private;
4860 file_priv->file = file;
4860 4861
4861 spin_lock_init(&file_priv->mm.lock); 4862 spin_lock_init(&file_priv->mm.lock);
4862 INIT_LIST_HEAD(&file_priv->mm.request_list); 4863 INIT_LIST_HEAD(&file_priv->mm.request_list);