summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/gpu/nvgpu/include/nvgpu/vgpu/tegra_vgpu.h6
-rw-r--r--drivers/gpu/nvgpu/vgpu/vgpu.c4
2 files changed, 10 insertions, 0 deletions
diff --git a/drivers/gpu/nvgpu/include/nvgpu/vgpu/tegra_vgpu.h b/drivers/gpu/nvgpu/include/nvgpu/vgpu/tegra_vgpu.h
index c269dc24..3bcabadf 100644
--- a/drivers/gpu/nvgpu/include/nvgpu/vgpu/tegra_vgpu.h
+++ b/drivers/gpu/nvgpu/include/nvgpu/vgpu/tegra_vgpu.h
@@ -706,6 +706,10 @@ struct tegra_vgpu_sm_esr_info {
706 u32 hww_warp_esr_report_mask; 706 u32 hww_warp_esr_report_mask;
707}; 707};
708 708
709struct tegra_vgpu_semaphore_wakeup {
710 u32 post_events;
711};
712
709enum { 713enum {
710 714
711 TEGRA_VGPU_INTR_GR = 0, 715 TEGRA_VGPU_INTR_GR = 0,
@@ -722,6 +726,7 @@ enum {
722 TEGRA_VGPU_EVENT_FECS_TRACE = 2, 726 TEGRA_VGPU_EVENT_FECS_TRACE = 2,
723 TEGRA_VGPU_EVENT_CHANNEL = 3, 727 TEGRA_VGPU_EVENT_CHANNEL = 3,
724 TEGRA_VGPU_EVENT_SM_ESR = 4, 728 TEGRA_VGPU_EVENT_SM_ESR = 4,
729 TEGRA_VGPU_EVENT_SEMAPHORE_WAKEUP = 5,
725}; 730};
726 731
727struct tegra_vgpu_intr_msg { 732struct tegra_vgpu_intr_msg {
@@ -736,6 +741,7 @@ struct tegra_vgpu_intr_msg {
736 struct tegra_vgpu_fecs_trace_event_info fecs_trace; 741 struct tegra_vgpu_fecs_trace_event_info fecs_trace;
737 struct tegra_vgpu_channel_event_info channel_event; 742 struct tegra_vgpu_channel_event_info channel_event;
738 struct tegra_vgpu_sm_esr_info sm_esr; 743 struct tegra_vgpu_sm_esr_info sm_esr;
744 struct tegra_vgpu_semaphore_wakeup sem_wakeup;
739 char padding[32]; 745 char padding[32];
740 } info; 746 } info;
741}; 747};
diff --git a/drivers/gpu/nvgpu/vgpu/vgpu.c b/drivers/gpu/nvgpu/vgpu/vgpu.c
index eb56d4f9..3b53474d 100644
--- a/drivers/gpu/nvgpu/vgpu/vgpu.c
+++ b/drivers/gpu/nvgpu/vgpu/vgpu.c
@@ -165,6 +165,10 @@ int vgpu_intr_thread(void *dev_id)
165 case TEGRA_VGPU_EVENT_SM_ESR: 165 case TEGRA_VGPU_EVENT_SM_ESR:
166 vgpu_gr_handle_sm_esr_event(g, &msg->info.sm_esr); 166 vgpu_gr_handle_sm_esr_event(g, &msg->info.sm_esr);
167 break; 167 break;
168 case TEGRA_VGPU_EVENT_SEMAPHORE_WAKEUP:
169 g->ops.semaphore_wakeup(g,
170 !!msg->info.sem_wakeup.post_events);
171 break;
168 default: 172 default:
169 nvgpu_err(g, "unknown event %u", msg->event); 173 nvgpu_err(g, "unknown event %u", msg->event);
170 break; 174 break;