drm/i915: Disable mmio debugging during user access
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 7 Sep 2017 13:44:41 +0000 (14:44 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 7 Sep 2017 16:58:17 +0000 (17:58 +0100)
commitd7a133d886b45651e36e7065998b1413d379ac1f
treea977bfb8df119e372bb0b0a9d8226e28495f9c81
parentd2d4f39b1e6407323e568c174e17b022b8f98a40
drm/i915: Disable mmio debugging during user access

If the user bypasses i915 and accesses mmio directly, that easily
confuses our automatic mmio debugging (any error we then detect is
likely to be as a result of the user). Since we expect userspace to open
debugfs/i915_forcewake_user if i915.ko is loaded and they want mmio
access, that makes the opportune time to disable our debugging for
duration of the bypass.

v2: Move the fiddling of uncore internals to uncore.c

References: https://bugs.freedesktop.org/show_bug.cgi?id=102543
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Reviewed-by: Mika Kuoppala <mika.kuoppala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20170907134441.12881-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_debugfs.c
drivers/gpu/drm/i915/intel_uncore.c
drivers/gpu/drm/i915/intel_uncore.h