OSDN Git Service

drm/i915: Flush idle work when changing missed-irq fault injection
authorChris Wilson <chris@chris-wilson.co.uk>
Tue, 7 Mar 2017 15:59:08 +0000 (15:59 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Tue, 7 Mar 2017 16:52:28 +0000 (16:52 +0000)
commit64486ae7a9a9cc048c2842ba7628df7ce7374019
tree7a2e86b4130fb16f62195644db8edd0cf8cb0da3
parent7fba8306ccebb651bdba0c04692022a0b519cfea
drm/i915: Flush idle work when changing missed-irq fault injection

In order for the missed-irq update to take effect, the device must be
idle. So when the user updates the fault injection via debugfs, idle the
device.

v2: Idle is explicitly required for setting test_irq, and good behaviour
for clearing the missed_irq.
v3: Use matching types; expanding to more than ulong rings is left as an
exercise to the reader.

Testcase: igt/drv_missed_irq
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: http://patchwork.freedesktop.org/patch/msgid/20170307155908.14576-1-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/i915_debugfs.c