drm/i915: Hold struct_mutex for per-file stats in debugfs/i915_gem_object
authorChris Wilson <[email protected]>
Sat, 17 Jun 2017 11:57:44 +0000 (12:57 +0100)
committerChris Wilson <[email protected]>
Wed, 21 Jun 2017 09:31:00 +0000 (10:31 +0100)
commit0caf81b5c53d9bd332a95dbcb44db8de0b397a7c
tree6e6dcb96c6412d647c7bf387ef6d197c95dc71ed
parent7a3bc034ed5c4b57c145a025070739ec41434e94
drm/i915: Hold struct_mutex for per-file stats in debugfs/i915_gem_object

As we walk the obj->vma_list in per_file_stats(), we need to hold
struct_mutex to prevent alteration of that list.

Fixes: 1d2ac403ae3b ("drm: Protect dev->filelist with its own mutex")
Fixes: c84455b4bacc ("drm/i915: Move debug only per-request pid tracking from request to ctx")
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=101460
Signed-off-by: Chris Wilson <[email protected]>
Cc: Daniel Vetter <[email protected]>
Cc: Joonas Lahtinen <[email protected]>
Link: http://patchwork.freedesktop.org/patch/msgid/[email protected]
Reviewed-by: Tvrtko Ursulin <[email protected]>
drivers/gpu/drm/i915/i915_debugfs.c