drm/i915: Fix pre-ILK error interrupt ack
authorVille Syrjälä <ville.syrjala@linux.intel.com>
Mon, 11 Jun 2018 20:02:57 +0000 (23:02 +0300)
committerVille Syrjälä <ville.syrjala@linux.intel.com>
Wed, 4 Jul 2018 20:03:30 +0000 (23:03 +0300)
commit78c357dd3fcf51de61a0b8db3abdb8ed5aea6dd8
tree3be7b5dd4204b1f571b3c2d4862cc63657034ed7
parent0ba7c51a6fd80a89236f6ceb52e63f8a7f62bfd3
drm/i915: Fix pre-ILK error interrupt ack

Adjust the EIR clearing to cope with the edge triggered IIR
on i965/g4x. To guarantee an edge in the ISR master error bit
we temporarily mask everything in EMR. As some of the EIR bits
can't even be directly cleared we also borrow a trick from
i915_clear_error_registers() and permanently mask any bit that
remains high. No real thought given to how we might unmask them
again once the cause for the error has been clered. I suppose
on pre-g4x GPU reset will reinitialize EMR from scratch.

Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180611200258.27121-3-ville.syrjala@linux.intel.com
Reviewed-by: Imre Deak <imre.deak@intel.com>
drivers/gpu/drm/i915/i915_irq.c
drivers/gpu/drm/i915/i915_reg.h