drm/i915/lrc: Only set RS ctx enable in ctx control reg if there is a RS
Subsystems (2)
PATCH 1/1 drm/i915/lrc: Only set RS ctx enable in ctx control reg if there is a RS
The driver should only set the "RS context enable" bit in the context image if we plan to use the resource streamer.
Signed-off-by Michel Thierry <[email protected]>
--- drivers/gpu/drm/i915/intel_lrc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)
drivers/gpu/drm/i915/intel_lrc.c +2 -1
@@ -2382,7 +2382,8 @@ populate_lr_context(struct intel_context *ctx, struct drm_i915_gem_object *ctx_oASSIGN_CTX_REG (reg_state,CTX_CONTEXT_CONTROL ,RING_CONTEXT_CONTROL (ring),_MASKED_BIT_ENABLE (CTX_CTRL_INHIBIT_SYN_CTX_SWITCH |CTX_CTRL_ENGINE_CTX_RESTORE_INHIBIT | -CTX_CTRL_RS_CTX_ENABLE )); + (HAS_RESOURCE_STREAMER (dev) ? +CTX_CTRL_RS_CTX_ENABLE :0 )));ASSIGN_CTX_REG (reg_state,CTX_RING_HEAD ,RING_HEAD (ring->mmio_base),0 );ASSIGN_CTX_REG (reg_state,CTX_RING_TAIL ,RING_TAIL (ring->mmio_base),0 );/* Ring buffer start address is not known until the buffer is pinned.
Signature · 6 lines
2.7.1 _______________________________________________ Intel-gfx mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/intel-gfx
Quoted 14 lines · Michel Thierry
The driver should only set the "RS context enable" bit in the context image if we plan to use the resource streamer.
Signed-off-by Michel Thierry <[email protected]>--- drivers/gpu/drm/i915/intel_lrc.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)drivers/gpu/drm/i915/intel_lrc.c +0
-0
drivers/gpu/drm/i915/intel_lrc.c populate_lr_context(struct intel_context *ctx, struct drm_i915_gem_object *ctx_o · line 2389
Quoted 9 lines
drivers/gpu/drm/i915/intel_lrc.c +2
-1@@ -2382,7 +2382,8 @@ populate_lr_context(struct intel_context *ctx, struct drm_i915_gem_object *ctx_oASSIGN_CTX_REG (reg_state,CTX_CONTEXT_CONTROL ,RING_CONTEXT_CONTROL (ring),_MASKED_BIT_ENABLE (CTX_CTRL_INHIBIT_SYN_CTX_SWITCH |CTX_CTRL_ENGINE_CTX_RESTORE_INHIBIT | -CTX_CTRL_RS_CTX_ENABLE )); + (HAS_RESOURCE_STREAMER (dev) ? +CTX_CTRL_RS_CTX_ENABLE :0 )));ASSIGN_CTX_REG (reg_state,CTX_RING_HEAD ,RING_HEAD (ring->mmio_base),0 );ASSIGN_CTX_REG (reg_state,CTX_RING_TAIL ,RING_TAIL (ring->mmio_base),0 );/* Ring buffer start address is not known until the buffer is pinned.
looks good to me,
Reviewed-by Arun Siluvery <[email protected]>
regards
Arun
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx