]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/execlists: Reset CSB write pointer after reset
authorChris Wilson <chris@chris-wilson.co.uk>
Thu, 28 Jun 2018 20:12:08 +0000 (21:12 +0100)
committerChris Wilson <chris@chris-wilson.co.uk>
Thu, 28 Jun 2018 21:55:07 +0000 (22:55 +0100)
commitb8dcb19d6ed91841ca018b71f2ee9ddfcc35a1c1
tree232b69e75b4be506c19e54300a8aa61a0b2bb095
parentf0ece857d55044c428dd3c0cc0bbfd933e14687b
drm/i915/execlists: Reset CSB write pointer after reset

On HW reset, the HW clears the write pointer (to 0). But since it also
writes its first CSB entry to slot 0, we need to reset the write pointer
back to the element before (so the first entry we read is 0).

This is required for the next patch, where we trust the CSB completely!

v2: Use _MASKED_FIELD
v3: Store the reset value, so that we differentiate between mmio/hwsp
transparently and without pretense.

Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20180628201211.13837-6-chris@chris-wilson.co.uk
drivers/gpu/drm/i915/intel_lrc.c
drivers/gpu/drm/i915/intel_ringbuffer.h