]> git.kernelconcepts.de Git - karo-tx-linux.git/commit
drm/i915: Prevent TLB error on first execution on SNB
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 13 Feb 2015 14:35:59 +0000 (14:35 +0000)
committerJani Nikula <jani.nikula@intel.com>
Tue, 10 Mar 2015 13:30:23 +0000 (15:30 +0200)
commit5e4f518959bdf8a4f9c8f80879e4a0f7a95d2cb3
treed439c77468bfcb75d8e13d830f8dd1168a95698b
parent0cd0caad99a028568dd4a7c1b95777aadf4eb317
drm/i915: Prevent TLB error on first execution on SNB

Long ago I found that I was getting sporadic errors when booting SNB,
with the symptom being that the first batch died with IPEHR != *ACTHD,
typically caused by the TLB being invalid. These magically disappeared
if I held the forcewake during the entire ring initialisation sequence.
(It can probably be shortened to a short critical section, but the whole
initialisation is full of register writes and so we would be taking and
releasing forcewake almost continually, and so holding it over the
entire sequence will probably be a net win!)

Note some of the kernels I encounted the issue already had the deferred
forcewake release, so it is still relevant.

I know that there have been a few other reports with similar failure
conditions on SNB, I think such as
References: https://bugs.freedesktop.org/show_bug.cgi?id=80913

v2: Wrap i915_gem_init_hw() with its own security blanket as we take
that path following resume and reset.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: stable@vger.kernel.org
Signed-off-by: Jani Nikula <jani.nikula@intel.com>
drivers/gpu/drm/i915/i915_gem.c