summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/gpu/nvgpu/gk20a/gr_gk20a.c')
-rw-r--r--drivers/gpu/nvgpu/gk20a/gr_gk20a.c34
1 files changed, 9 insertions, 25 deletions
diff --git a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
index ea4d1d24..f07a54b1 100644
--- a/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
+++ b/drivers/gpu/nvgpu/gk20a/gr_gk20a.c
@@ -5256,16 +5256,10 @@ static int gk20a_gr_handle_semaphore_pending(struct gk20a *g,
5256{ 5256{
5257 struct fifo_gk20a *f = &g->fifo; 5257 struct fifo_gk20a *f = &g->fifo;
5258 struct channel_gk20a *ch = &f->channel[isr_data->chid]; 5258 struct channel_gk20a *ch = &f->channel[isr_data->chid];
5259 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid];
5259 5260
5260 if (gk20a_is_channel_marked_as_tsg(ch)) { 5261 gk20a_tsg_event_id_post_event(tsg,
5261 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid]; 5262 NVGPU_EVENT_ID_GR_SEMAPHORE_WRITE_AWAKEN);
5262
5263 gk20a_tsg_event_id_post_event(tsg,
5264 NVGPU_EVENT_ID_GR_SEMAPHORE_WRITE_AWAKEN);
5265 } else {
5266 gk20a_channel_event_id_post_event(ch,
5267 NVGPU_EVENT_ID_GR_SEMAPHORE_WRITE_AWAKEN);
5268 }
5269 5263
5270 nvgpu_cond_broadcast(&ch->semaphore_wq); 5264 nvgpu_cond_broadcast(&ch->semaphore_wq);
5271 5265
@@ -5806,26 +5800,16 @@ static int gk20a_gr_post_bpt_events(struct gk20a *g, struct channel_gk20a *ch,
5806 u32 global_esr) 5800 u32 global_esr)
5807{ 5801{
5808 if (global_esr & gr_gpc0_tpc0_sm_hww_global_esr_bpt_int_pending_f()) { 5802 if (global_esr & gr_gpc0_tpc0_sm_hww_global_esr_bpt_int_pending_f()) {
5809 if (gk20a_is_channel_marked_as_tsg(ch)) { 5803 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid];
5810 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid];
5811 5804
5812 gk20a_tsg_event_id_post_event(tsg, 5805 gk20a_tsg_event_id_post_event(tsg,
5813 NVGPU_EVENT_ID_BPT_INT); 5806 NVGPU_EVENT_ID_BPT_INT);
5814 } else {
5815 gk20a_channel_event_id_post_event(ch,
5816 NVGPU_EVENT_ID_BPT_INT);
5817 }
5818 } 5807 }
5819 if (global_esr & gr_gpc0_tpc0_sm_hww_global_esr_bpt_pause_pending_f()) { 5808 if (global_esr & gr_gpc0_tpc0_sm_hww_global_esr_bpt_pause_pending_f()) {
5820 if (gk20a_is_channel_marked_as_tsg(ch)) { 5809 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid];
5821 struct tsg_gk20a *tsg = &g->fifo.tsg[ch->tsgid];
5822 5810
5823 gk20a_tsg_event_id_post_event(tsg, 5811 gk20a_tsg_event_id_post_event(tsg,
5824 NVGPU_EVENT_ID_BPT_PAUSE); 5812 NVGPU_EVENT_ID_BPT_PAUSE);
5825 } else {
5826 gk20a_channel_event_id_post_event(ch,
5827 NVGPU_EVENT_ID_BPT_PAUSE);
5828 }
5829 } 5813 }
5830 5814
5831 return 0; 5815 return 0;