drm/msm/A5xx: Skip hardware preemption init if no preemption
Subsystems (4)
PATCH 1/1 drm/msm/A5xx: Skip hardware preemption init if no preemption
In the case where preemption is not enabled, this patch simply skips preemption related initialization in hardware init sequence.
Signed-off-by Sharat Masetty <[email protected]>
--- drivers/gpu/drm/msm/adreno/a5xx_preempt.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)
drivers/gpu/drm/msm/adreno/a5xx_preempt.c +7 -3
@@ -208,6 +208,13 @@ void a5xx_preempt_hw_init(struct msm_gpu *gpu)struct a5xx_gpu *a5xx_gpu =to_a5xx_gpu (adreno_gpu);int i; +/* Always come up on rb 0 */ + a5xx_gpu->cur_ring = gpu->rb[0 ]; + +/* No preemption if we only have one ring */ +if (gpu->nr_rings ==1 ) +return ; +for (i =0 ; i < gpu->nr_rings; i++) { a5xx_gpu->preempt[i]->wptr =0 ; a5xx_gpu->preempt[i]->rptr =0 ;
@@ -220,9 +227,6 @@ void a5xx_preempt_hw_init(struct msm_gpu *gpu)/* Reset the preemption state */ set_preempt_state (a5xx_gpu,PREEMPT_NONE ); - -/* Always come up on rb 0 */ - a5xx_gpu->cur_ring = gpu->rb[0 ]; } static int preempt_init_ring(struct a5xx_gpu *a5xx_gpu,
Signature · 6 lines
1.9.1 _______________________________________________ dri-devel mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/dri-devel
A message that is not in the archive (sent off-list or not yet received): 1536914335-19717-1-git-send-email-smasetty-sgV2jX0FEOL9JmXXK+q4OQ@public.gmane.org
Jordan Crouse
Reviewed-byQuoted 2 lines · Sharat Masetty
In the case where preemption is not enabled, this patch simply skips preemption related initialization in hardware init sequence.
Reviewed-by Jordan Crouse <[email protected]>
Quoted 36 lines
Signed-off-by Sharat Masetty <[email protected]>--- drivers/gpu/drm/msm/adreno/a5xx_preempt.c | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-)drivers/gpu/drm/msm/adreno/a5xx_preempt.c +7
-3@@ -208,6 +208,13 @@ void a5xx_preempt_hw_init(struct msm_gpu *gpu)struct a5xx_gpu *a5xx_gpu =to_a5xx_gpu (adreno_gpu);int i; +/* Always come up on rb 0 */ + a5xx_gpu->cur_ring = gpu->rb[0 ]; + +/* No preemption if we only have one ring */ +if (gpu->nr_rings ==1 ) +return ; +for (i =0 ; i < gpu->nr_rings; i++) { a5xx_gpu->preempt[i]->wptr =0 ; a5xx_gpu->preempt[i]->rptr =0 ;@@ -220,9 +227,6 @@ void a5xx_preempt_hw_init(struct msm_gpu *gpu)/* Reset the preemption state */ set_preempt_state (a5xx_gpu,PREEMPT_NONE ); - -/* Always come up on rb 0 */ - a5xx_gpu->cur_ring = gpu->rb[0 ]; } static int preempt_init_ring(struct a5xx_gpu *a5xx_gpu,Signature · 1 line
1.9.1
Signature · 6 lines
The Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum, a Linux Foundation Collaborative Project _______________________________________________ Freedreno mailing list [email protected] https://lists.freedesktop.org/mailman/listinfo/freedreno